From bf5409d36e90883077941dd689e75560eee9931d Mon Sep 17 00:00:00 2001 From: Pierre Eisenbrandt Date: Wed, 4 Feb 2026 20:17:43 +0100 Subject: [PATCH 1/2] use random delay before set temp --- Climate/bosch_bth-ra_control.yaml | 42 ++++++++++++++++++++----------- 1 file changed, 27 insertions(+), 15 deletions(-) diff --git a/Climate/bosch_bth-ra_control.yaml b/Climate/bosch_bth-ra_control.yaml index 7f28044..df8f390 100644 --- a/Climate/bosch_bth-ra_control.yaml +++ b/Climate/bosch_bth-ra_control.yaml @@ -221,6 +221,10 @@ variables: # Konstanten temperature_change_tolerance: 0.4 # °C - Minimale Differenz für Temperaturänderung sensor_sync_max_age: 1499 # Sekunden (25 Minuten - 1 Sekunde) - Max Alter für Sensor-Sync + random_delay_max_seconds: 30 + + # Zufalls-Delay für climate.set_temperature + random_delay_seconds: "{{ range(0, random_delay_max_seconds + 1) | random }}" # Entity-Discovery remote_temperature_entity: > @@ -406,11 +410,13 @@ actions: value_template: > {{ is_valid_temperature and is_temperature_change_needed and is_state(window_detection_entity, 'off') }} then: - - service: climate.set_temperature - target: - entity_id: !input trv - data: - temperature: "{{ safe_temperature | float }}" + - delay: + seconds: "{{ random_delay_seconds }}" + - service: climate.set_temperature + target: + entity_id: !input trv + data: + temperature: "{{ safe_temperature | float }}" alias: Heizperiode aktiviert - Setze Modus auf heat, synchronisiere Fensterstatus und Solltemperatur - conditions: - condition: trigger @@ -465,11 +471,13 @@ actions: value_template: > {{ is_valid_temperature and is_temperature_change_needed }} then: - - service: climate.set_temperature - target: - entity_id: !input trv - data: - temperature: "{{ safe_temperature | float }}" + - delay: + seconds: "{{ random_delay_seconds }}" + - service: climate.set_temperature + target: + entity_id: !input trv + data: + temperature: "{{ safe_temperature | float }}" alias: Setze Fenster auf geschlossen und setze Solltemperatur auf Wert aus Zeitplan (wenn vorhanden) alias: Fensterstatus Änderung # temperature sensor sync @@ -526,6 +534,8 @@ actions: - condition: template value_template: "{{ override_duration_exceeded }}" sequence: + - delay: + seconds: "{{ random_delay_seconds }}" - service: climate.set_temperature target: entity_id: !input trv @@ -556,11 +566,13 @@ actions: value_template: > {{ is_valid_temperature and is_temperature_change_needed and is_state(window_detection_entity, 'off') }} then: - - service: climate.set_temperature - target: - entity_id: !input trv - data: - temperature: "{{ safe_temperature | float }}" + - delay: + seconds: "{{ random_delay_seconds }}" + - service: climate.set_temperature + target: + entity_id: !input trv + data: + temperature: "{{ safe_temperature | float }}" # Notification bei Scheduler-Mismatch - if: - condition: template -- 2.49.1 From edc4cabde5f12ffc05751ba2ba11fa8c01aa44a2 Mon Sep 17 00:00:00 2001 From: Pierre Eisenbrandt Date: Wed, 4 Feb 2026 20:21:11 +0100 Subject: [PATCH 2/2] fix yaml --- Climate/bosch_bth-ra_control.yaml | 46 +++++++++++++++---------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/Climate/bosch_bth-ra_control.yaml b/Climate/bosch_bth-ra_control.yaml index df8f390..4306ea3 100644 --- a/Climate/bosch_bth-ra_control.yaml +++ b/Climate/bosch_bth-ra_control.yaml @@ -222,7 +222,7 @@ variables: temperature_change_tolerance: 0.4 # °C - Minimale Differenz für Temperaturänderung sensor_sync_max_age: 1499 # Sekunden (25 Minuten - 1 Sekunde) - Max Alter für Sensor-Sync random_delay_max_seconds: 30 - + # Zufalls-Delay für climate.set_temperature random_delay_seconds: "{{ range(0, random_delay_max_seconds + 1) | random }}" @@ -410,13 +410,13 @@ actions: value_template: > {{ is_valid_temperature and is_temperature_change_needed and is_state(window_detection_entity, 'off') }} then: - - delay: - seconds: "{{ random_delay_seconds }}" - - service: climate.set_temperature - target: - entity_id: !input trv - data: - temperature: "{{ safe_temperature | float }}" + - delay: + seconds: "{{ random_delay_seconds }}" + - service: climate.set_temperature + target: + entity_id: !input trv + data: + temperature: "{{ safe_temperature | float }}" alias: Heizperiode aktiviert - Setze Modus auf heat, synchronisiere Fensterstatus und Solltemperatur - conditions: - condition: trigger @@ -471,13 +471,13 @@ actions: value_template: > {{ is_valid_temperature and is_temperature_change_needed }} then: - - delay: - seconds: "{{ random_delay_seconds }}" - - service: climate.set_temperature - target: - entity_id: !input trv - data: - temperature: "{{ safe_temperature | float }}" + - delay: + seconds: "{{ random_delay_seconds }}" + - service: climate.set_temperature + target: + entity_id: !input trv + data: + temperature: "{{ safe_temperature | float }}" alias: Setze Fenster auf geschlossen und setze Solltemperatur auf Wert aus Zeitplan (wenn vorhanden) alias: Fensterstatus Änderung # temperature sensor sync @@ -534,7 +534,7 @@ actions: - condition: template value_template: "{{ override_duration_exceeded }}" sequence: - - delay: + - delay: seconds: "{{ random_delay_seconds }}" - service: climate.set_temperature target: @@ -566,13 +566,13 @@ actions: value_template: > {{ is_valid_temperature and is_temperature_change_needed and is_state(window_detection_entity, 'off') }} then: - - delay: - seconds: "{{ random_delay_seconds }}" - - service: climate.set_temperature - target: - entity_id: !input trv - data: - temperature: "{{ safe_temperature | float }}" + - delay: + seconds: "{{ random_delay_seconds }}" + - service: climate.set_temperature + target: + entity_id: !input trv + data: + temperature: "{{ safe_temperature | float }}" # Notification bei Scheduler-Mismatch - if: - condition: template -- 2.49.1