Mycodo
Mycodo copied to clipboard
Mi Flora Sensor only gets new values once ... on activate/deactivate/reactivate Input
Hi,
Don´t know why ... no errors present in the log. MiFlora sensor works fine. But the only way to aquire new meassurments is to deactivate and reactivate the sensor on input tab.
Mycodo 8.10.1 ... also tried new Master 8.11 but then the live graphs won´t work anymore.(seems to be a bug)
The Sensor gets the same meassurements until deactivate and reactivate.
Any suggestion which log i could check ? I´m not quite sure if this could be an BT initializing error .
Or is there any workarround ...such like deactivating and reactivating an input in a period of time as a function ? ... couldn´t find something like this ... force meassurements as function won´t work also .
Greets El-Tonno
*ps ... could it be a timestamp problem ? .... i always see 'timestamp_utc': None
add... Log: ... everything seems fine ... but always the old values are recognized ... new values after deactivate and reactivate the input
2021-06-09 22:04:19,900 - DEBUG - mycodo.controllers.controller_input_ec1812f7 - Adding measurements to InfluxDB with ID ec1812f7-6661-4afc-82de-ac8a74d1cf59: {0: {'measurement': 'battery', 'unit': 'percent', 'value': 100.0, 'timestamp_utc': None}, 1: {'measurement': 'electrical_conductivity', 'unit': 'uS_cm', 'value': 0.0, 'timestamp_utc': None}, 2: {'measurement': 'light', 'unit': 'lux', 'value': 4.0, 'timestamp_utc': None}, 3: {'measurement': 'moisture', 'unit': 'unitless', 'value': 0.0, 'timestamp_utc': None}, 4: {'measurement': 'temperature', 'unit': 'C', 'value': 25.3, 'timestamp_utc': None}} 2021-06-09 22:04:49,862 - DEBUG - mycodo.inputs.xiaomi_miflora_ec1812f7 - Acquiring lock 2021-06-09 22:04:49,865 - DEBUG - mycodo.inputs.xiaomi_miflora_ec1812f7 - Releasing lock 2021-06-09 22:04:49,910 - DEBUG - mycodo.controllers.controller_input_ec1812f7 - Adding measurements to InfluxDB with ID ec1812f7-6661-4afc-82de-ac8a74d1cf59: {0: {'measurement': 'battery', 'unit': 'percent', 'value': 100.0, 'timestamp_utc': None}, 1: {'measurement': 'electrical_conductivity', 'unit': 'uS_cm', 'value': 0.0, 'timestamp_utc': None}, 2: {'measurement': 'light', 'unit': 'lux', 'value': 4.0, 'timestamp_utc': None}, 3: {'measurement': 'moisture', 'unit': 'unitless', 'value': 0.0, 'timestamp_utc': None}, 4: {'measurement': 'temperature', 'unit': 'C', 'value': 25.3, 'timestamp_utc': None}}
.... now the new ones after reactivating
2021-06-09 22:11:49,916 - DEBUG - mycodo.controllers.controller_input_ec1812f7 - Adding measurements to InfluxDB with ID ec1812f7-6661-4afc-82de-ac8a74d1cf59: {0: {'measurement': 'battery', 'unit': 'percent', 'value': 100.0, 'timestamp_utc': None}, 1: {'measurement': 'electrical_conductivity', 'unit': 'uS_cm', 'value': 455.0, 'timestamp_utc': None}, 2: {'measurement': 'light', 'unit': 'lux', 'value': 26.0, 'timestamp_utc': None}, 3: {'measurement': 'moisture', 'unit': 'unitless', 'value': 85.0, 'timestamp_utc': None}, 4: {'measurement': 'temperature', 'unit': 'C', 'value': 24.7, 'timestamp_utc': None}} 2021-06-09 22:12:11,684 - INFO - mycodo.controllers.controller_input_ec1812f7 - Deactivated in 76.3 ms 2021-06-09 22:12:21,141 - INFO - mycodo.inputs.xiaomi_miflora_ec1812f7 - Miflora: Name: Flower care, FW: 3.2.4 2021-06-09 22:12:21,143 - INFO - mycodo.controllers.controller_input_ec1812f7 - Activated in 3005.9 ms 2021-06-09 22:12:21,144 - DEBUG - mycodo.inputs.xiaomi_miflora_ec1812f7 - Acquiring lock 2021-06-09 22:12:21,386 - DEBUG - mycodo.inputs.xiaomi_miflora_ec1812f7 - Releasing lock 2021-06-09 22:12:21,515 - DEBUG - mycodo.controllers.controller_input_ec1812f7 - Adding measurements to InfluxDB with ID ec1812f7-6661-4afc-82de-ac8a74d1cf59: {0: {'measurement': 'battery', 'unit': 'percent', 'value': 100.0, 'timestamp_utc': None}, 1: {'measurement': 'electrical_conductivity', 'unit': 'uS_cm', 'value': 454.0, 'timestamp_utc': None}, 2: {'measurement': 'light', 'unit': 'lux', 'value': 134.0, 'timestamp_utc': None}, 3: {'measurement': 'moisture', 'unit': 'unitless', 'value': 85.0, 'timestamp_utc': None}, 4: {'measurement': 'temperature', 'unit': 'C', 'value': 24.5, 'timestamp_utc': None}}
I don't own this sensor, so I can't really debug any issue with it. If you happen to figure out the issue, I can try to fix the Input module. Perhaps search for previous issues that happened recently.
Did the update fix this? Is there a difference between all those other sensors that look like the flora? The original ones are either sold out or really expensive.