node-zwave-js: ZEN30 dimmer + switch associating actions with the wrong entity in HA

A dev told me to report this here, not an issue with Home Assistant

  • [ X] I am not using HomeAssistant. Or: a developer has told me to come here.
  • [ X] I am not using ZWaveJS2MQTT. Or: a developer has told me to come here.
  • [ X] I have checked the troubleshooting section and my problem is not described there.
  • [ X] I have read the changelog and my problem was not mentioned there.

The ZEN30 device has a dimmer-switch and a seperate relay switch. These appear as two entities in HomeAssistant - light.xxx for the dimmer and switch.xxx for the relay-switch. When controlling from HA both work perfectly. But any action on the dimmer done on the device gets repo as a change on the “switch” entity.

This was reported on the zwavejs2mqtt slack channel and user “Blowhard2” at that site said “we need to add a compat flag. We are mapping the report to the wrong endpoint”. He asked me to open an issue here.

Device information

Which device(s) is/are affected (make/model)? Zooz ZEN30 dual dimmer+switch What are the node IDs?

Did you change anything?

  • Yes: (please describe)
  • [ X] No

Did this use to work before?

  • [ X] Don’t know, this is a new device
  • No, it never worked anywhere
  • Yes, in: (specify application with versions)

How are you using node-zwave-js

  • [ X] zwavejs2mqtt (latest) docker image (4.0.0)
  • zwavejs2mqtt (dev) docker image
  • zwavejs2mqtt Manual Docker build
    • node-zwave-js branch:
    • zwavejs2mqtt branch:
  • ioBroker.zwave2 adapter
  • [ X] HomeAssistant version XYZ (HA Version 2021.4.6
  • Pkg
  • Manual Docker build
    • node-zwave-js branch:
    • zwavejs2mqtt branch:
  • node-red-contrib-zwave-js
    • Module version (double click node):
  • Manually built (as described in the docs)
  • Other:

To Reproduce

Steps to reproduce the behavior:

Setup zwavejs2mqtt with HA Install/associate ZEN30 switch Test that both entities are crated in HA and from HA control the correct part of the device Turn the dimmer on or off at the device Notice that state changes on the “switch” entity and not the “light” <-- this is the symptom of the bug Turn the relay switch on or off at the device Notice that the correct entity (the switch) change is reflected in HA

Additional context

N/A

Logfile:

N/A

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 1
  • Comments: 44 (16 by maintainers)

Most upvoted comments

@AlCalzone Awesome work!

I just setup a local debugging environment and can confirm .getEndpoint(1).supportsCC(CommandClasses.Basic) returns false for your change and true for master branch after restart.

Found it. That took a lot of semi-interactive debugging over the pond 😅

We don’t keep device polled information in the files. Endpoints get queried directly from the device on the fly. It is really just configuration parameters and if we need to pretty up the name of the association groups.

We work with Zooz on an ongoing basis and get samples of pretty much all of their devices. They’ve already sent me one for testing. We’re still working on this one its just a harder one to pin down that requires some debugging.

Not a problem at all. I’ve enabled silly level logging and set up a Node Red/MQTT notification for myself so I get notified when one of the nodes publishes to “zwave/nodeID_XX/32/1” (since I’ve noticed they only report a value for “32-1-currentValue” when they’re misbehaving). I’ll upload the logs when the issue arises again.

Thank you for all your help!

I am having the same issue. I have 5 ZEN30 switches and they all occasionally revert to behaving in this manner. A re-interview corrects the problem temporarily. I attempted to capture the logs and relevant information for node 22. Please let me know if you need additional info.

zwavejs_355.log zwavejs2mqtt.log

Export of “bad” state: bad_node22_json.txt Export of “good” state, after re-interviewing: good_node22_json.txt