bieniu/ha-shellies-discovery-gen2

MQTT integration does not detect the devices

Closed this issue · 22 comments

Describe the bug
It's probably not a real bug but a mistake on my part.
The data all arrive in the MQTT broker and are also updated. I can see temperature values, etc. However, the MQTT integration does not detect the new entities.

Expected behavior
The MQTT integration shows the new entities

Versions:

  • Home Assistant: 2024.11.1
  • Shellies Discovery GEN2: 3.5.2
  • Shelly device firmware:
    • Shelly BLU Gateway Gen3: 20241021-140344/1.4.99-blugwg3prod4-g110402b
    • 2x Shelly BLU TRV: 20241011-050134/v1.0.1@ed260994

Shellies Discovery GEN2 automations:

- id: shellies_announce_gen2
  alias: "Shellies Announce Gen2"
  triggers:
    - platform: homeassistant
      event: start
  variables:
    get_config_payload: "{{ {'id': 1, 'src': 'shellies_discovery', 'method': 'Shelly.GetConfig'} | to_json }}"
    get_components_payload: "{{ {'id': 1, 'src': 'shellies_discovery', 'method':'Shelly.GetComponents'} | to_json }}"
    device_ids:  # enter the list of device IDs (MQTT prefixes) here
      - blu-gateway-kitchen
  actions:
    - repeat:
        for_each: "{{ device_ids }}"
        sequence:
          - action: mqtt.publish
            data:
              topic: "{{ repeat.item }}/rpc"
              payload: "{{ get_config_payload }}"
          - service: mqtt.publish
            data:
              topic: "{{ repeat.item }}/rpc"
              payload: "{{ get_components_payload }}"

- id: shellies_discovery_gen2
  alias: "Shellies Discovery Gen2"
  mode: queued
  max: 999
  triggers:
    - platform: mqtt
      topic: shellies_discovery/rpc
  actions:
    - action: python_script.shellies_discovery_gen2
      data:
        id: "{{ trigger.payload_json.src }}"
        device_config: "{{ trigger.payload_json.result }}"
    - condition: template
      value_template: "{{ 'mqtt' in trigger.payload_json.result }}"
    - service: mqtt.publish
      data:
        topic: "{{ trigger.payload_json.result.mqtt.topic_prefix }}/command"
        payload: "status_update"

Shelly device MQTT settings:

Debug log:

home-assistant.log

First of all... I think you forgot something
obraz

Besides that, your Shellies Announce automation needs update and there is nothing interesting in the log, it seems that device didn't respond to the correct topic. Maybe MQTT prefix is wrong?

Yeah you're right I'm sorry.
Here are the MQTT settings:
image

After upgrading the automation.yaml I have found a new error in the log after restarting:

