Zigbee2mqtt not auto detecting device

Greetings all:
i recently installed a slzb-06 and zigbee2mqtt. The install went as smoothly as i expected. I then paired 2 presence detector ( HOBEIAN), which paired without any issues. Both show in the z2m dashboard. The presence shows false or true appropriately, as does the temperature, light, humidity.
But no now devices show up in Homeassistant. So I looked in MQTT Explorer and found:

zigbee2mqtt/Sleeping Porch Presence z2m. As the topic and the json message:

{
"anti_interference": "ON",
"battery": 90,
"detection_distance": 5,
"device": {
"applicationVersion": 151,
"dateCode": "12052026",
"friendlyName": "Sleeping Porch Presence z2m",
"hardwareVersion": 1,
"ieeeAddr": "0xa4c1380f3e814033",
"manufacturerID": 4742,
"manufacturerName": "HOBEIAN",
"model": "ZG-204ZX",
"networkAddress": 48403,
"powerSource": "Battery",
"softwareBuildID": "0112052026",
"stackVersion": 2,
"type": "EndDevice",
"zclVersion": 3
},
"fading_time": 60,
"humidity": 53,
"humidity_calibration": 0,
"illuminance": 1491,
"illuminance_interval": 1,
"indicator": "OFF",
"linkquality": 153,
"motion_detection_sensitivity": 5,
"presence": false,
"static_detection_sensitivity": 4,
"temperature": 69.6,
"temperature_calibration": 0,
"temperature_unit": "fahrenheit"
}
The presence changes from true to false as expected.
So I know mosquitto is working as is the slzb-06 coordinator.

So I tried adding some configuration.yaml code for my mqtt.yaml for a binary-sensor:

binary_sensor:

  • name: Sleeping Porch Presence z2m
    unique_id: "Sleeping Porch Presence z2m"
    state_topic: "zigbee2mqtt/Sleeping Porch Presence z2m"
    value_template: "{{ state_json.presence }}"
    payload_on: "true"
    payload_off: "false"

but nothing shows up when I search under entities.

I'm stuck!
Any suggestions would be greatefully appreciated!
Thanks!

Might need to discover it, so restart HA possibly.

Thanks, I tried that, no difference. I think that I might go back to ZHA as that has worked well for me.
Frustrating!

  • In order for Home Assistant to discover Zigbee2MQTT's devices, it needs the MQTT integration installed and configured.

  • The MQTT integration provides Home Assistant with an MQTT client. This client connects to the MQTT Broker.

  • Once connected, it subscribes to MQTT topics beginning with homeassistant. Those are the topics that contain information for discovering and creating devices and entities.

If any link in this chain is broken, Home Assistant will not be able to discover Zigbee2MQTT's devices.

In addition to what @123 said above, it also needs the home assistant setting to be enabled Home Assistant integration | Zigbee2MQTT