Posted September 27, 200718 yr If I turn on a switch then I change my mind in a split second and turn it back off before a program starts the program turns them back on. I found it on my bathroom timer program.
September 28, 200718 yr Author Here is the code and I know your going to say use a Finally but this causes the light to blink on then back off after the split second on-off usage. If Control 'Guest Bath Main' is On Then Set 'Guest Bath Main' On Wait 1 hour Set 'Guest Bath Main' Off
September 28, 200718 yr Yes, I would say use 'Finally', because you are guaranteed to have the light turn off if the program turns the light on. BUT It would be better to directly link the light to the switch in a scene. The switch would directly turn the light on, and the program would only have to turn it off after an hour. You could either test the control or the status depending on what you want to do. If Control 'Guest Bath Main' is On Then Wait 1 hour Set 'Guest Bath Main' Off
September 28, 200718 yr Author Yes there was already links to that scene on the switch. I can see them work right away. [*:1cmkiu81]I tap the light on, the scene comes on[*:1cmkiu81]I split second later tap it off, the scene goes off[*:1cmkiu81]Then about a half second later the program turns it back on.[*:1cmkiu81]And now that I added a finally it flashes back off. So what I get is an echo of the switch. I guess I could run without the switch links and just the ISY program but then the scene would not function if the ISY was out of the loop. I think it might be that the ISY is trying to execute the program ASAP so there is no time to get feedback back before the split second off tap. How big of a hit is it to wait for the second tap response?
September 28, 200718 yr Author Well I found a workaround but I am wondering if you can check in the background for the parallel scene vs program; if there is already the same controller switch in the program, and the same scene as the program, then you could add a small delay to that program. If Control 'Guest Bath Main' is On Then Wait 1 second Set 'Guest Bath Main' On Wait 1 hour Set 'Guest Bath Main' Off
September 28, 200718 yr Did you try the program I posted where the switch turns the light on, not the program, and the only thing the program does is turn it off: If Control 'Guest Bath Main' is On Then Wait 1 hour Set 'Guest Bath Main' Off I think this should solve the flicker problem with Finally. You could instead check the Status if the 'Guest Bath Main' can be turned on by different controls.
September 28, 200718 yr Maybe I'm missing something, but if the event is detecting that you are turning the switch on with this line: If Control 'Guest Bath Main' is On Why are you having the ISY-26 turn it on again with this line: Then Set 'Guest Bath Main' On Wouldn't the switch already be on??
September 28, 200718 yr Author Good idea, good question. I will try the program without the turning on part. I just need the timer to turn it off after the time is run out. Thanks Guys.
September 28, 200718 yr Author That works great. These little programs really just need a lightest touch approach.
September 28, 200718 yr Hey Mark - Just a note. I had my triggers setup the same way, but recently switched to STATUS instead of CONTROL because if the switch is turned off by something other than the switch itself (like another trigger, or another switch in the house), this timer will continue to run. Something to think about.
September 28, 200718 yr Author I noticed that last night when I was experimenting. I will try status instead. Thanks!
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.