2024-11-14 22:01:11.114 INFO (MainThread) [homeassistant.components.automation.shellies_announce_gen2] Shellies Announce Gen2: Running automation actions
2024-11-14 22:01:11.114 INFO (MainThread) [homeassistant.components.automation.shellies_announce_gen2] Shellies Announce Gen2: Repeating sequence: Iteration 1 of 1 with item: 'blu-gateway-kitchen'
2024-11-14 22:01:11.115 INFO (MainThread) [homeassistant.components.automation.shellies_announce_gen2] Shellies Announce Gen2: Repeat at step 1: Running automation actions
2024-11-14 22:01:11.115 INFO (MainThread) [homeassistant.components.automation.shellies_announce_gen2] Shellies Announce Gen2: Repeat at step 1: Executing step call service
2024-11-14 22:01:11.115 INFO (MainThread) [homeassistant.components.automation.shellies_announce_gen2] Initialized trigger Shellies Announce Gen2
2024-11-14 22:01:11.115 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Initialized trigger Shellies Discovery Gen2
2024-11-14 22:01:11.123 INFO (MainThread) [homeassistant.components.automation.shellies_announce_gen2] Shellies Announce Gen2: Repeat at step 1: Executing step call service
2024-11-14 22:01:12.272 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Running automation actions
2024-11-14 22:01:12.272 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Executing step call service
2024-11-14 22:01:12.621 INFO (SyncWorker_5) [homeassistant.components.python_script] Executing shellies_discovery_gen2.py: {'id': 'shellyblugwg3-e4b323168fa0', 'device_config': {'components': [{'key': 'ble', 'config': {'enable': True, 'rpc': {'enable': True}}}, {'key': 'blugw', 'config': {'sys_led_enable': True}}, {'key': 'blutrv:200', 'config': {'id': 200, 'addr': 'f8:44:77:2c:02:e7', 'name': 'TRV Badezimmer', 'key': None, 'trv': 'bthomedevice:200', 'temp_sensors': [], 'dw_sensors': [], 'meta': {}}}, {'key': 'blutrv:201', 'config': {'id': 201, 'addr': '28:db:a7:b5:f0:a3', 'name': 'TRV Küche', 'key': None, 'trv': 'bthomedevice:201', 'temp_sensors': [], 'dw_sensors': [], 'meta': {}}}, {'key': 'bthome', 'config': {}}, {'key': 'bthomedevice:200', 'config': {'id': 200, 'addr': 'f8:44:77:2c:02:e7', 'name': 'TRV Badezimmer', 'key': None, 'meta': None}, 'attrs': {'flags': 17, 'model_id': 8}}, {'key': 'bthomedevice:201', 'config': {'id': 201, 'addr': '28:db:a7:b5:f0:a3', 'name': 'TRV Küche', 'key': None, 'meta': None}, 'attrs': {'flags': 17, 'model_id': 8}}, {'key': 'bthomedevice:202', 'config': {'id': 202, 'addr': '7c:c6:b6:63:39:41', 'name': None, 'key': None, 'meta': {'ui': {'view': 'regular', 'local_name': 'SBHT-003C'}}}, 'attrs': {'flags': 0, 'model_id': 3}}, {'key': 'bthomesensor:200', 'config': {'id': 200, 'addr': 'f8:44:77:2c:02:e7', 'name': None, 'obj_id': 1, 'idx': 0, 'meta': None}}, {'key': 'bthomesensor:201', 'config': {'id': 201, 'addr': 'f8:44:77:2c:02:e7', 'name': None, 'obj_id': 58, 'idx': 0, 'meta': None}}, {'key': 'bthomesensor:202', 'config': {'id': 202, 'addr': 'f8:44:77:2c:02:e7', 'name': None, 'obj_id': 69, 'idx': 0, 'meta': None}}, {'key': 'bthomesensor:203', 'config': {'id': 203, 'addr': 'f8:44:77:2c:02:e7', 'name': None, 'obj_id': 69, 'idx': 1, 'meta': None}}, {'key': 'bthomesensor:204', 'config': {'id': 204, 'addr': '28:db:a7:b5:f0:a3', 'name': None, 'obj_id': 1, 'idx': 0, 'meta': None}}, {'key': 'bthomesensor:205', 'config': {'id': 205, 'addr': '28:db:a7:b5:f0:a3', 'name': None, 'obj_id': 58, 'idx': 0, 'meta': None}}, {'key': 'bthomesensor:206', 'config': {'id': 206, 'addr': '28:db:a7:b5:f0:a3', 'name': None, 'obj_id': 69, 'idx': 0, 'meta': None}}, {'key': 'bthomesensor:207', 'config': {'id': 207, 'addr': '28:db:a7:b5:f0:a3', 'name': None, 'obj_id': 69, 'idx': 1, 'meta': None}}, {'key': 'bthomesensor:208', 'config': {'id': 208, 'addr': '7c:c6:b6:63:39:41', 'name': None, 'obj_id': 1, 'idx': 0, 'meta': None}}], 'cfg_rev': 1984, 'offset': 0, 'total': 26}}
2024-11-14 22:01:12.621 INFO (SyncWorker_5) [homeassistant.components.python_script.shellies_discovery_gen2.py] Shellies Discovery Gen2 version: 3.5.2
2024-11-14 22:01:12.621 ERROR (SyncWorker_5) [homeassistant.components.python_script.shellies_discovery_gen2.py] Error executing script
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/python_script/__init__.py", line 270, in execute
    exec(compiled.code, restricted_globals)  # noqa: S102
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "shellies_discovery_gen2.py", line 4190, in <module>
ValueError: Missing MQTT component, probably 'Shelly.GetComponent' pagination problem
2024-11-14 22:01:12.624 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Test condition template: False

The log is incomplete.

Yes, the rest is actually uninteresting, so I had shortened it to the essentials, but here is the complete one
home-assistant (1).log

The device still doesn’t respond to Shelly.GetConfig.

BTW 2xBLU TRV for one gateway is not supported by the script. This is why you can see an error. #498

But this is not related to the lack of Shelly.GetConfig response.

I have just seen that although the data is permanently updated in the MQTT Explorer, offline = false is still displayed

image

offline = false is still displayed

This is known issue (Shelly team knows it) but it is unrelated here.

Do you have any idea what the problem could be? Any tips on where I could look? I am still relatively new to the HomeAssistant cosmos.

Is it maybe my python_script folder? I copied the files from the repo. It contains the following files:
image

announce automation sends Shelly.GetConfig request to device via MQTT broker, device must respond to shellies_discovery topic. I don't see this response in log, so from my point of view the problem is the connection between device and MQTT broker or between MQTT broker and HA server.

python_scripts folder should contain ONLY shellies_discovery_gen2.py file.

To be honest, I’m at a loss as to where exactly the issue lies and what I might have configured incorrectly. Is there perhaps any additional information I can provide to help us find a solution?

Unfortunately it's hard to tell where to look for the problem. I don't know your network so I don't know what's wrong. Try sending a Shelly.GetConfig request and observing the result.

When I call the API via the IP, I get the following response. But it looks good to me so far. I have censored my location.

{
    "ble": {
        "enable": true,
        "rpc": {
            "enable": true
        }
    },
    "blugw": {
        "sys_led_enable": true
    },
    "bthome": {},
    "cloud": {
        "enable": true,
        "server": "shelly-134-eu.shelly.cloud:6022/jrpc"
    },
    "mqtt": {
        "enable": true,
        "server": "192.168.178.77:1883",
        "client_id": "blu-gateway-kitchen",
        "user": "benny",
        "ssl_ca": null,
        "topic_prefix": "blu-gateway-kitchen",
        "rpc_ntf": true,
        "status_ntf": true,
        "use_client_cert": false,
        "enable_rpc": true,
        "enable_control": true
    },
    "script:1": {
        "id": 1,
        "name": "aioshelly_ble_integration",
        "enable": false
    },
    "sys": {
        "device": {
            "name": "blu-gateway-kitchen",
            "mac": "E4B323168FA0",
            "fw_id": "20241021-140344/1.4.99-blugwg3prod4-g110402b",
            "discoverable": true,
            "eco_mode": false
        },
        "location": {
            "tz": "Europe/Berlin",
            "lat": xxxx,
            "lon": xxxx
        },
        "debug": {
            "level": 2,
            "file_level": null,
            "mqtt": {
                "enable": false
            },
            "websocket": {
                "enable": true
            },
            "file_log": {
                "enable": false
            },
            "udp": {
                "addr": null
            }
        },
        "ui_data": {},
        "rpc_udp": {
            "dst_addr": null,
            "listen_port": null
        },
        "sntp": {
            "server": "time.cloudflare.com"
        },
        "cfg_rev": 2719
    },
    "wifi": {
        "ap": {
            "ssid": "ShellyBluGwG3-E4B323168FA0",
            "is_open": false,
            "enable": true,
            "range_extender": {
                "enable": false
            }
        },
        "sta": {
            "ssid": "Katholische Weihwasserwerke",
            "is_open": false,
            "enable": true,
            "ipv4mode": "static",
            "ip": "192.168.178.81",
            "netmask": "255.255.255.0",
            "gw": "192.168.178.1",
            "nameserver": null
        },
        "sta1": {
            "ssid": null,
            "is_open": true,
            "enable": false,
            "ipv4mode": "dhcp",
            "ip": null,
            "netmask": null,
            "gw": null,
            "nameserver": null
        },
        "roam": {
            "rssi_thr": -80,
            "interval": 60
        }
    },
    "ws": {
        "enable": false,
        "server": null,
        "ssl_ca": "ca.pem"
    }
}

We need this response via MQTT.

Since I didn't know exactly how this works, I simply followed Shelly's documentation and hope that it is correct. But I think the answer is quite short, don't you?

{
    "id": 1,
    "src": "shellyblugwg3-e4b323168fa0",
    "result": {
        "enable": true,
        "server": "192.168.178.77:1883",
        "client_id": "blu-gateway-kitchen",
        "user": "benny",
        "ssl_ca": null,
        "topic_prefix": "blu-gateway-kitchen",
        "rpc_ntf": true,
        "status_ntf": true,
        "use_client_cert": false,
        "enable_rpc": true,
        "enable_control": true
    }
}

I doubt this is a response to Shelly.GetConfig. You need to send the payload {"id": 0, "src": "shellies_discovery", "method": "Shelly.GetConfig"} to the topic blu-gateway-kitchen/rpc.

After that, I have bunch of new topics under the gateway topic
image

This is the blu-gateway-kitchen/rpc topic:

{
    "ble": {},
    "blugw": {},
    "bthome": {},
    "cloud": {
        "connected": true
    },
    "mqtt": {
        "connected": true
    },
    "script:1": {
        "id": 1,
        "running": false,
        "mem_free": 24164
    },
    "script:2": {
        "id": 2,
        "running": true,
        "mem_used": 1022,
        "mem_peak": 3976,
        "mem_free": 24164
    },
    "sys": {
        "mac": "E4B323168FA0",
        "restart_required": false,
        "time": "22:59",
        "unixtime": 1731880765,
        "uptime": 212306,
        "ram_size": 253940,
        "ram_free": 69584,
        "ram_min_free": 28196,
        "fs_size": 1048576,
        "fs_free": 565248,
        "cfg_rev": 2739,
        "kvs_rev": 0,
        "schedule_rev": 1,
        "webhook_rev": 0,
        "available_updates": {},
        "reset_reason": 3,
        "installed_version": "1.4.99-blugwg3prod4"
    },
    "wifi": {
        "sta_ip": "192.168.178.81",
        "status": "got ip",
        "ssid": "Katholische Weihwasserwerke",
        "rssi": -60
    },
    "ws": {
        "connected": false
    }
}

Also I have now an extra shellies_discovery/rpc topic with this response:

{
    "id": 0,
    "src": "shellyblugwg3-e4b323168fa0",
    "dst": "shellies_discovery",
    "result": {
        "ble": {
            "enable": true,
            "rpc": {
                "enable": true
            }
        },
        "blugw": {
            "sys_led_enable": true
        },
        "bthome": {},
        "cloud": {
            "enable": true,
            "server": "shelly-134-eu.shelly.cloud:6022/jrpc"
        },
        "mqtt": {
            "enable": true,
            "server": "192.168.178.77:1883",
            "client_id": "blu-gateway-kitchen",
            "user": "benny",
            "ssl_ca": null,
            "topic_prefix": "blu-gateway-kitchen",
            "rpc_ntf": true,
            "status_ntf": true,
            "use_client_cert": false,
            "enable_rpc": true,
            "enable_control": true
        },
        "script:1": {
            "id": 1,
            "name": "aioshelly_ble_integration",
            "enable": false
        },
        "script:2": {
            "id": 2,
            "name": "shellies_discovery_gen2_script_20240216",
            "enable": true
        },
        "sys": {
            "device": {
                "name": "blu-gateway-kitchen",
                "mac": "E4B323168FA0",
                "fw_id": "20241021-140344/1.4.99-blugwg3prod4-g110402b",
                "discoverable": true,
                "eco_mode": false
            },
            "location": {
                "tz": "Europe/Berlin",
                "lat": xxx,
                "lon": xxx
            },
            "debug": {
                "level": 2,
                "file_level": null,
                "mqtt": {
                    "enable": false
                },
                "websocket": {
                    "enable": true
                },
                "file_log": {
                    "enable": false
                },
                "udp": {
                    "addr": null
                }
            },
            "ui_data": {},
            "rpc_udp": {
                "dst_addr": null,
                "listen_port": null
            },
            "sntp": {
                "server": "time.cloudflare.com"
            },
            "cfg_rev": 2739
        },
        "wifi": {
            "ap": {
                "ssid": "ShellyBluGwG3-E4B323168FA0",
                "is_open": false,
                "enable": true,
                "range_extender": {
                    "enable": false
                }
            },
            "sta": {
                "ssid": "Katholische Weihwasserwerke",
                "is_open": false,
                "enable": true,
                "ipv4mode": "static",
                "ip": "192.168.178.81",
                "netmask": "255.255.255.0",
                "gw": "192.168.178.1",
                "nameserver": null
            },
            "sta1": {
                "ssid": null,
                "is_open": true,
                "enable": false,
                "ipv4mode": "dhcp",
                "ip": null,
                "netmask": null,
                "gw": null,
                "nameserver": null
            },
            "roam": {
                "rssi_thr": -80,
                "interval": 60
            }
        },
        "ws": {
            "enable": false,
            "server": null,
            "ssl_ca": "ca.pem"
        }
    }
}

I hope this helps

And this response should trigger shellies_discovery_gen2 automation. You can check this in the automation trace.

Now I have this output in the log:

