I solved my loop problem with a delay of 1 second
this is my whole config if someone might be interested ![]()
# AC Bedroom Sensors for Thermostat
# AC Bedroom
- platform: template
sensors:
ac_bedroom_hvac_mode:
entity_id: climate.air_conditioner_bedroom
value_template: "{{ states.climate.air_conditioner_bedroom.state }}"
friendly_name: AC Bedroom HVAC Mode
ac_bedroom_temperature:
entity_id: climate.air_conditioner_bedroom
value_template: "{{ state_attr('climate.air_conditioner_bedroom', 'temperature') }}"
friendly_name: AC Bedroom Temperature
ac_bedroom_fan_mode:
entity_id: climate.air_conditioner_bedroom
value_template: "{{ state_attr('climate.air_conditioner_bedroom', 'fan_mode') }}"
friendly_name: AC Bedroom Temperature
# Thermostat
thermostat_bedroom_hvac_mode:
entity_id: climate.bedroom_ac_control
value_template: "{{ states.climate.bedroom_ac_control.state }}"
friendly_name: Thermostat Bedroom HVAC Mode
thermostat_bedroom_temperature:
entity_id: climate.bedroom_ac_control
value_template: "{{ state_attr('climate.bedroom_ac_control', 'temperature') }}"
friendly_name: Thermostat Bedroom Temperature
thermostat_bedroom_fan_mode:
entity_id: climate.bedroom_ac_control
value_template: "{{ state_attr('climate.bedroom_ac_control', 'fan_mode') }}"
friendly_name: Thermostat Bedroom Temperature
###################################### END ###########################################################
And the automations:
# # Bedroom Thermostat
## HVAC Mode
- alias: Thermostat - Set Slave HVAC Mode
trigger:
- platform: state
entity_id: sensor.thermostat_bedroom_hvac_mode
action:
- delay:
seconds: 1
- service: climate.set_hvac_mode
data_template:
entity_id: climate.air_conditioner_bedroom
hvac_mode: "{{ trigger.to_state.state }}"
- alias: Thermostat - Set Master HVAC Mode
trigger:
- platform: state
entity_id: sensor.ac_bedroom_hvac_mode
action:
- delay:
seconds: 1
- service: climate.set_hvac_mode
data_template:
entity_id: climate.bedroom_ac_control
hvac_mode: "{{ trigger.to_state.state }}"
## Temperature
- alias: Thermostat - Set Slave Temperatue
trigger:
- platform: state
entity_id: sensor.thermostat_bedroom_temperature
action:
- delay:
seconds: 1
- service: climate.set_temperature
data_template:
entity_id: climate.air_conditioner_bedroom
temperature: "{{ trigger.to_state.state }}"
- alias: Thermostat - Set Slave Temperatue
trigger:
- platform: state
entity_id: sensor.ac_bedroom_temperature
action:
- delay:
seconds: 1
- service: climate.set_temperature
data_template:
entity_id: climate.bedroom_ac_control
temperature: "{{ trigger.to_state.state }}"
## Fan Mode
- alias: Thermostat - Set Slave Fan Mode
trigger:
- platform: state
entity_id: sensor.thermostat_bedroom_fan_mode
action:
- delay:
seconds: 1
- service: climate.set_fan_mode
data_template:
entity_id: climate.air_conditioner_bedroom
fan_mode: "{{ trigger.to_state.state }}"
- alias: Thermostat - Set Slave Fan Mode
trigger:
- platform: state
entity_id: sensor.ac_bedroom_fan_mode
action:
- delay:
seconds: 1
- service: climate.set_fan_mode
data_template:
entity_id: climate.bedroom_ac_control
fan_mode: "{{ trigger.to_state.state }}"