Window Sensor with Radiator Valve

Hi

Sorry for my bad english. I am very new with samrt home systems.

I use HamaThermostats and a sonoff windo sensor.

This ist my config to put the Thermostat off. But I think that doenst work.

id: ‘1642603672499’
alias: Fenster Arbeitszimmer
description: ‘’
trigger:

  • platform: event
    event_type: ‘’
    condition:
  • type: is_open
    condition: device
    device_id: 1e93b8666453aafd5079ed02f455b7f9
    entity_id: binary_sensor.fenstersensor_arbeitszimmer_contact
    domain: binary_sensor
    action:
  • device_id: 4d42f5e20e75871acc45fee17a2dcad7
    domain: climate
    entity_id: climate.heizung_arbeitszimmer
    type: set_hvac_mode
    hvac_mode: ‘off’
    mode: single

Nutz’ halt deepl.com.

Please use the code formatting button (grafik) when including Yaml or any other code-like sources …

id: ‘1642603672499’
alias: Fenster Arbeitszimmer
description: ''
trigger:
  - platform: event
    event_type: ''
condition:
  - type: is_open
    condition: device
    device_id: 1e93b8666453aafd5079ed02f455b7f9
    entity_id: binary_sensor.fenstersensor_arbeitszimmer_contact
    domain: binary_sensor
action:
  - device_id: 4d42f5e20e75871acc45fee17a2dcad7
    domain: climate
    entity_id: climate.heizung_arbeitszimmer
    type: set_hvac_mode
    hvac_mode: ‘off’
mode: single

Despite the missing formatting, it looks weird. According to the Event Trigger documentation, I assume this automation triggers on any type of event (due to event_type being empty).

It’s not a matter of believe, either is does work or not. I guess you want the heating to go off, if the window is opened. Try this.

alias: Heizung aus bei Fenster auf.
description: ''
mode: single
trigger:
  - platform: state
    entity_id: binary_sensor.fenstersensor_arbeitszimmer_contact
    to: open
condition: []
action:
  - service: climate.set_hvac_mode
    target:
      entity_id: climate.heizung_arbeitszimmer
    data:
      hvac_mode: 'off'

PS: You should use the excellent visual automation editor from the UI.

1 Like