balda / ruuvitag-discovery

Web interface to Discover RuuviTag Environmental Sensors and save measures to MQTT, InfluxDB, Graphite and Home Assistant
MIT License
31 stars 6 forks source link

Measurement stops after several minutes #26

Closed subterfugium closed 3 years ago

subterfugium commented 3 years ago

After upgrading to 0.2.1 my ruuvi tags started working properly. Before I would only get few measurement and USB dongle would reset.

Now following is happening after several minutes: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON: 2020-12-07 00:38:50 WARNING (MainThread) [homeassistant.components.mqtt] Erroneous JSON:

Around the same time RuuviDiscovery stops reporting values: image

home-assistant.log does not provide much else data and ruuvi Logs seem empty. image

Supervisor 2020.12.6, home assistant 0.118.5, "Home Assistant OS" install method. Mosquitto broker Current version: 5.1 (only used for RuuviTag).

Config exported from RuuviDiscovery UI:

Example ``` { "sampling": { "history": 100, "interval": 10000 }, "battery": { "min": 2500, "max": 3000 }, "ruuvitags": { "c681a6c0c92f": "Guest Room", "eb825f280c35": "Bedroom", "e2f3bc34f1eb": "Livingroom intake", "f8e525b68371": "Sauna", "c8bc6d15b1ba": "Freezer", "dc16ddb00b0b": "Outside Air", "eae10c8de708": "Sebu" }, "targets": [ { "type": "ha_mqtt", "id": "0", "enable": 1, "name": "ruuvi", "interval": 300, "host": "***********", "port": "***********", "topic": "homeassistant", "username": "***********", "password": "***********", "tags": { "c681a6c0c92f": { "id": "c681a6c0c92f", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "battery_level": { "label": "Battery Level", "field": "battery_level" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Guest Room", "field": "ruuvitag_c681a6c0c92f", "selected": true }, "eb825f280c35": { "id": "eb825f280c35", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Bedroom", "field": "ruuvitag_eb825f280c35", "selected": true }, "e2f3bc34f1eb": { "id": "e2f3bc34f1eb", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Intake air", "field": "ruuvitag_e2f3bc34f1eb", "selected": true }, "eae10c8de708": { "id": "eae10c8de708", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "battery_level": { "label": "Battery Level", "field": "battery_level" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Sensor1", "field": "ruuvitag_eae10c8de708", "selected": true }, "c8bc6d15b1ba": { "id": "c8bc6d15b1ba", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "battery_level": { "label": "Battery Level", "field": "battery_level" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Freezer", "field": "ruuvitag_c8bc6d15b1ba", "selected": true }, "f8e525b68371": { "id": "f8e525b68371", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "battery_level": { "label": "Battery Level", "field": "battery_level" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Sauna", "field": "ruuvitag_f8e525b68371", "selected": true }, "dc16ddb00b0b": { "id": "dc16ddb00b0b", "measures": { "temperature": { "label": "Temperature", "field": "temperature" }, "humidity": { "label": "Humidity", "field": "humidity" }, "pressure": { "label": "Pressure", "field": "pressure" }, "battery_level": { "label": "Battery Level", "field": "battery_level" }, "rssi": { "label": "RSSI", "field": "rssi" } }, "name": "Outside air", "field": "ruuvitag_dc16ddb00b0b", "selected": true } } } ], "columns": { "name": true, "dataFormat": true, "rssi": true, "temperature": true, "humidity": true, "pressure": true, "battery": true, "battery_level": true, "txPower": true, "movementCounter": true, "measurementSequenceNumber": true, "samples": true, "frequency": true, "period": true, "ts": true } } ```

Could you help me debug this further?

balda commented 3 years ago

I have exactly the same configuration and I never had this kind of error. You configuration is good (no obvious error). Have you tried to restart the addon to see if the error returns? (maybe a temporary bug).

As the error seems to come from the MQTT (JSON error), you can inspect the message with MQTT Explorer (http://mqtt-explorer.com/). I like this tool, but you can use another.

Another test is to modify the interval (yours is 300) to a lower value (less than 30): the device must be regularly “presented” to Home Assistant and the frequency is set to 30 seconds. Maybe a bug with this... I try to make it configurable ;)

subterfugium commented 3 years ago

Well, I did upgrade my debian host to latest docker which broke everything. I ended up to setup everything from the scratch. I will try to set frequency to 30 and see if issue happens again.

subterfugium commented 3 years ago

I could not find the JSON error in the logs anymore so I did not investigate MQTT error further. Will do if I see it again.

Issue is still happening after setting up home assistant: image

