So I own a smart plug that has energy metering, so I was thinking maybe its better if for the cycling of the pump, I use the energy of the washer to start the pump on the 15 minute repeats
So at this moment I have two motion sensors I’d like to fire up one cycle, IF the laundry is not already doing a cycle, I figured a global variable might be the best way to do it? It is possible to delay the laundry cycle if the pump was recently run by a motion event?
I’ve changed the piston you made to attempt to trigger based on power, but it now seems to not be happy with the global variable. If I run it without the global it variable, it fires, but it quits when the power goes below the threshold OR the power demand changes at all, which then never resets the Pump_On variable, so it breaks itself that way. Which I don’t get because I figure it would ignore that like the motion events do when its set to never cancel.
With the global variable this is the log:
11/6/2020, 7:41:46 PM +900ms
+1ms ╔Received event [Living Room Lamp].power = 5.651 with a delay of 31ms
+68ms ║RunTime Analysis CS > 15ms > PS > 39ms > PE > 13ms > CE
+70ms ║Runtime (39916 bytes) successfully initialized in 39ms (v0.3.110.20191009) (68ms)
+71ms ║╔Execution stage started
+79ms ║║Comparison (decimal) 5.651 is_greater_than (decimal) 0.0 = true (1ms)
+80ms ║║Condition #2 evaluated true (6ms)
+84ms ║║Comparison (boolean) true is_not (boolean) true = false (2ms)
+85ms ║║Condition #13 evaluated false (4ms)
+86ms ║║Condition group #1 evaluated false (state did not change) (12ms)
+88ms ║║Cancelling statement #20's schedules...
+93ms ║║No action taken...
+94ms ║║Executed virtual command log (1ms)
+95ms ║╚Execution stage complete. (25ms)
+96ms ╚Event processed successfully (96ms)
11/6/2020, 7:41:45 PM +807ms
+1ms ╔Received event [Living Room Lamp].power = 5.672 with a delay of 27ms
+65ms ║RunTime Analysis CS > 13ms > PS > 40ms > PE > 12ms > CE
+68ms ║Runtime (39916 bytes) successfully initialized in 40ms (v0.3.110.20191009) (66ms)
+69ms ║╔Execution stage started
+77ms ║║Comparison (decimal) 5.672 is_greater_than (decimal) 0.0 = true (1ms)
+79ms ║║Condition #2 evaluated true (6ms)
+83ms ║║Comparison (boolean) true is_not (boolean) true = false (1ms)
+84ms ║║Condition #13 evaluated false (4ms)
+85ms ║║Condition group #1 evaluated false (state did not change) (12ms)
+88ms ║║Cancelling statement #20's schedules...
+93ms ║║No action taken...
+94ms ║║Executed virtual command log (1ms)
+96ms ║╚Execution stage complete. (26ms)
+97ms ╚Event processed successfully (96ms)
11/6/2020, 7:41:42 PM +812ms
+0ms ╔Received event [Living Room Lamp].power = 5.609 with a delay of 26ms
+68ms ║RunTime Analysis CS > 14ms > PS > 42ms > PE > 13ms > CE
+71ms ║Runtime (39915 bytes) successfully initialized in 42ms (v0.3.110.20191009) (70ms)
+72ms ║╔Execution stage started
+81ms ║║Comparison (decimal) 5.609 is_greater_than (decimal) 0.0 = true (1ms)
+83ms ║║Cancelling condition #2's schedules...
+84ms ║║Condition #2 evaluated true (8ms)
+88ms ║║Comparison (boolean) true is_not (boolean) true = false (1ms)
+90ms ║║Condition #13 evaluated false (4ms)
+91ms ║║Condition group #1 evaluated false (state did not change) (14ms)
+93ms ║║Cancelling statement #20's schedules...
+98ms ║║No action taken...
+99ms ║║Executed virtual command log (1ms)
+102ms ║╚Execution stage complete. (30ms)
+103ms ╚Event processed successfully (104ms)
This is my broken piston: