Variables For Keypadlinc Button Link Trigger

Posted on
Tue Nov 22, 2011 2:44 pm
mrdubs offline
Posts: 21
Joined: Nov 22, 2011

Variables For Keypadlinc Button Link Trigger

I've made awesome progress on my home automation project and these boards are so helpful. Does anyone have suggestions on making sense of true/false arguments in the indigo 5 application?

Goal: If any upstairs light is on (or dimmed/on more than 1%) I'd like to create a variable called "upstairs_lights_on" that would be true and trigger button #4 on my Keypadlinc to on. I understand it's a multipart setup, but I can't get the True/False to work correctly -- if all upstairs lights are off, it still says the variable is true.

My Thinking:
Part #1 - Trigger: If Variable Change "upstairs_lights_on" changes; ANY conditions: master lights on; guest bedroom lights on; stairway lights on; action: set to true. (is this what I want to do here? This is been the most confusing part of indigo I've tried to wrap my head around)

Part #2 - Trigger: If above is true, action would be to turn on KPL dimmer button #4 to on.

Part #3 - Schedule: Run Part #1 and #2 every 10-30 minutes.

I know tracking status on KPL dimmers is not widely recommended, but I'd like to know if my goal is possible and figure out the best way to do it. Also, I'm open to feedback or suggestions as to why I shouldn't move forward with this idea.

Thanks!

Posted on
Tue Nov 22, 2011 5:11 pm
jay (support) offline
Site Admin
User avatar
Posts: 18185
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Variables For Keypadlinc Button Link Trigger

What you really need to do is track the lights - so when any of them go on, set the variable to true; when one goes off, you'll need a script to check to see if any others are on and if not then set the variable to false. That means 2 triggers per light - one for ON and one for OFF. The ON action is to set the variable to true so it's straight-forward. The OFF action should execute an Action Group that contains a script that cycles through all the lights looking to see if one is ON: if so, make sure the variable is true; if not, set the variable to false.

There are other ways to do this but off the top of my head this is what I'd do. I can't think of a good way to do it without scripts but there may be... ;)

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 1 guest