Flat line is when the issue happens. During that time if I move my bluetooth dongle, RSSI values do not update (normally they do updatevery responsively) so this might indicate issue somewhere between RuuviDiscovery and bluetooth hardware. I did not run bluetooth scan from host system when this happened to verify if issue is at bluetooth. Will try this next time issue happens. It usually takes several hours to happen.

I tried timers 20s and 30s. It seems that restarting ruuvi discovery returns the functionality (you can see new measurement at the end of the graph after restart).

This is RuuviDsicovery Log from webui Log tab:

RuuviTag Discovery WebUI Log [s6-init] making user provided files available at /var/run/s6/etc...exited 0. [s6-init] ensuring user provided files have correct perms...exited 0. [fix-attrs.d] applying ownership & permissions fixes... [fix-attrs.d] done. [cont-init.d] executing container initialization scripts... [cont-init.d] 00-banner.sh: executing... ----------------------------------------------------------- Add-on: RuuviTag Discovery Web interface to Discover RuuviTag Environmental Sensors and save measures to Home Assistant, MQTT, InfluxDB and Graphite ----------------------------------------------------------- Add-on version: 0.2.2 You are running the latest version of this add-on. System: Debian GNU/Linux 10 (buster) (amd64 / qemux86-64) Home Assistant Core: 0.118.5 Home Assistant Supervisor: 2020.12.6 ----------------------------------------------------------- Please, share the above information when looking for help or support in, e.g., GitHub, forums or the Discord chat. ----------------------------------------------------------- [cont-init.d] 00-banner.sh: exited 0. [cont-init.d] 01-log-level.sh: executing... [cont-init.d] 01-log-level.sh: exited 0. [cont-init.d] done. [services.d] starting services [services.d] done. > ruuvitag-discovery@0.2.2 start /app > NODE_ENV=production node index.js Start RuuviTag Discovery - v0.2.2 Start measures sampling every 10 seconds Start web server on port 8099 Discover RuuviTag f8e525b68371 Connected to MQTT "ruuvi" Discover RuuviTag eb825f280c35 Discover RuuviTag c681a6c0c92f Discover RuuviTag c8bc6d15b1ba Discover RuuviTag e2f3bc34f1eb Discover RuuviTag eae10c8de708 Discover RuuviTag dc16ddb00b0b

Is is possible to enable debug logging on RuuviDiscovery? I tried to look for a log in host system and in docker but did not find anything related. I did have some issues with my bluetooth dongle (Plugable BLE 4), but in this case both host, virtual machine and home assistant did not print any errors about loosing access to bluetooth hardware.

Thanks for you time!

balda commented 3 years ago

I will work on a more advanced log module (with a debug mode) ;)

I suspect a problem with your Bluetooth interface (RaspberryPi 3B has already had this kind of problem).

subterfugium commented 3 years ago

You are probably correct. Issue happened again and I executed 'hcitool -i hci0 scan' command on host machine (running supervised install) and it did not produce any output, but RuuviDiscovery started to update RSSI values again :O I need to investigate this from bluetooth point of view.

balda commented 3 years ago

Release 0.2.3 add more log options (configurable in the UI). I hope it will help.

subterfugium commented 3 years ago

Release 0.2.3 add more log options (configurable in the UI). I hope it will help.

Just installed, looks very nice indeed. Update before applying 0.2.3.

I had bluetooth service set to debug mode and I was using btmon to record snoop and txt log. None of them show anything going wrong, measurement just stops at random time after restarting RuuviDiscovery everything continues as normal. From OS point-of-view everything seem to be in order. Modified kernel parameter to /etc/default/grub add autosuspend disable: GRUB_CMDLINE_LINUX_DEFAULT="quiet btusb.enable_autosuspend=n" And enable FastConnectable at /etc/bluetooth/main.conf.

Anyway, I enabled all logging from 0.2.3 GUI, bluetooth service logs and btmon snoop/txt logs running now. Wish me luck! :)

balda commented 3 years ago

Good luck! :)

subterfugium commented 3 years ago

Nothing much on logs. btmon snoop log stops suddenly in the middle of event:

> HCI Event: LE Meta Event (0x3e) plen 43           #120437 [hci0] 60250.188889
      LE Advertising Report (0x02)
        Num reports: 1
        Event type: Non connectable undirected - ADV_NONCONN_IND (0x03)
        Address type: Random (0x01)
        Address: EB:82:5F:28:0C:35 (Static)
        Data length: 31
        Flags: 0x06
          LE General Discoverable Mode
          BR/EDR Not Supported
        Company: not assigned (1177)
          Data: 050ff82dceca4effe8ffb40410b236adec3aeb825f280c35
        RSSI: -72 dBm (0xb8)
