Day night Temp sliders

I was working on a slider for my day and night Temperatures so my thermostat can have different settings during the day or night but i don’t want to hardcode the values.

So far i made two input numbers and can change their value with a slider. However, the automation to set these values at given times during the day is where it goes wrong.

This is the automation so far.

- id: '1601703152278'
  alias: Set_Temp - Day mode
  description: ''
  trigger:
  - platform: time
    at: 06:00:00
  condition: []
  action:
  - service: climate.set_temperature
    data_template:
      entity_id: climate.living_thermostaat
      temperature: '{{ states.input_number.temp_dag | int }}'
  mode: single
- id: 8e21371283b74ba5a3409be4eb64d78e
  alias: Set _Temp -  Night mode
  description: ''
  trigger:
  - platform: time
    at: '21:30:00'
  condition: []
  action:
  - service: climate.set_temperature
    data_template:
      entity_id: climate.living_thermostaat
      temperature: '{{ states.input_number.temp_nacht | int }}'
  mode: single

The triger works fine but this sets my Thermostat to 0 Degrees and not 21 as the input number is curently configured to be.
I have also just try to call the service in the developer tools with the same result, no error but the output is zero degrees on the thermostat.

service: climate.set_temperature
target:
  entity_id: climate.living_thermostaat
data:
  temperature: '{{state.input_number.temp_Nacht | int }}'
temperature: '{{states.input_number.temp_nacht.state | int }}'

or better

temperature: '{{states("input_number.temp_nacht") | int }}'
1 Like

Not certain if HA is case sensitive but you have nacht and Nacht.

Thank you, This has dominated my weekend and i just couldn’t see it.

Same on both, ofc