Looking for help, please. What don’t I understand?
I created an input_datetime helper: input_datetime.peter .
I called this service on Developer Tools / Services …
service: input_datetime.set_datetime
data:
datetime: "{{ utcnow() }}"
target:
entity_id: input_datetime.peter
Using Developer Tools / Template …
{{ (as_timestamp(utcnow()) - as_timestamp(as_datetime(states('input_datetime.peter')))) / 3600 }}
the result is …
Result type: number
1.0171730258067448
It didn’t take an hour to write the template. Time zone in the UK is UTC+1 currently. Does input_datetime always return values as local time?