Do you get a channel triggered event in your log when pressing the button? Than you wouldn’t need to link it to an item at all as you can use those events in rules. If not a work around would be to link the switch channel to a switch item with the expire binding set to expire to off after 1 second. That way yo could use the changed to ON as a rule trigger etc.
2019-06-26 17:04:54.725 [vent.ItemStateChangedEvent] - zigbee_device_70dd630e_00158d0002041455_00158D0002041455_1_switch changed from OFF to ON
So I’d have to base my rule on this and set the state back to OFF after execution for this work-around. Not my preferred solution because of the more complex code but I’ll keep it in the back of my mind, thank you
So in fact I think what @JGKK wrote above is probably the correct approach. The events are being received, but the device only ever reports ON state, and in this case it seems you will need to use this to trigger a rule.
The possibility of changing the channel type for zigbee buttons to a trigger channel type (like the rocker switch channel type in the enocean binding) would be a nice addition to remove the expire binding workaround.
I don’t know if there is zigbee buttons that support functionality like long press or double press but this would be a great match for a trigger channel like this.
Best regards Johannes
So is the aquara wireless switch just reporting itself as a switch instead of a pushbutton although it is a button and the fault is on the manufacturers side for implementing the Zigbee standard wrong or should the binding actually be changed to correctly implement this button type? Or are we in a grey area?
Sorry for asking all this. Just trying to wrap my head around the Zigbee stuff in more detail.
The important bit here is the cluster=On_OFF part.
Probably there is scope to change the binding. It’s possible to manually define things in the binding, so this could be possible now, or if not if could be added.
As I said though, for this device it would fundamentally still be the same - you’d simply get a rule trigger each time the button is pressed.
Why use the expire binding at all? I guess you’re using it as you’re using this as a switch, but why not simply trigger a rule with the “On Update” trigger and it will be the same as if you had a trigger channel wouldn’t it?
Comment: using the expire binding,you can have a linked Switch Item set its state back to OFF after a delay of your choice.
Rules can then use conventional Item state triggers e.g. changed, Group based etc.
The discussion was about changing the binding to use trigger channels for this switch. I think don’t have a UI do they? I think using a trigger channel in this instance is the same as using the “received update” trigger in the rule?