hi ,
sorry to be a pain but im sure this is an easy problem for most of yous, yet i still cant suss it.
so i have a timer sensor engine_run_time that accumaltes the hours that my engine is running,
this is for me to roughly calculate fuel costs, so every time i fill up i need a simple way of resetting the timer to 0 hours 0 mins.
i tried just restting them in developer states, but that doesnt seem to work, can anyone advise please
i think i would like a script or automation that can be called via a button on the web interface
thankyou in advance.
sensor engine_run_time:
- platform: history_stats
name: engine_run_time
entity_id: sensor.ignition
state: ‘1’
type: time
start: ‘{{ 0 }}’
#start: ‘{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}’
end: ‘{{ now() }}’