No, I think he just needs to define a switch.
And then when he uses the switch he can build the required delay
If it always has the same âactionâ then write it into a script and call the script instead of the switch
What is the use case for this ?
There may be a better way to achieve the same result
The use case is the following:
I have two Tasmota switches.
One is the âTV Masterâ, it switches on/off the power for everything related to the TV (Receiver, Subwoofer, BluRay Player). For the TV there is an extra Tasmota switch called âTVâ , because the TV is configured to switch on immediately when it has Power.
Now, if TV Master is off and I want to turn on the TV, I would have to turn on TV Master first, then wait a few seconds till the TV Tasmota Switch connected to my WiFi, and then also switch it on.
Fair enough, I actually have a similar use case.
But itâs just a delayed power on for kodi when HA sees that my TV is on
And a similar action on switch off except that the switch to turn the actual power of its fake, it interrupts the switch off and shuts down kodi first, waits 20 secs then cuts the power.
I canât imagine you doing these independently so just have a switch on automation with your delay in it and a switch off automation reversing the action.
Both automations could be driven by your template switch
Theyâd be really simple and easy to maintain so I wouldnât bother trying to get them into one.
Remember the KISS principle.
Good luck