To reset or restart an active timer while it is running … it is necessary to cancel and start the timer. This will result in an unwanted CANCEL event before the timer gets active again.
Can we have a reset/restart functionality for TIMER to reset the clock to the start time keeping the status as active?
This is already possible by triggering the start service again.
Starts or restarts a timer with the provided duration. If no duration is given, it will either restart with its initial value, or continue a paused timer with the remaining duration.
xx_Nexus_xx is right, the timer actually does restart, but the time remaining in the frontend is still the time of the first period (not restarted).
Even though the timer have been successfully restarted, the frontend display the wrong value.
Same experience here. When restarting a running timer, I would expect the timer to display a new countdown in the frontend, but it doesn’t. But in the background it is indeed restarted, only not displayed in the frontend.
Like puk1966, I also had to cancel and start the timer to update the duration on an active timer (push time zero into the future) in version 0.92. I consider this a work around since this segments timer’s active state in history graphs rather showing a continuous active state.
I had the same experience, I cannot restart a timer.
System Health
item
value
arch
x86_64
dev
false
docker
true
hassio
true
os_name
Linux
python_version
3.7.3
timezone
America/New_York
version
0.94.3
virtualenv
false
Cancel and re-start is not an option, that will complicate automations.
My use case is a count down timer to turn off a light, every time there’s motion reset the timer. This way I don’t have lingering and overlapping automations.
I would have (2) Automations and one timer per light:
(1) Turn on the light and start (or restart) the timer on motion
(2) automation to turn off the light when the timer hits zero
The timer would vary based on the use of the room, living room set higher (10m) because you sit idle, working area of a kitchen lower (2min), because you’re constantly moving.