blueprint: name: Better Thermostat Multi-Mode Controller description: Steuert Better Thermostat mit Sommer/Winter (Wetterbasiert), Schedule und Urlaubs-Button domain: automation input: better_thermostat_entity: name: Better Thermostat Entity description: z.B. climate.wohnzimmer_bt selector: entity: domain: climate schedule_entity: name: Heizzeitplan Schedule description: z.B. schedule.heizzeitplan_wohnzimmer selector: entity: domain: schedule vacation_helper: name: Urlaubsmodus Helper description: input_boolean für Urlaub selector: entity: domain: input_boolean weather_entity: name: Wettervorhersage description: z.B. weather.openweathermap selector: entity: domain: weather summer_temp_threshold: name: Sommer-Schwellwert (°C) description: Wenn Vorhersage über dieser Temp, Heizung aus default: 25 selector: number: min: 20 max: 35 step: 1 winter_temp_threshold: name: Winter-Schwellwert (°C) description: Wenn Vorhersage unter dieser Temp, Winter-Modus default: 10 selector: number: min: 0 max: 20 step: 1 eco_temp: name: Eco Temperatur (°C) description: Temperatur bei Abwesenheit/Urlaub default: 15 selector: number: min: 10 max: 18 step: 0.5 comfort_temp: name: Komfort Temperatur (°C) description: Temperatur wenn Schedule aktiv default: 21 selector: number: min: 18 max: 24 step: 0.5 trigger: - platform: state entity_id: !input schedule_entity - platform: state entity_id: !input vacation_helper - platform: state entity_id: !input weather_entity - platform: time_pattern minutes: "/30" condition: [] action: - variables: weather_entity: !input weather_entity schedule_entity: !input schedule_entity vacation_entity: !input vacation_helper summer_threshold: !input summer_temp_threshold winter_threshold: !input winter_temp_threshold eco_temperature: !input eco_temp comfort_temperature: !input comfort_temp - variables: forecast: "{{ state_attr(weather_entity, 'forecast') }}" weather_temp: "{{ forecast[0].temperature if forecast and forecast|length > 0 else 15 }}" is_summer: "{{ (weather_temp | float(15)) > (summer_threshold | float(25)) }}" is_winter: "{{ (weather_temp | float(15)) < (winter_threshold | float(10)) }}" is_vacation: "{{ states(vacation_entity) == 'on' }}" schedule_active: "{{ states(schedule_entity) == 'on' }}" - choose: # Priorität 1: Sommer-Modus (Heizung aus) - conditions: - condition: template value_template: "{{ is_summer }}" sequence: - service: climate.set_hvac_mode target: entity_id: !input better_thermostat_entity data: hvac_mode: "off" # Priorität 2: Urlaubsmodus (Eco) - conditions: - condition: template value_template: "{{ is_vacation }}" sequence: - service: climate.set_hvac_mode target: entity_id: !input better_thermostat_entity data: hvac_mode: "heat" - service: climate.set_temperature target: entity_id: !input better_thermostat_entity data: temperature: "{{ eco_temperature }}" # Priorität 3: Winter + Schedule aktiv (Komfort) - conditions: - condition: template value_template: "{{ is_winter and schedule_active }}" sequence: - service: climate.set_hvac_mode target: entity_id: !input better_thermostat_entity data: hvac_mode: "heat" - service: climate.set_temperature target: entity_id: !input better_thermostat_entity data: temperature: "{{ comfort_temperature }}" # Priorität 4: Winter ohne Schedule (reduzierte Temp) - conditions: - condition: template value_template: "{{ is_winter and not schedule_active }}" sequence: - service: climate.set_hvac_mode target: entity_id: !input better_thermostat_entity data: hvac_mode: "heat" - service: climate.set_temperature target: entity_id: !input better_thermostat_entity data: temperature: "{{ eco_temperature + 2 }}" default: [] mode: queued max: 10