zwave-js / zwave-js-ui

Full featured Z-Wave Control Panel UI and MQTT gateway. Built using Nodejs, and Vue/Vuetify
https://zwave-js.github.io/zwave-js-ui
MIT License
938 stars 200 forks source link

Target Endpoint not available for a muli-endpoint switch in Group associations #2709

Closed AaronSeibert closed 1 year ago

AaronSeibert commented 1 year ago

Checklist

Deploy method

Docker

Z-Wave JS UI version

8.0.2

ZwaveJS version

10.2.0

Describe the bug

The Group association tab has no option to set a target endpoint when adding a multi-endpoint target

To Reproduce

Using either Local or Double tap, add a new group association. When adding the group association and selecting a device with multiple endpoints, there is no UI option to set the target endpoint to be controlled. After adding the device, the Target Endpoint column shows None.

Expected behavior

For multi-endpoint devices, it is expected that one would be able to select the target endpoint when creating a direct association.

Additional context

Devices in use:

Controlling device: UltraPro In-Wall Paddle Dimmer, QFSW, 500S | 39351 / ZW3010, FW: v5.54 SDK: v6.81.3 Using Group 2 or Group 3 association

Target Device: Zooz Z-Wave Plus Power Strip, VER. 2.0 | ZEN20, FW: FW: v2.0.1 SDK: v6.71.3

AaronSeibert commented 1 year ago

My apologies, I've been looking at this for a bit and realized there has been an update a couple days ago - I just pulled the 8.1.0 docker image and verified the issue is still present.

robertsLando commented 1 year ago

@AaronSeibert are there any error on chrome console? COuld you also attach dirver/application logs of when you open the groups tab and try to add a new association?

AaronSeibert commented 1 year ago

@robertsLando - no failed requests or console errors in dev console other than a 404 for material icons.

Log lines for adding the association - note the UI doesn't surface a field for targetEndpoint.

2022-10-07 12:49:55.500 INFO Z-WAVE: Calling api addAssociations with args: [
  { nodeId: 26, endpoint: 0 },
  2,
  [ { nodeId: 28 }, [length]: 1 ],
  [length]: 3
]
2022-10-07 12:49:55.502 INFO Z-WAVE: Associations: Adding Node 28 to Group 2 of Node 26
12:49:56.307 DRIVER   Dropping message with invalid payload
12:49:56.400 DRIVER   Dropping message with invalid payload
12:49:56.446 DRIVER   Dropping message with invalid payload
2022-10-07 12:49:56.501 INFO Z-WAVE: Calling api getAssociations with args: [ 26, [length]: 1 ]
2022-10-07 12:49:56.502 INFO Z-WAVE: Success zwave api call getAssociations [
  { endpoint: 0, groupId: 1, nodeId: 1, targetEndpoint: undefined },
  { endpoint: 0, groupId: 3, nodeId: 1, targetEndpoint: undefined },
  [length]: 2
]
2022-10-07 12:49:56.921 INFO Z-WAVE: Success zwave api call addAssociations undefined
2022-10-07 12:49:58.069 INFO Z-WAVE: Node 19: value updated: 50-0-value-66049 8.8 => 8.8
2022-10-07 12:50:01.751 INFO Z-WAVE: Node 28: value updated: 50-1-value-66049 8.4 => 8.4
2022-10-07 12:50:02.338 INFO Z-WAVE: Calling api getAssociations with args: [ 26, [length]: 1 ]
2022-10-07 12:50:02.340 INFO Z-WAVE: Success zwave api call getAssociations [
  { endpoint: 0, groupId: 1, nodeId: 1, targetEndpoint: undefined },
  { endpoint: 0, groupId: 2, nodeId: 28, targetEndpoint: undefined },
  { endpoint: 0, groupId: 3, nodeId: 1, targetEndpoint: undefined },
  [length]: 3
]
2022-10-07 12:50:02.352 INFO Z-WAVE: Node 28: value updated: 50-2-value-66049 0 => 0
2022-10-07 12:50:02.949 INFO Z-WAVE: Node 28: value updated: 50-3-value-66049 0 => 0
2022-10-07 12:50:03.549 INFO Z-WAVE: Node 28: value updated: 50-4-value-66049 0 => 0
2022-10-07 12:50:04.149 INFO Z-WAVE: Node 28: value updated: 50-5-value-66049 0 => 0
2022-10-07 12:50:04.750 INFO Z-WAVE: Node 28: value updated: 50-0-value-66049 8.4 => 8.4
2022-10-07 12:50:07.665 INFO Z-WAVE: Calling api removeAssociations with args: [
  { nodeId: 26, endpoint: 0 },
  2,
  [ { nodeId: 28 }, [length]: 1 ],
  [length]: 3
]
2022-10-07 12:50:07.667 INFO Z-WAVE: Associations: Removing associations from Node 26 Group 2: [ { nodeId: 28 }, [length]: 1 ]
2022-10-07 12:50:08.483 INFO Z-WAVE: Success zwave api call removeAssociations undefined
2022-10-07 12:50:08.717 INFO Z-WAVE: Calling api getAssociations with args: [ 26, [length]: 1 ]
2022-10-07 12:50:08.718 INFO Z-WAVE: Success zwave api call getAssociations [
  { endpoint: 0, groupId: 1, nodeId: 1, targetEndpoint: undefined },
  { endpoint: 0, groupId: 3, nodeId: 1, targetEndpoint: undefined },
  [length]: 2
]

Debug info for association target: https://gist.github.com/AaronSeibert/3776e72a40b3ae800a228c6e4058ef19 Debug info for switch I'm adding the association to: https://gist.github.com/AaronSeibert/b038a4338d747ed570def469824a1665

Both devices are on latest firmware from vendors

robertsLando commented 1 year ago

note the UI doesn't surface a field for targetEndpoint.

This means that the node simply doesn't support it. Could you go on node debug tab and paste the content here?

AaronSeibert commented 1 year ago

@robertsLando They're in the gists linked below the log

robertsLando commented 1 year ago

@robertsLando They're in the gists linked below the log

Sorry I have missed them. I need to check code

robertsLando commented 1 year ago

Ok found it. The problem is that yes the target node has multiple endpoints but the node groups doens't support multiChannel associations. So you cannot specify the target endpoint

Code: https://github.com/zwave-js/zwave-js-ui/blob/master/src/components/dialogs/DialogAssociation.vue#L83

AaronSeibert commented 1 year ago

Thanks! Is that something that Jasco needs to address via firmware?

robertsLando commented 1 year ago

I don't know if a firmware update could handle that but I don't think so.

cc @kpine @AlCalzone @blhoward2

kpine commented 1 year ago

I'm sure it's technically possible, but adding the Multi-Channel Association CC to an existing device might require complete re-certification, which they might not want to do. Ultimately Jasco is the only one that can answer the question. The device in its current form does not support it.

You can look for devices certified with Z-Wave Plus V2 to support this use case, they are required to implement MCA, even if they have no MC functionality. For example, my Zooz ZEN72 supports it.

AaronSeibert commented 1 year ago

Yeah, the zooz device that I'm looking to add to the switch's group 2 supports multi-target, but the switch itself doesn't - so I'm guessing both devices need to support it.

Thanks y'all - this is good info to know and these aren't critical for offline control so I'll just do an automation in Node-Red.

AlCalzone commented 1 year ago

The source device on which you create the multi channel association must support the CC and the association group must have multi channel support too.

The target device that should be added there just needs to have multiple endpoints.