Hi all,
I am using the ABB-free@home integration. I have free@home wall switch sensors (no actors) with double rockers shown as following:
Left rocket as “event.sensor_bad_waschtisch_oben_schalt_ereignis_ch0000”
Attributes:
event_types:
- unknown
- "off"
- "on"
event_type: "on"
device_class: button
friendly_name: Sensor Bad Waschtisch oben Schalt Ereignis (ch0000)
I want to use the physical switch when pressing top left button to switch on my Eve Energy for 1 minute and then turn Eve Energy off. By pressing buttom left Eve Energy should turn off without waiting for the 1 minute timer.
- id: "automation_bad_waschtisch_schalter_oben_links"
alias: "Zirkulation per Schalter Bad Waschtisch oben links"
description: "Schaltet die Eve Steckdose Zirkulation für 1 Minute ein oder sofort aus."
trigger:
- platform: state
entity_id: event.sensor_bad_waschtisch_oben_schalt_ereignis_ch0000
attribute: event_type
to: "on"
id: "switch_on"
- platform: state
entity_id: event.sensor_bad_waschtisch_oben_schalt_ereignis_ch0000
attribute: event_type
to: "off"
id: "switch_off"
action:
- choose:
- conditions:
- condition: trigger
id: "switch_on"
sequence:
- service: switch.turn_on
target:
entity_id: switch.eve_energy_zirkulation
- delay: "00:01:00" # 1 Minute warten
- service: switch.turn_off
target:
entity_id: switch.eve_energy_zirkulation
- conditions:
- condition: trigger
id: "switch_off"
sequence:
- service: switch.turn_off
target:
entity_id: switch.eve_energy_zirkulation
mode: restart
I have the following problem: when I press top left buttom the automation works fine but event_type stays at “on”. So if I want to use the automation again by pressing top left buttom it does not work because the event_type is not changing from off to on. I have to physically push the bottom left button and then the automation is working again.
Is there any possibility in Home Assistant to set the event_type to “off” after 1 minute?
Thanks