All,
I’m hoping this is a fairly easy one but I can’t seem to get my head round it.
I’ve got a helper value which changes based on the next alarm on my phone. What I want to do however is actually make the helper value be 15 mins before the alarm so it can turn my heating on etc.
This is the code I’ve currently got to run when ever the next alarm value changes from my phone.
service: input_datetime.set_datetime
entity_id: input_datetime.helper_value
data_template:
datetime: >-
{{
as_timestamp(states('sensor.phone_next_alarm'))|timestamp_custom('%Y-%m-%d
%H:%M:00') }}
What do I need to change to get it to to be 15 mins before?