Closed ech0-py closed 1 year ago
My guess would be this has to do with the MQTT retain Retain flag
What this means is that your MQTT explorer was open when the message was received on MQTT, but it's not kept on the server. If you restart MQTT explorer you will see the same result as you see with restarting HASS. The value will not exist (Unknown)
The value needs to be reported again. In theory no_unit
should be reported every 5 min... not sure why the HASS state mentions 6 min unknown, since there should have been a 5min in that 6min (they will not be synced)
But I have configured schedule to report every 5sec (full addon config I've added to the Addon configuration... expand section, that not obvious I guess), thus I though everything should be ok, but it's not. Addon does really report grid_connected = 1 every 5 seconds, I see it in mqtt explorer as well
SCHEDULES:
- KEY: grid_connected
READ_EVERY: 5
REPORT_EVERY: 5
CHANGE_ANY: true
I made another longer test to show that even mosquitto restart doesn't help and entity was in unknown state for more than 20 minutes long
Mosquitto restart won't help. Probably only the addon restart
Can you try setting change_any
to false? or removing it from the schedule?
Still the same in both cases:
Sure, only the addon restart helps
Same for me. But just change the grid state in real from on to off and the state of entity appear clearly now.
Le mar. 12 sept. 2023 à 08:04, ech0-py @.***> a écrit :
Still the same in both cases:
- change_any: false (or remove the grid_connected from the schedule)
- restart HA
- sensor becomes unknown
- wait for 5+ minutes until every other sensor get value
- sensor is still unknown
Sure, only the addon restart helps
— Reply to this email directly, view it on GitHub https://github.com/kellerza/sunsynk/issues/182#issuecomment-1715041883, or unsubscribe https://github.com/notifications/unsubscribe-auth/AYDJ6M4UJWP6763IQFSRONDXZ73NLANCNFSM6AAAAAA4SAIKXI . You are receiving this because you are subscribed to this thread.Message ID: @.***>
I've added a possible fix in the edge branch, only unit tested for now
But just change the grid state in real from on to off and the state of entity appear clearly now.
I can confirm. If in unknown state I turn off the inverter and then turn on it the entity changes the state accordingly
For some reason the BinarySensor
required an actual change (by any means) to work. This sensors is the only Binary Sensor today.
We have so much load-shedding in South Africa I probably would have never picked up this bug 🤣
I confirm that on the edge everything now works as expected From my perspective, what's changed:
I appreciate your efforts, sir, god bless you <3
🤣in France very rare grid outage . But I force every day my inverter to go off -on grid depending of battery soc, so I see the unknow to ok value when the state change appear. Binary start at first change
Le mar. 12 sept. 2023 à 09:06, Johann Kellerman @.***> a écrit :
For some reason the BinarySensor required an actual change (by any means) to work. This sensors is the only Binary Sensor today.
We have so much load-shedding in South Africa I probably would have never picked up this bug 🤣
— Reply to this email directly, view it on GitHub https://github.com/kellerza/sunsynk/issues/182#issuecomment-1715121791, or unsubscribe https://github.com/notifications/unsubscribe-auth/AYDJ6MYNGE4OZEF6ALXKJPDX2ACWPANCNFSM6AAAAAA4SAIKXI . You are receiving this because you commented.Message ID: @.***>
But I force every day my inverter to go off -on grid depending of battery soc
Unfortunately in Ukraine we have a lot of outages during last year =\ Sorry I know this is off topic, but can you describe how you achieve that? Is that manual way (turn off the breaker by hands), automatic (smart zigbee/wifi relay/breaker) or mb even some kind of software (writing to the modbus registry, for example). I'm trying found ways to achieve low energy consumption from the grid/battery during the night
Just change minimum frequency to a value outage your grid For example 50Hz grid
min frequency set to 52Hz and then inverter go alone to off grid by opening the internal grid input relay
Le mar. 12 sept. 2023 à 10:56, ech0-py @.***> a écrit :
But I force every day my inverter to go off -on grid depending of battery soc
Sorry I know this is off topic, but can you describe how you achieve that? Is that manual way (turn off the breaker by hands), automatic (smart zigbee/wifi relay/breaker) or mb even some kind of software (writing to the modbus registry, for example). I'm trying found ways to achieve low energy consumption from the grid/battery during the night
— Reply to this email directly, view it on GitHub https://github.com/kellerza/sunsynk/issues/182#issuecomment-1715300671, or unsubscribe https://github.com/notifications/unsubscribe-auth/AYDJ6M3PUK4PTEDIAERMSILX2APUFANCNFSM6AAAAAA4SAIKXI . You are receiving this because you commented.Message ID: @.***>
You Inverter
Deye 8kw 1phase (SG01 generation)
Addon
Sunsynk/Deye Inverter Add-on (multi) Current version: 0.5.9
Addon configuration...
```yaml DRIVER: umodbus INVERTERS: - SERIAL_NR: "Describe the issue/bug and what you expect
After one of the recent updates (not sure which one) the Grid Connected sensor goes to the "unknown" state after HA restart, while mqtt-explorer shows that sensor is present and availability topic is present. Reloading of MQTT integration do nothing, restarting of sunsynk addon helps to resolve the issue.
Not sure where I can see what's going wrong
Logs (if applicable)