Skip to content
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

Add support for device registry #4582

Merged
merged 1 commit into from
Dec 10, 2018

Conversation

emontnemery
Copy link
Contributor

@emontnemery emontnemery commented Dec 10, 2018

Add support for Hass device registry
Also small adjustment of TOGGLE type button to make it easier to use in automations.

With support for device registry, entities will show up like this in Hass configuration UI:
image
(Configuration -> Integrations -> MQTT)

Note1: Due to the very long announcement message, setoption55 must be set to 1, otherwise device registry data is not announced.

Note 2: With support for device registry it is mandatory to define a unique ID (for example: MAC address, serial number etc) to identify the entities and devices. For Tasmota, MAC is the perfect choice and that's what's used in this PR. To not confuse Hass and create duplicated entities, the unique ID is now also used as a base for object id in the discovery messages.
This is a change from before, when topic was instead used a a base for the object id.
This means previously retained discovery messages must be manually cleared from the MQTT server!

@arendst arendst merged commit ab91668 into arendst:development Dec 10, 2018
gemu2015 pushed a commit to gemu2015/Sonoff-Tasmota that referenced this pull request Jan 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants