How to cancel queued commandArray{} events
Posted: Monday 22 January 2024 9:23
I'm porting over some old LUA scripts from seven years ago, and am wondering if something has changed in the method for cancelling a queued commandArray{} event. Suppose we issue:
and then, a little later, we wish to remove that queued request that hasn't yet fired. Or, perhaps we don't even know for sure if there are any pending requests, but we just want to make sure the device remains in it's present state without generating any radio traffic. It used to be we could issue:
and it would clear all queued requests on MyDevice. This worked in 2017 for OpenZwave devices, but with Domoticz 2024.2 and ZWave-JS-UI 9.7.1 the Domoticz log shows:
where ZWaveMqtt is my Domoticz MQTT autodiscovery gateway.
So, it looks like the empty "" commandArray{} string has lost its former special meaning of clearing the device queue, and is now just seen as a bogus unsupported command. Oddly, it DOES still have the effect of cancelling queued events even though it is reported as an error. Also, I verified that no ZWave MQTT traffic is generated directly in response to issuing the empty string.
Is there some new commandArray{} syntax to cleanly request that a device's queue be internally cleared?
Thanks
Code: Select all
commandArray[ 'MyDevice' ] = "On AFTER 30"
Code: Select all
commandArray[ 'MyDevice' ] = "" -- Empty string cancellation request
Code: Select all
Error: ZWaveMqtt: Switch command not supported ( - zwavejs2mqtt_0xef7cfb02_3-37-1-currentValue/MyDevice)
So, it looks like the empty "" commandArray{} string has lost its former special meaning of clearing the device queue, and is now just seen as a bogus unsupported command. Oddly, it DOES still have the effect of cancelling queued events even though it is reported as an error. Also, I verified that no ZWave MQTT traffic is generated directly in response to issuing the empty string.
Is there some new commandArray{} syntax to cleanly request that a device's queue be internally cleared?
Thanks