Hi there, I have a Netatmo Thermostat and I see that all entities are not directly accessible. I can only add Thermostat device to a History card to see “desired temp”, “current temp” and “heating temp” (when heating on).
Is there any way to extract the time my heating was on every day?
What do your states and attributes look like for this device?
You should be able to run your history stats off of something similar to the hvac_mode or hvac_action:
I use History Stats helpers to do just that as mentioned here:
I do it this way :
- platform: history_stats
name: Heating Today
entity_id: sensor.hvac_activity
state: 'heating'
type: time
start: '{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}'
end: '{{ now() }}'
Replace the entity with whatever is “on” while the heating is on.
Then I make it easy to read with a template sensor
{% set hours = states('sensor.heating_today') | float %}
{% set minutes = ((hours % 1) * 60) | int %}
{% set hours = (hours - (hours % 1)) | int %}
{{ '%02i:%02i'%(hours, minutes) }}