> HCI Event: LE Meta Event (0x3e) plen 40           #120438 [hci0] 60250.218862
      LE Advertising Report (0x02)
        Num reports: 1
        Event type: Scannable undirected - ADV_SCAN_IND (0x02)
        Address type: Random (0x01)
        Address: 7E:F3:35:D7:40:33 (Re

Same time nothing happens on bluetooth service logs, some prints several hours ago then nothing

Dec 13 01:50:16 hass bluetoothd[417]: src/adapter.c:add_uuid() sending add uuid command for index 0
Dec 13 01:50:16 hass bluetoothd[417]: src/profile.c:register_profile() sender :1.94
Dec 13 01:50:16 hass bluetoothd[417]: src/profile.c:create_ext() Created ":1.94/Profile/HSPHSProfile/00001108-0000-1000-8000-00805f9b34fb"
Dec 13 01:50:16 hass bluetoothd[417]: src/profile.c:ext_adapter_probe() ":1.94/Profile/HSPHSProfile/00001108-0000-1000-8000-00805f9b34fb" probed
Dec 13 01:50:16 hass bluetoothd[417]: src/profile.c:ext_start_servers() :1.94/Profile/HSPHSProfile/00001108-0000-1000-8000-00805f9b34fb listening on chan 3
Dec 13 01:50:16 hass bluetoothd[417]: src/adapter.c:adapter_service_add() /org/bluez/hci0
Dec 13 01:50:16 hass bluetoothd[417]: src/sdpd-service.c:add_record_to_server() Adding record with handle 0x10006
Dec 13 01:50:16 hass bluetoothd[417]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00000003-0000-1000-8000-00805f9
Dec 13 01:50:16 hass bluetoothd[417]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00000100-0000-1000-8000-00805f9
Dec 13 01:50:16 hass bluetoothd[417]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00001002-0000-1000-8000-00805f9
Dec 13 01:50:16 hass bluetoothd[417]: src/sdpd-service.c:add_record_to_server() Record pattern UUID 00001108-0000-1000-8000-00805f9
Dec 13 01:50:16 hass bluetoothd[417]: src/adapter.c:adapter_service_insert() /org/bluez/hci0
Dec 13 01:50:16 hass bluetoothd[417]: src/adapter.c:add_uuid() sending add uuid command for index 0
Dec 13 01:50:16 hass bluetoothd[417]: src/adapter.c:dev_class_changed_callback() Class: 0x040000
Dec 13 01:50:16 hass 80ff6a42e65d[480]: I: [pulseaudio] module.c: Loaded "module-bluetooth-discover" (index: #7; argument: "").
Dec 13 01:50:16 hass bluetoothd[417]: src/adapter.c:dev_class_changed_callback() Class: 0x0c0000
Dec 13 01:50:16 hass 80ff6a42e65d[480]: D: [pulseaudio] backend-native.c: Bluetooth Headset Backend API support using the native backend

RuuviDiscovery logs don't show much either:

Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.277Z] [DEBUG] [HA MQTT] Publish on topic "homeassistant/sensor/f8e525b68371/battery_level/attributes" message: {"RuuviTag":"f8e525b68371","Measure":"Battery Level","Unit":"%"}
Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.277Z] [SEND] Send data to target "ruuvi" (ha_mqtt): {"id":"eae10c8de708","name":"Sebu","field":"ruuvitag_eae10c8de708","measures":[{"label":"RSSI","field":"rssi","value":-93,"measure":"rssi"},{"label":"Temperature","field":"temperature","value":21.84,"measure":"temperature"},{"label":"Humidity","field":"humidity","value":26.0525,"measure":"humidity"},{"label":"Pressure","field":"pressure","value":101898,"measure":"pressure"},{"label":"Battery Level","field":"battery_level","value":100,"measure":"battery_level"}]}
Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.277Z] [DEBUG] [HA MQTT] Publish on topic "homeassistant/sensor/eae10c8de708/rssi/attributes" message: {"RuuviTag":"eae10c8de708","Measure":"RSSI","Unit":"dBm"}
Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.278Z] [DEBUG] [HA MQTT] Publish on topic "homeassistant/sensor/eae10c8de708/temperature/attributes" message: {"RuuviTag":"eae10c8de708","Measure":"Temperature","Unit":"°C"}
Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.278Z] [DEBUG] [HA MQTT] Publish on topic "homeassistant/sensor/eae10c8de708/humidity/attributes" message: {"RuuviTag":"eae10c8de708","Measure":"Humidity","Unit":"%"}
Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.278Z] [DEBUG] [HA MQTT] Publish on topic "homeassistant/sensor/eae10c8de708/pressure/attributes" message: {"RuuviTag":"eae10c8de708","Measure":"Pressure","Unit":"hPa"}
Dec 13 18:34:36 hass 130329fd3143[480]: [2020-12-13T16:34:36.278Z] [DEBUG] [HA MQTT] Publish on topic "homeassistant/sensor/eae10c8de708/battery_level/attributes" message: {"RuuviTag":"eae10c8de708","Measure":"Battery Level","Unit":"%"}
Dec 13 18:34:56 hass 130329fd3143[480]: [2020-12-13T16:34:56.270Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:35:16 hass 130329fd3143[480]: [2020-12-13T16:35:16.272Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:35:36 hass 130329fd3143[480]: [2020-12-13T16:35:36.273Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:35:56 hass 130329fd3143[480]: [2020-12-13T16:35:56.274Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:36:16 hass 130329fd3143[480]: [2020-12-13T16:36:16.274Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:36:29 hass hassio-supervisor[1011]: #033[32m20-12-13 16:36:29 INFO (SyncWorker_5) [supervisor.docker.addon] Export image 5069d20e/amd64-addon-ruuvitag-discovery to /data/tmp/tmpy74gz4n2/image.tar#033[0m
Dec 13 18:36:29 hass 713d24db93ca[480]: #033[32m20-12-13 16:36:29 INFO (SyncWorker_5) [supervisor.docker.addon] Export image 5069d20e/amd64-addon-ruuvitag-discovery to /data/tmp/tmpy74gz4n2/image.tar#033[0m
Dec 13 18:36:30 hass 713d24db93ca[480]: #033[32m20-12-13 16:36:30 INFO (SyncWorker_5) [supervisor.docker.addon] Export image 5069d20e/amd64-addon-ruuvitag-discovery done#033[0m
Dec 13 18:36:30 hass hassio-supervisor[1011]: #033[32m20-12-13 16:36:30 INFO (SyncWorker_5) [supervisor.docker.addon] Export image 5069d20e/amd64-addon-ruuvitag-discovery done#033[0m
Dec 13 18:36:31 hass 713d24db93ca[480]: #033[32m20-12-13 16:36:31 INFO (MainThread) [supervisor.addons.addon] Building snapshot for add-on 5069d20e_ruuvitag-discovery#033[0m
Dec 13 18:36:31 hass hassio-supervisor[1011]: #033[32m20-12-13 16:36:31 INFO (MainThread) [supervisor.addons.addon] Building snapshot for add-on 5069d20e_ruuvitag-discovery#033[0m
Dec 13 18:36:36 hass 130329fd3143[480]: [2020-12-13T16:36:36.275Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:36:56 hass 130329fd3143[480]: [2020-12-13T16:36:56.275Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:37:16 hass 130329fd3143[480]: [2020-12-13T16:37:16.276Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:37:36 hass 130329fd3143[480]: [2020-12-13T16:37:36.275Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:37:36 hass 713d24db93ca[480]: #033[32m20-12-13 16:37:36 INFO (MainThread) [supervisor.addons.addon] Finish snapshot for addon 5069d20e_ruuvitag-discovery#033[0m
Dec 13 18:37:36 hass hassio-supervisor[1011]: #033[32m20-12-13 16:37:36 INFO (MainThread) [supervisor.addons.addon] Finish snapshot for addon 5069d20e_ruuvitag-discovery#033[0m
Dec 13 18:37:56 hass 130329fd3143[480]: [2020-12-13T16:37:56.286Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:38:16 hass 130329fd3143[480]: [2020-12-13T16:38:16.287Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:38:36 hass 130329fd3143[480]: [2020-12-13T16:38:36.287Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:38:56 hass 130329fd3143[480]: [2020-12-13T16:38:56.288Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:39:16 hass 130329fd3143[480]: [2020-12-13T16:39:16.288Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:39:36 hass 130329fd3143[480]: [2020-12-13T16:39:36.289Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:39:56 hass 130329fd3143[480]: [2020-12-13T16:39:56.290Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:40:16 hass 130329fd3143[480]: [2020-12-13T16:40:16.291Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:40:36 hass 130329fd3143[480]: [2020-12-13T16:40:36.291Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:40:56 hass 130329fd3143[480]: [2020-12-13T16:40:56.291Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:41:16 hass 130329fd3143[480]: [2020-12-13T16:41:16.292Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:41:36 hass 130329fd3143[480]: [2020-12-13T16:41:36.293Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:41:56 hass 130329fd3143[480]: [2020-12-13T16:41:56.294Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:42:16 hass 130329fd3143[480]: [2020-12-13T16:42:16.294Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:42:36 hass 130329fd3143[480]: [2020-12-13T16:42:36.294Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:42:56 hass 130329fd3143[480]: [2020-12-13T16:42:56.295Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:43:16 hass 130329fd3143[480]: [2020-12-13T16:43:16.295Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:43:36 hass 130329fd3143[480]: [2020-12-13T16:43:36.295Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:43:56 hass 130329fd3143[480]: [2020-12-13T16:43:56.296Z] [DEBUG] Broadcast to "ruuvi"

syslog (home assistant log basically) in general doesn't have much at the same time:

Dec 13 18:43:56 hass 130329fd3143[480]: [2020-12-13T16:43:56.296Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:44:16 hass 130329fd3143[480]: [2020-12-13T16:44:16.297Z] [DEBUG] Broadcast to "ruuvi"
Dec 13 18:44:17 hass 713d24db93ca[480]: #033[32m20-12-13 16:44:17 INFO (MainThread) [supervisor.host.info] Updating local host information#033[0m
Dec 13 18:44:17 hass hassio-supervisor[1011]: #033[32m20-12-13 16:44:17 INFO (MainThread) [supervisor.host.info] Updating local host information#033[0m
Dec 13 18:44:17 hass dbus-daemon[373]: [system] Activating via systemd: service name='org.freedesktop.hostname1' unit='dbus-org.freedesktop.hostname1.service' requested by ':1.645' (uid=0 pid=8139 comm="gdbus call --system --dest org.freedesktop.hostnam")
Dec 13 18:44:17 hass systemd[1]: Starting Hostname Service...
Dec 13 18:44:18 hass dbus-daemon[373]: [system] Successfully activated service 'org.freedesktop.hostname1'
Dec 13 18:44:18 hass systemd[1]: Started Hostname Service.
Dec 13 18:44:18 hass 713d24db93ca[480]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host.services] Updating service information#033[0m
Dec 13 18:44:18 hass hassio-supervisor[1011]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host.services] Updating service information#033[0m
Dec 13 18:44:18 hass 713d24db93ca[480]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host.network] Updating local network information#033[0m
Dec 13 18:44:18 hass hassio-supervisor[1011]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host.network] Updating local network information#033[0m
Dec 13 18:44:18 hass 713d24db93ca[480]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host.sound] Updating PulseAudio information#033[0m
Dec 13 18:44:18 hass hassio-supervisor[1011]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host.sound] Updating PulseAudio information#033[0m
Dec 13 18:44:18 hass 80ff6a42e65d[480]: I: [pulseaudio] client.c: Created 8 "Native client (UNIX socket client)"
Dec 13 18:44:18 hass 80ff6a42e65d[480]: I: [pulseaudio] protocol-native.c: Client authenticated anonymously.
Dec 13 18:44:18 hass 80ff6a42e65d[480]: D: [pulseaudio] protocol-native.c: Protocol version: remote 33, local 33
Dec 13 18:44:18 hass 80ff6a42e65d[480]: D: [pulseaudio] protocol-native.c: SHM possible: no
Dec 13 18:44:18 hass 80ff6a42e65d[480]: D: [pulseaudio] protocol-native.c: Negotiated SHM: no
Dec 13 18:44:18 hass 80ff6a42e65d[480]: D: [pulseaudio] protocol-native.c: Disabling srbchannel, reason: No SHM support
Dec 13 18:44:18 hass 80ff6a42e65d[480]: I: [pulseaudio] client.c: Freed 8 "supervisor"
Dec 13 18:44:18 hass 713d24db93ca[480]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host] Host information reload completed#033[0m
Dec 13 18:44:18 hass hassio-supervisor[1011]: #033[32m20-12-13 16:44:18 INFO (MainThread) [supervisor.host] Host information reload completed#033[0m
Dec 13 18:44:18 hass 80ff6a42e65d[480]: I: [pulseaudio] protocol-native.c: Connection died.

Running hcitool scan and ruuvi discovery starts updating RSSI values again. Weird, weird, my main suspicion is the broadcomm based bluetooth dongle. I need to try to find CSR based dongle somewhere and try with that.

subterfugium commented 3 years ago

Update from here. I switched Plugable 4.0 BLE dongle to Asus USB-BT500 Dongle around 8 pm and you can see the difference here: image

I would say to avoid https://plugable.com/products/usb-bt4le this product or any product based on Broadcomm BCM20702A chipset. So far I can recommend Realtek RTL8761B based bluetooth chips.

Thanks for you support even if we both knew issue wasn't in RuuviDiscovery. Hopefully this will help someone else in the future :)