I prefer to keep automations very simple and have each one do only one thing. Then different automations all come into play, which makes maintenance mnuch simpler and the whole thing is much more flexible.
For example -
One automation just turns the light on with the conditions you specified, trigered by the action you specified.
One automation starts a timer when the light is switched on, but the timer is started with a duration specified by an input_number which you can show as a slider to change in your dashboard.
One automation simply turns the light off when the timer finishes.
Then you can add alot more functionality and logic to it in a much simpler manner going forward.
Thoughts?
Also you can have an automation that justg turns the light on when the timer is started, and then your original automation could just start the timer if you like. Or also add an automation that just stops the timer when the garage door closes (which would turn off the light), etc., etc.
It makes it much more flexible and easier to maintain keeping all of the automations simple - and opens alot more possibilities!
When I create the Helper timer do I just create a “Timer” for 5:00 minutes? Then create an automation that see the light come on and then the “Timer” starts with a trigger to Turn_off light when timer completes?
Sorry I will let Bob answer, but I believe so… When you start the timer it would then run for 5 minutes. But, when you start the timer you can specify how long it runs, so you could pass to it the value from an input_number which you can then just display on a dashboard as a slider. (I then have another automation that restarts the timer with the new duration when the slider is changed - but only if the timer is already active.)