You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been looking through the web interface and the documentation and I'm yet to see this as an option.
I use sonoff devices to control a number of items in the house but there are still failure cases that might leave the devices either running for too long, or not running at all. In particular I use Home Assistant to turn on things like sprinker circuits, or pool pumps, or to turn off fridges overnight (non-critical ones).
What would be great would be to be able to define a failsafe state (much like the power on state) that is triggered based on either disconnection from wifi, disconnection from the MQTT broker, or in response to an MQTT last will and testiment (LWT) topic being published. Home assistant allows the definition of a LWT but this seems to be a single global LWT that occurs when it dies or disconnects. Being able to configure ESPURNA to subscribe to a particular topic and revert to failsafe mode (configurable either on or off per relay) would be a great step towards being more robust as a complete system.
If this work isn't planned or hasn't been done yet then I'll look at doing the development work and creating a pull request but I don't want to double up on someone elses effort.
Thanks
Jarrad
The text was updated successfully, but these errors were encountered:
Audiobuzz
changed the title
Failsafe mode in response to MQTT dissconnect or last will topic event
Failsafe mode in response to MQTT disconnect or last will topic event
May 18, 2018
Thanks @xoseperez. That fixes half the problem, but doesn't help when the controlling applications (in my case home assistant) crashes/locks/disconnects from the mqtt broker. Thats what mqtt has LWT for but espurna has no way to define which topic to listen for and respond to.
Currently there is no way to subscribe to specific topics... so you will basically need a "translator" that listens to your HA LWT and translate forward it to your device(s) to turn them ON/OFF or whatever you want. In my case I would do it from outside (Node-RED for instance).
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 30 days if no further activity occurs. Thank you for your contributions.
This issue will be auto-closed because there hasn't been any activity for a few months. Feel free to open a new one if you still experience this problem.
I've been looking through the web interface and the documentation and I'm yet to see this as an option.
I use sonoff devices to control a number of items in the house but there are still failure cases that might leave the devices either running for too long, or not running at all. In particular I use Home Assistant to turn on things like sprinker circuits, or pool pumps, or to turn off fridges overnight (non-critical ones).
What would be great would be to be able to define a failsafe state (much like the power on state) that is triggered based on either disconnection from wifi, disconnection from the MQTT broker, or in response to an MQTT last will and testiment (LWT) topic being published. Home assistant allows the definition of a LWT but this seems to be a single global LWT that occurs when it dies or disconnects. Being able to configure ESPURNA to subscribe to a particular topic and revert to failsafe mode (configurable either on or off per relay) would be a great step towards being more robust as a complete system.
If this work isn't planned or hasn't been done yet then I'll look at doing the development work and creating a pull request but I don't want to double up on someone elses effort.
Thanks
Jarrad
The text was updated successfully, but these errors were encountered: