Elegant way to react to commands from multi-button switches

Posted on
Tue Sep 12, 2017 2:14 am
jmdraper offline
Posts: 103
Joined: Sep 11, 2014
Location: Surrey, UK

Elegant way to react to commands from multi-button switches

I have many z wave switches with multiple buttons (like the Nodon Octan for example, plus many others). I have all of these controlling various sets of actions in Indigo so have them in 'scene' mode rather than directly paired with other z-wave devices.

At the moment I do this by creating a trigger for each button on each switch triggered by the relevant z-wave command received from that device. So 4 triggers for each Nodon Octan for example. But then I find some people in my household who shall remain nameless tend to press and hold the button too long, so I end up creating another 4 triggers per device to react to 'button held' z wave commands received. So very quickly I have many tens of triggers in Indigo just to respond to these switches. They're a PITA to create and maintain.

I know there must be a more elegant way to do this, but I cannot find one. Any suggestions, please?

Thanks!

Jon

Posted on
Tue Sep 12, 2017 6:05 am
rehafer offline
Posts: 279
Joined: Feb 08, 2013

Re: Elegant way to react to commands from multi-button switc

Family-proofing your Home Automation is always a challenge ;). Are your scenes Action Groups called by the Triggers or written into the Triggers themselves? Using Action Groups would at least simplify maintenance.
The classic coding solution would be to build a lookup table of Z-wave commands vs. actions, but I'm not sure how to implement that in Indigo.


Sent from my iPad using Tapatalk

Posted on
Tue Sep 12, 2017 8:51 am
jmdraper offline
Posts: 103
Joined: Sep 11, 2014
Location: Surrey, UK

Re: Elegant way to react to commands from multi-button switc

Yes indeed!

The things being triggered tend to be either in action groups or occasionally I have wrapped them into virtual devices. I am thinking of creating a plugin for this which would enable the creation of new devices of a type called something like 'multi-button scene switch' in the config of which you could create multiple 'buttons' each with an associated z-wave command and either a virtual device command (on/off) or an action group. Then whenever one of those z-wave commands is received, the plugin would execute the matched virtual device command or action group.

It looks like such a thing would be (a) possible, (b) useful at least for me and (c) hasn't been done already. I wanted to check (c) here before I started. Then assuming there's no easier way, it's going to take me a while as I am barely a beginner in both Python and Indigo plugin creation. But it could be an interesting challenge!

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 2 guests