log.debug "schedule check"
def motionState = motion1.currentState("motion")
if (motionState.value == "inactive") {
- def elapsed = now() - motionState.rawDateCreated.time
- def threshold = 1000 * 60 * minutes1 - 1000
- if (elapsed >= threshold) {
+ //def elapsed = now() - motionState.rawDateCreated.time
+ //def threshold = 1000 * 60 * minutes1 - 1000
+ if (/*elapsed >= threshold*/true) {
log.debug "Motion has stayed inactive long enough since last check ($elapsed ms): turning lights off"
switches.off()
} else {