Light Timer Efficiency


#1

1) Give a description of the problem
Is there a more efficient way to do what I’m trying to do here? The part I don’t like is that the piston has to be evaluated every 30 seconds even when no lights are on at all. I want to keep all of this configurable as it is now though.

2) What is the expected behavior?
The goal here is to turn a group of lights on based on motion, for minimum of 120 seconds. Once the motion sensor goes inactive, a 60 second countdown is started. Then every 30 seconds the lights dim by 10%, until they finally turn off. Any motion will reset the process.

3) What is happening/not happening?
It works, but I don’t want to put too much load on the webcore server(s).

4) Post a Green Snapshot of the pistonimage


#2

I think there’s a fade function for lights, you can just try using it, then set the fade out time you prefer.


#3

Hmm, that’s cool, but it seems there is no way to cancel the fade once it has started:


#4

That’s inconvenient… I tired fade once but was scared by that function because it keeps sending commands to the light. So I use manual fade (hard coded brightness level) since I fear the load to the light as well as to the piston.