Hi,
I’m trying to create an automation and I would like the action to execute UNTIL one OR more conditions are met. I simplified it, but I want my garage ventilation fan to turn on to cool down my garage until either :
- the difference between the outside and inside temperature is less than 5 degrees; or
- the temperature in the garage has fallen to less than 24 degrees
If I follow the syntax documented at: https://www.home-assistant.io/docs/scripts/conditions/ , I should get something like this
- id: '123'
alias: Garage Heat Fan
mode: single
trigger:
- platform: template
value_template: "{{ (states.sensor.garage_temperature.state - states.sensor.weather_temperature.state) > 5 }}"
condition:
- condition: template
value_template: "{{ (states.sensor.garage_temp.state)|float > 24 }}"
action:
- service: fan.turn_on
entity_id: fan.garage_fan_control_switch_level
- repeat:
sequence:
- delay:
minutes: 1
until:
condition:
condition: or
conditions:
- condition: template
value_template: "{{ (states.sensor.garage_temp.state - states.sensor.weather_temperature.state) < 5 }}"
- condition: template
value_template: "{{ (states.sensor.garage_temp.state)|float < 24 }}"
- service: fan.turn_off
entity_id: fan.garage_fan_control_switch_level
But that does not pass validation. How do I format the conditions within the UNTIL statement? Note that if I only put one condition within the UNTIL statement, the automation works correctly.