-
-
Notifications
You must be signed in to change notification settings - Fork 198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Group items state after reboot / powercycle #99
Comments
Please note that Github labels the issues automatically as bug and assigns them to @fvanroie , it was not me who puts these labels on. I don't have permission to change these afterwards. |
When you open a bug report, these get added automatically. Opening a Feature request or question will add the appropriate labels too. When in doubt, join our discussion forum or Discord channel and we'll happily discuss it there first. |
Moved from #123 Is your feature request related to a problem? Please describe. Describe the solution you'd like Describe alternatives you've considered Additional context |
Atm, joining an object or gpio to a group will not set the item to the last known group state. So this would require keeping the last group state, on join: set new members of the group to that state and advertise the new value of the item. |
Group items state is lost after reboot. To reproduce:
on
the relay turnson
on
(correctly), but after boot the object displays asoff
, state in MQTT ison
(as no update came)Also inconsistent state occurs after power-cycling. To reproduce:
on
the relay turnson
off
(correctly), after boot the object displays asoff
, state in MQTT ison
, incorrect (as no update came)I don't think we should save the state to the flash, instead we should check the state of the GPIO outputs in the group after boot and set the state of the objects accordingly. Also send an MQTT update about these to make sure real state is correct after reboot or power cycling and MQTT server reconnection.
It's important imho not to rely exclusively on the HA system to update states of the objects, when we're talking about outputs and objects on the same device. Reboots and power cycles are situations close to (prolonged) offline status. A plate boots in 1-2 seconds, a HA system can boot for minutes until plates are ready to connect. And states in the HA system can be really messed up after a boot.
The text was updated successfully, but these errors were encountered: