No, the 10% was actually an intermediate level as the dimmer was ramping up from off to a higher value.
I moved this device (z-wave plus Jasco dimmer) to a driver by itself to make it easier to get a longer period of logs. Those are included at the bottom of this post. In these new logs the process is:
- Dimmer starts from on with the dim level set to 37%
- Turn off (
Switch
capability)
- Turn on (
Switch
capability)
I’ve figured out that the reports that are throwing the error are ones that are generated in the middle of the dimming transition. Per the spec, a mid-transition report should give the current value (23% in the example below as it’s midway through the transition) for value
and the value from the Set command (0xFF in this case) for the target_value
, so the report itself seems reasonable and one that the handler should anticipate.
I’m definitely starting to wonder whether that was the right choice, even outside of this error with 0xFF values for target_value
. The two parameters should give identical results for quick dimming transitions. But for longer transitions, using target_value
will give a premature report that the device has finished dimming.
I have a different Jasco switch set with a 10 second dimming transition. That one is a zigbee model, and the dimming events in the app track the slow increase in the device’s actual dim level as it moves toward the target. It could be good to switch from using target_value
to value
just to have consistency in how the two protocols are handled.
2022-02-01T17:54:56.568012219+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received Z-Wave command: {args={current_value=37, duration=0, target_value=37, value=37}, cmd_class="SWITCH_MULTILEVEL", cmd_id="REPORT", dst_channels={}, encap="S2_AUTH", payload="\x25\x25\x00", src_channel=0, version=4}
2022-02-01T17:54:56.585473886+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:54:56.591838886+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"switch","component_id":"main","state":{"value":"on"},"capability_id":"switch"}
2022-02-01T17:54:56.611118886+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:54:56.621899553+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"level","component_id":"main","state":{"value":37},"capability_id":"switchLevel"}
2022-02-01T17:54:56.642419553+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:54:56.648579886+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler capability
2022-02-01T17:54:56.667241886+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received command: {"positional_args":[],"command":"off","capability":"switch","args":[],"component":"main"}
2022-02-01T17:54:56.673921219+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found CapabilityCommandDispatcher handler in ge-zwave-switch
2022-02-01T17:54:56.679601553+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test SWITCH_MULTILEVEL supported.
2022-02-01T17:54:56.689363219+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> sending Z-Wave command: {args={duration=1, value="OFF_DISABLE"}, cmd_class="SWITCH_MULTILEVEL", cmd_id="SET", dst_channels={}, encap="AUTO", payload="\x00\x01", src_channel=0, version=2}
2022-02-01T17:54:56.708617886+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(5425da5a) queued for radio transmission: CC:Switch Multi-level, CID:0x01
2022-02-01T17:54:56.719088553+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:54:56.726998219+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:54:56.897514886+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(5425da5a) transmit status: TRANSMIT_COMPLETE_OK
2022-02-01T17:54:58.052976553+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler unnamed
2022-02-01T17:54:58.065206220+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received Z-Wave command: {args={value="OFF_DISABLE"}, cmd_class="SWITCH_MULTILEVEL", cmd_id="REPORT", dst_channels={}, encap="S2_AUTH", payload="\x00", src_channel=0, version=1}
2022-02-01T17:54:58.079197220+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:54:58.086101553+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"switch","component_id":"main","state":{"value":"off"},"capability_id":"switch"}
2022-02-01T17:54:58.105913220+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:54:58.111326553+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:00.970319221+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler capability
2022-02-01T17:55:01.016625555+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received command: {"positional_args":[],"command":"on","capability":"switch","args":[],"component":"main"}
2022-02-01T17:55:01.029931888+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found CapabilityCommandDispatcher handler in ge-zwave-switch
2022-02-01T17:55:01.041127222+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test SWITCH_MULTILEVEL supported.
2022-02-01T17:55:01.054936555+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> sending Z-Wave command: {args={duration=1, value="ON_ENABLE"}, cmd_class="SWITCH_MULTILEVEL", cmd_id="SET", dst_channels={}, encap="AUTO", payload="\xFF\x01", src_channel=0, version=2}
2022-02-01T17:55:01.101014555+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(bbd706a4) queued for radio transmission: CC:Switch Multi-level, CID:0x01
2022-02-01T17:55:01.127665888+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:01.134529222+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:01.213055222+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(bbd706a4) transmit status: TRANSMIT_COMPLETE_OK
2022-02-01T17:55:01.731558889+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> sending Z-Wave command: {args={}, cmd_class="SWITCH_MULTILEVEL", cmd_id="GET", dst_channels={}, encap="AUTO", payload="", src_channel=0, version=1}
2022-02-01T17:55:01.750994889+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(b1c92421) queued for radio transmission: CC:Switch Multi-level, CID:0x02
2022-02-01T17:55:01.756877889+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:01.929520222+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(b1c92421) transmit status: TRANSMIT_COMPLETE_OK
2022-02-01T17:55:01.948534889+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler unnamed
2022-02-01T17:55:01.958502889+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received Z-Wave command: {args={current_value=23, duration=0, target_value=255, value=23}, cmd_class="SWITCH_MULTILEVEL", cmd_id="REPORT", dst_channels={}, encap="S2_AUTH", payload="\x17\xFF\x00", src_channel=0, version=4}
2022-02-01T17:55:01.968475555+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:55:01.975061889+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"switch","component_id":"main","state":{"value":"on"},"capability_id":"switch"}
2022-02-01T17:55:01.994804555+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:55:02.003762222+00:00 ERROR GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights thread encountered error: [string "st/dispatcher.lua"]:229: Error encountered while processing event for <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)>:
arg1: {args={current_value=23, duration=0, target_value=255, value=23}, cmd_class="SWITCH_MULTILEVEL", cmd_id="REPORT", dst_channels={}, encap="S2_AUTH", payload="\x17\xFF\x00", src_channel=0, version=4}
[string "st/capabilities/init.lua"]:225: Value 255 is invalid for Switch Level.level
2022-02-01T17:55:03.321852223+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler unnamed
2022-02-01T17:55:03.331254556+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received Z-Wave command: {args={value=37}, cmd_class="BASIC", cmd_id="REPORT", dst_channels={}, encap="AUTO", payload="%", src_channel=0, version=1}
2022-02-01T17:55:03.355509556+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:55:03.362254556+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"switch","component_id":"main","state":{"value":"on"},"capability_id":"switch"}
2022-02-01T17:55:03.382072556+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:06.136893891+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> sending Z-Wave command: {args={}, cmd_class="SWITCH_MULTILEVEL", cmd_id="GET", dst_channels={}, encap="AUTO", payload="", src_channel=0, version=1}
2022-02-01T17:55:06.193714891+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(2f72ac24) queued for radio transmission: CC:Switch Multi-level, CID:0x02
2022-02-01T17:55:06.201314224+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:06.377398891+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Z-Wave command(2f72ac24) transmit status: TRANSMIT_COMPLETE_OK
2022-02-01T17:55:06.447995557+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler unnamed
2022-02-01T17:55:06.487426224+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> received Z-Wave command: {args={current_value=37, duration=0, target_value=37, value=37}, cmd_class="SWITCH_MULTILEVEL", cmd_id="REPORT", dst_channels={}, encap="S2_AUTH", payload="\x25\x25\x00", src_channel=0, version=4}
2022-02-01T17:55:06.611079558+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:55:06.654155891+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"switch","component_id":"main","state":{"value":"on"},"capability_id":"switch"}
2022-02-01T17:55:06.698789891+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Found ZwaveDispatcher handler in ge-zwave-switch
2022-02-01T17:55:06.721098891+00:00 INFO GE Z-Wave Switch/Dimmer/Fan/Outlet Test <ZwaveDevice: 61606588-501f-4ff8-b071-8da57be02e7c [62] (Den Lights)> emitting event: {"attribute_id":"level","component_id":"main","state":{"value":37},"capability_id":"switchLevel"}
2022-02-01T17:55:06.772660558+00:00 DEBUG GE Z-Wave Switch/Dimmer/Fan/Outlet Test Den Lights device thread event handled
2022-02-01T17:55:52.118945246+00:00 TRACE GE Z-Wave Switch/Dimmer/Fan/Outlet Test Received event with handler capability