2024-11-17 22:54:53.364 INFO (MainThread) [homeassistant.components.mqtt.discovery] Found new component: binary_sensor shellyblugwg3-e4b323168fa0-cloud from external application Shellies Discovery Gen2, version: 3.5.2, support URL: https://github.com/bieniu/ha-shellies-discovery-gen2
2024-11-17 22:54:53.366 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Test condition template: True
2024-11-17 22:54:53.366 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Executing step call service
2024-11-17 22:58:12.673 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Running automation actions
2024-11-17 22:58:12.673 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Executing step call service
2024-11-17 22:58:12.800 INFO (SyncWorker_32) [homeassistant.components.python_script] Executing shellies_discovery_gen2.py: {'id': 'shellyblugwg3-e4b323168fa0', 'device_config': {'ble': {'enable': True, 'rpc': {'enable': True}}, 'blugw': {'sys_led_enable': True}, 'bthome': {}, 'cloud': {'enable': True, 'server': 'shelly-134-eu.shelly.cloud:6022/jrpc'}, 'mqtt': {'enable': True, 'server': '192.168.178.77:1883', 'client_id': 'blu-gateway-kitchen', 'user': 'benny', 'ssl_ca': None, 'topic_prefix': 'blu-gateway-kitchen', 'rpc_ntf': True, 'status_ntf': True, 'use_client_cert': False, 'enable_rpc': True, 'enable_control': True}, 'script:1': {'id': 1, 'name': 'aioshelly_ble_integration', 'enable': False}, 'script:2': {'id': 2, 'name': 'shellies_discovery_gen2_script_20240216', 'enable': True}, 'sys': {'device': {'name': 'blu-gateway-kitchen', 'mac': 'E4B323168FA0', 'fw_id': '20241021-140344/1.4.99-blugwg3prod4-g110402b', 'discoverable': True, 'eco_mode': False}, 'location': {'tz': 'Europe/Berlin', 'lat': 52.8829, 'lon': 7.9704}, 'debug': {'level': 2, 'file_level': None, 'mqtt': {'enable': False}, 'websocket': {'enable': True}, 'file_log': {'enable': False}, 'udp': {'addr': None}}, 'ui_data': {}, 'rpc_udp': {'dst_addr': None, 'listen_port': None}, 'sntp': {'server': 'time.cloudflare.com'}, 'cfg_rev': 2739}, 'wifi': {'ap': {'ssid': 'ShellyBluGwG3-E4B323168FA0', 'is_open': False, 'enable': True, 'range_extender': {'enable': False}}, 'sta': {'ssid': 'Katholische Weihwasserwerke', 'is_open': False, 'enable': True, 'ipv4mode': 'static', 'ip': '192.168.178.81', 'netmask': '255.255.255.0', 'gw': '192.168.178.1', 'nameserver': None}, 'sta1': {'ssid': None, 'is_open': True, 'enable': False, 'ipv4mode': 'dhcp', 'ip': None, 'netmask': None, 'gw': None, 'nameserver': None}, 'roam': {'rssi_thr': -80, 'interval': 60}}, 'ws': {'enable': False, 'server': None, 'ssl_ca': 'ca.pem'}}}
2024-11-17 22:58:12.800 INFO (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Shellies Discovery Gen2 version: 3.5.2
2024-11-17 22:58:12.801 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/button/shellyblugwg3-e4b323168fa0-restart/config {"name": "Restart", "cmd_t": "~rpc", "en": "true", "uniq_id": "shellyblugwg3-e4b323168fa0-restart", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "pl_prs": "{\"id\":1,\"src\":\"home-assistant\",\"method\":\"Shelly.Reboot\"}", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "dev_cla": "restart", "ent_cat": "config"}
2024-11-17 22:58:12.802 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/sensor/shellyblugwg3-e4b323168fa0-last_restart/config {"name": "Last restart", "en": "true", "uniq_id": "shellyblugwg3-e4b323168fa0-last_restart", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "val_tpl": "{{(as_timestamp(now())-value_json.uptime)|timestamp_local}}", "stat_t": "~status/sys", "dev_cla": "timestamp", "ent_cat": "diagnostic"}
2024-11-17 22:58:12.803 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/sensor/shellyblugwg3-e4b323168fa0-ssid/config {"name": "SSID", "en": "false", "uniq_id": "shellyblugwg3-e4b323168fa0-ssid", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "val_tpl": "{{value_json.ssid}}", "stat_t": "~status/wifi", "icon": "mdi:wifi-settings", "ent_cat": "diagnostic"}
2024-11-17 22:58:12.806 INFO (MainThread) [homeassistant.components.mqtt.discovery] Found new component: sensor shellyblugwg3-e4b323168fa0-ssid from external application Shellies Discovery Gen2, version: 3.5.2, support URL: https://github.com/bieniu/ha-shellies-discovery-gen2
2024-11-17 22:58:12.807 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/sensor/shellyblugwg3-e4b323168fa0-wifi_ip/config {"name": "WiFi IP", "en": "false", "uniq_id": "shellyblugwg3-e4b323168fa0-wifi_ip", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "val_tpl": "{{value_json.sta_ip}}", "stat_t": "~status/wifi", "icon": "mdi:ip-outline", "ent_cat": "diagnostic"}
2024-11-17 22:58:12.809 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/sensor/shellyblugwg3-e4b323168fa0-wifi_signal/config {"name": "Signal strength", "en": "true", "uniq_id": "shellyblugwg3-e4b323168fa0-wifi_signal", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "val_tpl": "{{value_json.rssi}}", "stat_t": "~status/wifi", "unit_of_meas": "dBm", "dev_cla": "signal_strength", "ent_cat": "diagnostic", "stat_cla": "measurement"}
2024-11-17 22:58:12.811 INFO (MainThread) [homeassistant.components.mqtt.discovery] Found new component: sensor shellyblugwg3-e4b323168fa0-wifi_ip from external application Shellies Discovery Gen2, version: 3.5.2, support URL: https://github.com/bieniu/ha-shellies-discovery-gen2
2024-11-17 22:58:12.814 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/binary_sensor/shellyblugwg3-e4b323168fa0-cloud/config {"name": "Cloud", "val_tpl": "{%if value_json.connected%}ON{%else%}OFF{%endif%}", "en": "false", "uniq_id": "shellyblugwg3-e4b323168fa0-cloud", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "stat_t": "~status/cloud", "dev_cla": "connectivity", "ent_cat": "diagnostic"}
2024-11-17 22:58:12.816 DEBUG (SyncWorker_32) [homeassistant.components.python_script.shellies_discovery_gen2.py] Sending to MQTT broker: homeassistant/binary_sensor/shellyblugwg3-e4b323168fa0-firmware/config {"name": "Firmware", "val_tpl": "{%if value_json.available_updates.stable is defined%}ON{%else%}OFF{%endif%}", "en": "true", "uniq_id": "shellyblugwg3-e4b323168fa0-firmware", "qos": 0, "dev": {"cns": [["mac", "e4:b3:23:16:8f:a0"]], "ids": ["e4:b3:23:16:8f:a0"], "name": "blu-gateway-kitchen", "mdl": "Shelly BLU Gateway Gen3", "mdl_id": "S3GW-1DBT001", "sw": "20241021-140344/1.4.99-blugwg3prod4-g110402b", "hw": "gen3", "mf": "Allterco Robotics", "cu": "http://shellyblugwg3-e4b323168fa0.local/"}, "o": {"name": "Shellies Discovery Gen2", "sw": "3.5.2", "url": "https://github.com/bieniu/ha-shellies-discovery-gen2"}, "~": "blu-gateway-kitchen/", "avty": [{"t": "~online", "pl_avail": "true", "pl_not_avail": "false"}, {"t": "~status/rpc", "val_tpl": "{%if value_json.mqtt.connected%}online{%else%}offline{%endif%}"}], "stat_t": "~status/sys", "json_attr_t": "~status/sys", "json_attr_tpl": "{{value_json.available_updates.get(\"stable\",{})|to_json}}", "dev_cla": "update", "ent_cat": "diagnostic"}
2024-11-17 22:58:12.817 INFO (MainThread) [homeassistant.components.mqtt.discovery] Found new component: binary_sensor shellyblugwg3-e4b323168fa0-cloud from external application Shellies Discovery Gen2, version: 3.5.2, support URL: https://github.com/bieniu/ha-shellies-discovery-gen2
2024-11-17 22:58:12.819 DEBUG (SyncWorker_32) [homeassistant.components.python_script] Output of python_script: `shellies_discovery_gen2.py`:
{}
2024-11-17 22:58:12.820 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Test condition template: True
2024-11-17 22:58:12.820 INFO (MainThread) [homeassistant.components.automation.shellies_discovery_gen2] Shellies Discovery Gen2: Executing step call service

And now you can also find the gateway in the mqtt, but nothing more
image

but nothing more

What more do you expect?

I thought that since I see the data from my H&T in mqtt Broker, for example, that I would be offered it too