Wait timer stopped working on bathroom light piston


#1

1) Give a description of the problem
Another instance of the wait timer on my piston suddenly stopped working. I’ve read a lot about setting the TCP to never, but I can’t seem to get it working again.

2) What is the expected behaviour?
I have an automation in my bathroom that if 1) motion is detected on a sensor or 2) the toilet is open, then the lights come on. Then if 1) motion sensors are inactive or 3) the toilet is closed, then wait 2 minutes and shut off the lights.

3) What is happening/not happening?
The timer is never starting, the lights just stay on forever.

**4) Post a Green Snapshot of the piston

5) Attach logs after turning logging level to Full

3/10/2021, 3:01:08 PM +358ms
+1ms ╔Received event [Bathroom Door Sensor].motion = inactive with a delay of 55ms
+54ms ║RunTime Analysis CS > 15ms > PS > 6ms > PE > 32ms > CE
+56ms ║Runtime (40120 bytes) successfully initialized in 6ms (v0.3.113.20210203) (54ms)
+57ms ║╔Execution stage started
+70ms ║║Comparison (time) 54068419 is_between (time) 20700000 .. (time) 75600000 = true (8ms)
+71ms ║║Time restriction check passed
+73ms ║║Condition #1 evaluated true (13ms)
+74ms ║║Condition group #null evaluated true (state did not change) (14ms)
+87ms ║║Comparison (enum) inactive is (string) active = false (1ms)
+89ms ║║Comparison (enum) active is (string) active = true (1ms)
+91ms ║║Condition #15 evaluated true (14ms)
+92ms ║║Condition group #14 evaluated true (state did not change) (15ms)
+93ms ║║Condition group #2 evaluated true (state did not change) (17ms)
+96ms ║║Cancelling statement #6's schedules...
+103ms ║║Skipped execution of physical command [Bath Bulb 1].on([]) because it would make no change to the device. (4ms)
+105ms ║║Executed [Bath Bulb 1].on (6ms)
+111ms ║║Skipped execution of physical command [Bath Bulb 2].on([]) because it would make no change to the device. (4ms)
+112ms ║║Executed [Bath Bulb 2].on (6ms)
+118ms ║║Skipped execution of physical command [Bath Bulb 3].on([]) because it would make no change to the device. (3ms)
+119ms ║║Executed [Bath Bulb 3].on (5ms)
+130ms ║║Skipped execution of physical command [Bath Bulb 1].setLevel([100]) because it would make no change to the device. (6ms)
+131ms ║║Executed [Bath Bulb 1].setLevel (8ms)
+139ms ║║Skipped execution of physical command [Bath Bulb 2].setLevel([100]) because it would make no change to the device. (7ms)
+140ms ║║Executed [Bath Bulb 2].setLevel (8ms)
+149ms ║║Skipped execution of physical command [Bath Bulb 3].setLevel([100]) because it would make no change to the device. (7ms)
+150ms ║║Executed [Bath Bulb 3].setLevel (9ms)
+153ms ║╚Execution stage complete. (96ms)
+154ms ╚Event processed successfully (154ms)
3/10/2021, 3:00:37 PM +712ms
+1ms ╔Received event [Bathroom Door Sensor].motion = active with a delay of 61ms
+64ms ║RunTime Analysis CS > 15ms > PS > 6ms > PE > 42ms > CE
+66ms ║Runtime (40120 bytes) successfully initialized in 6ms (v0.3.113.20210203) (64ms)
+67ms ║╔Execution stage started
+79ms ║║Comparison (time) 54037783 is_between (time) 20700000 .. (time) 75600000 = true (7ms)
+80ms ║║Time restriction check passed
+82ms ║║Condition #1 evaluated true (12ms)
+83ms ║║Condition group #null evaluated true (state did not change) (13ms)
+98ms ║║Comparison (enum) active is (string) active = true (1ms)
+99ms ║║Condition #15 evaluated true (13ms)
+100ms ║║Condition group #14 evaluated true (state did not change) (15ms)
+101ms ║║Condition group #2 evaluated true (state did not change) (16ms)
+104ms ║║Cancelling statement #6's schedules...
+151ms ║║Executed physical command [Bath Bulb 1].on() (44ms)
+152ms ║║Executed [Bath Bulb 1].on (45ms)
+163ms ║║Executed physical command [Bath Bulb 2].on() (8ms)
+164ms ║║Executed [Bath Bulb 2].on (10ms)
+174ms ║║Executed physical command [Bath Bulb 3].on() (8ms)
+175ms ║║Executed [Bath Bulb 3].on (10ms)
+187ms ║║Executed physical command [Bath Bulb 1].setLevel([100]) (9ms)
+188ms ║║Executed [Bath Bulb 1].setLevel (11ms)
+199ms ║║Executed physical command [Bath Bulb 2].setLevel([100]) (9ms)
+200ms ║║Executed [Bath Bulb 2].setLevel (10ms)
+210ms ║║Executed physical command [Bath Bulb 3].setLevel([100]) (9ms)
+211ms ║║Executed [Bath Bulb 3].setLevel (11ms)
+213ms ║╚Execution stage complete. (146ms)
+214ms ╚Event processed successfully (214ms)

#2

Your logs are showing the Bathroom Door Sensor going active and the lights turning on (the state of the other motion sensor isn’t tested). They then show that the Bathroom Door Sensor goes inactive but the other motion sensor is still active so the lights are turned on again (or in this case left on). What we don’t see is what happens when the other motion sensor also goes inactive as that is when the wait should start and the lights turn off.

You don’t need to change the TCP from the default. You actually want that ‘wait’ to be cancelled if there is motion to prevent the lights being turned off.


#3

Ahhhhh, it was the other motion sensor. Battery was dead in it, once I put in new batteries and switched TCP back to default and it works great! Thank you.