Zigbee2MQTT - device not updating HA state

Hi all,

I’ve been trying to sort this out with the Z2M developers here https://github.com/zigbee2mqtt/hassio-zigbee2mqtt/issues/359 but not seeming to find a resolution.

Ultimately I have a zigbee blind motor (Current Products ewand Gen 2) that works in Z2M via tilt (0 closed, 100 open). I don’t believe I’m the only one experiencing this see https://github.com/Koenkk/zigbee2mqtt/issues/9604#issuecomment-990081588.

Z2M has OPEN, STOP and CLOSED states shown, but HA always shows “unknown” for state.

I’ve tried changing the state in MQTT via MQTT Explorer to say “open” instead of “OPEN” but this has made no difference to HA state.

Anyone got any ideas what’s going on, and if this is something the Z2M team need to adjust or HA is missing? Happy to provide whatever logs people need (some already via the github link above).

Thanks,
Shane.

I think I may be on to something thanks to this comment.

I added this to my HA configuration.yaml and this Test Blind is presenting a state to HA and controlling the blind fine.

mqtt:
  cover:
    - name: "Test Blinds"
      json_attributes_topic: "zigbee2mqtt/Blinds - Back Lounge 1"
      position_topic: "zigbee2mqtt/Blinds - Back Lounge 1"
      position_template: "{{ value_json.tilt }}"
      set_position_topic: "zigbee2mqtt/Blinds - Back Lounge 1/set/tilt"
      command_topic: "zigbee2mqtt/Blinds - Back Lounge 1/set/tilt"
      position_open: 100
      position_closed: 0
      payload_open: "100"
      payload_close: "0"
      payload_stop: "STOP"