eschava / broadlink-mqtt

MQTT client to control BroadLink devices
MIT License
221 stars 60 forks source link

Add Birth and Last Will Message #71

Closed soloam closed 4 years ago

soloam commented 4 years ago

Hello, it would be nice to have a Birth Message and a Last Will message on the MQTT, this will allow to report the status of the connection.

Thank You

eschava commented 4 years ago

The next parameters were added to the default configuration:

mqtt_birth_topic = 'clients/broadlink'

mqtt_birth_payload = 'Hello!'

mqtt_will_topic = 'clients/broadlink' mqtt_will_payload = 'Adios!'

soloam commented 4 years ago

Thank you, 🙏

soloam commented 4 years ago

Hello @eschava thank you for your work on this, very simple to use but so useful! Is it possible to make the birth and will message retained? (or make it optional in the config), only this message! This is useful to know the status of the client on the controller (for example home assistant) start. If The controller starts after the broadlink client, it will not receive the bridge status if this is not retained.