I’m wondering why my history stats entity is showing a different value from what it actually is.
It counts correctly:
The entity value shows 0,73h.
- platform: history_stats
name: Papa - Zeit zu Hause
entity_id: person.papa
state: "home"
type: time
start: "{{ now().replace(hour=0, minute=0, second=0, microsecond=0) }}"
end: "{{ now() }}"
What do I need to do to get the correct value?
In the developer tools I see the following state attributes:
state_class: measurement
unit_of_measurement: h
device_class: duration
icon: mdi:chart-line
friendly_name: Papa - Zeit zu Hause