gdoor-org / gdoor

Wifi adapter and bus protocol documentation for the Gira TKS Door System
https://gdoor-org.github.io/
GNU General Public License v3.0
12 stars 3 forks source link

MQTT Discovery #17

Open DaSchaef opened 3 weeks ago

DaSchaef commented 3 weeks ago

I'm collecting infos about MQTT Discovery

{
    "sw_version": "3.0",
    "name": "GDOOR Gira Bus Adapter",
    "force_update": true,
    "icon": "mdi:door",
    "state_topic": "gdoor/rx",
    "command_topic": "gdoor/tx"
}

topic: homeassistant/sensor/gdoor/data/config

retention flag needed

jschroeter commented 3 weeks ago

Just for reference:

Nice to have: set the configuration_url to the IP of the adapter to get a link to the adapter UI (see https://developers.home-assistant.io/blog/2021/10/26/config-entity/).

DaSchaef commented 3 weeks ago

entity_category=config: we can also create config entries. entity_category=diagnostic: we can show status infos

jschroeter commented 3 weeks ago

Maybe useful as inspiration: https://github.com/tbnobody/OpenDTU/blob/master/src/MqttHandleHass.cpp

DaSchaef commented 3 weeks ago
{
    "name": "Bus Data",
    "force_update": True,
    "icon": "mdi:door",
    "state_topic": "gdoor/rx",
    "command_topic": "gdoor/tx",
    "json_attributes_topic": "gdoor/rx",
    "value_template": "{{ value_json.action }}",
    "uniq_id": "wfffedd_data",
    "device": {
        "sw_version": "3.0",
        "name": "GDOOR Adapter",
        "model": "ESP32 (de:ad:be:ef)",
        "manufacturer": "GDOOR Project",
        "configuration_url": "http://127.0.0.1",
        "ids": "hdisep"
    }
}