Cant figure out y this will not work


#1

Smartthings switch is on garage door. Trying to get switch to turn on at sunset if sensor is open and then if I open garage door after sunset want switch on 15 min after contact switch is opened


#2

Do you use the global variable @contact_open_true in other pistons?


#3

I am going to guess that lines 27 & 40 should read:

IF variable "@contact_open_true" is "true"


#4

I didn’t realize it but the variable was global so changed to local
Does not matter if the contact changes to open or closed
Under Quick Facts “piston state” stays false
Within the piston under
defind
boolean contact_sensor; /* true */ this does not change either
Whats the difference


#5

ok works for the most part but when contact sensor opens between sunrise and 11:59 variable does not change to true


#6


#7

I think I got it changed the set variable from else to then


#8

Still having problems with this piston
Even though the variable is false switch 8 still turns on at sunset


Line 31 do i have to make that a trigger rather than a condition


#10

If you have not figured this out, you should post current piston and full logs for when it runs