1) Give a description of the problem
I have a somewhat elaborate scheme for controlling the lights in my office based on the time of day and the light switch. It has worked great, as the time changes I have a global variable change from “morning” to “midday” to “afternoon”, etc. and the lights change. Similarly when I turn the lights on it sets the appropriate level for the time of day. Both the variable change and the light switch are subscribed to.
Where it went sideways is I wanted to also add the function to a smartthings button I have, so I added another condition to each block to say “if the light switch is on or the button gets held and the time of day variable = X” but the effect was now the piston ONLY subscribes to the button and ignores the light switch and variable.
2) What is the expected behaviour?
I expected it to operate off the switch or global variable, or button.
3) What is happening/not happening?
The piston stopped subscribing to the switch and the variable when the button was added, when the button was removed the subscriptions to the other two returned.
4) Post a Green Snapshot of the piston
5) Attach logs after turning logging level to Full
2/6/2022, 6:13:35 PM +185ms
+1ms ╔Starting piston… (v0.3.114.20220203)
+1455ms ║╔Subscribing to devices…
+1581ms ║║Subscribing to Office Desk Button.button…
+1778ms ║║Subscribing to Laptop…
+1780ms ║║Subscribing to PC…
+1781ms ║║Subscribing to Desk Light…
+1782ms ║║Subscribing to Office Cabinet…
+1783ms ║║Subscribing to Office Lamp…
+1785ms ║║Subscribing to Office TV Left…
+1786ms ║║Subscribing to Office TV Right…
+1788ms ║╚Finished subscribing (351ms)
+1828ms ║Comparison (enum) on is (string) off = false (3ms)
+1866ms ║Comparison (enum) on is (string) on = true (1ms)
+1880ms ║Comparison (dynamic) night is (string) night = true (1ms)
+1914ms ║Comparison (enum) on is (string) on = true (2ms)
+1921ms ║Comparison (dynamic) night is (string) morning = false (2ms)
+1928ms ║Comparison (dynamic) night is (string) evening = false (2ms)
+1963ms ║Comparison (enum) on is (string) on = true (2ms)
+1969ms ║Comparison (dynamic) night is (string) midday = false (2ms)
+1992ms ║Comparison (dynamic) night is (string) afternoon = false (2ms)
+2007ms ║Comparison (enum) on is (string) on = true (2ms)
+2028ms ╚Piston successfully started (2027ms)