#timer that counts how much time the tv is on
1 messages · Page 1 of 1 (latest)
i think you can do that kind of thing with the history stats helper
That seems like the point of history_stats
oh
yeah I forgot about that
thanks
"Estado" = "State"
theres no available options
There are more on the next page. What are you looking for?
and you can just type the state you want
find the entity in
-> States and figure out what state you want. If it's a switch, it will be "on"
what should I put here? I want it to track 4 ever(while the tv is on, which was configured in the previous page)
I suggest following the last example in the docs: https://www.home-assistant.io/integrations/history_stats/#examples
- platform: history_stats
name: "Temps de chauffage chambre"
unique_id: "temps_chauffage_chambre_netatmo"
entity_id: sensor.etat_netatmo_chambre
state: "heating"
type: time
start: "{{ now().replace(hour=0, minute=0, second=0) }}"
end: "{{ now() }}"```
create a template
start: "{{ now().replace(hour=0, minute=0, second=0) }}"
This could also just be start: "{{ today_at() }}"
kinda doesnt work
It does. Toggle power on the TV
it is already
What I wrote above works for me
okay so it showed up that
and I manually checked on smartthings
and it have been on for 5 hours the entire week
and I installed home assistant for the first time a week ago
any way to reset that?
That's 5 days. My guess is that you chose the wrong entity
I don't think so
im trying to check how much time my tv switch stays in "on" state
and the name of the entity is switch.tv
I probably could start tracking from now by changing that
you can use whatever start or end time you want, and the docs show many examples