Argo
(Argo)
August 8, 2020, 2:23pm
1
Hey everybody!
Trying to get seconds from timer in automation (9 seconds on the screenshot):
I thought {{state_attr('timer.killer', 'remaining')}}
would help, but it did not. ‘Remainig’ updates only if timer is paused. And I am trying to get ‘live’ time. How can I achieve that?
1 Like
KTibow
(Kendell R)
August 8, 2020, 2:53pm
2
How about {{ states('timer.killer') }}
Interesting naming…
Argo
(Argo)
August 8, 2020, 3:03pm
3
Nope, thats not gonna work
Making smth like countdown with tts for security system (siren + countdown)
I want to send tts every 10 seconds so it would be like:
“You will be destroyed in ** seconds”
KTibow
(Kendell R)
August 8, 2020, 3:05pm
4
This could be more easily done with the repeat
action and delay, check 0.113 release notes.
Argo
(Argo)
August 8, 2020, 3:14pm
5
I am using repeat
, but I don’t really want to hardcode time in automation. It seems like timer would be perfect here. I thought that there is a simple way to get live time
KTibow
(Kendell R)
August 8, 2020, 3:15pm
6
??? The time is still hardcoded with a timer, right?
Argo
(Argo)
August 8, 2020, 3:43pm
8
I mean that with timer I will get real time with correct intervals. So there will not be any situation when time is counted incorrectly
Can I be precise if I use delays?
And by the way, how do you mean to do it with repeat?
If I use repeat - I should have a variable for seconds left
tom_l
August 8, 2020, 3:46pm
9
I just linked to an exact answer to your question. That you probably should have found by searching yourself. Took me all of 15 seconds.
Argo
(Argo)
August 8, 2020, 4:10pm
10
thank you for your time, sorry for spamming