aneisch
(Andrew)
November 7, 2018, 3:26am
1
I want a script (or automation) that when triggered will adjust my AC to + or - X degrees. I tried this with a template script but it didn’t work, here is what I tried:
too_cold:
sequence:
- service: climate.set_temperature
data_template:
entity_id: climate.thermostat
temperature: {{ states("sensor.thermostat_setpoint") | int + 2 }}
Any thoughts?
aneisch
(Andrew)
November 7, 2018, 3:43am
2
aneisch:
I want a script (or automation) that when triggered will adjust my AC to + or - X degrees. I tried this with a template script but it didn’t work, here is what I tried:
too_cold:
sequence:
- service: climate.set_temperature
data_template:
entity_id: climate.thermostat
temperature: {{ states("sensor.thermostat_setpoint") | int + 2 }}
Any thoughts?
SOLVED!
too_cold:
sequence:
- service: climate.set_temperature
data_template:
entity_id: climate.thermostat
temperature: '{{ float(states("sensor.thermostat_setpoint")) + 2 }}'