You need to create an automation to turn it off again. You should be able to copy this one and just switch your trigger to use ābelowā instead of āaboveā.
So where would you expect it to turn off?
As far as I read your automation it follows this story:
if the humidity >83 for 2 minutes and the afzuiging is off, turn on.
With my limited automation knowledge, you could clone this automation asking for being <83 for 2 min and then turning it off.
If you want to keep one Automation, you can experiment with having a sequence of actions:
turn_on
wait for 2 min
turn_off
you can then play with the new option āmodeā for further comfort by automatically prolonging the fan on time by stacking the automations. There is goodexplanation on this in the 113:
I donāt want to hijack this topic of course, but it is precisely the automation iām trying to achive. However, iām new to automations and struggle to get this working. I have basically copied this automation from the TS through the visual editor. It looks like this in the code editor:
alias: Badkamer ventilatie On
description: Schakelt ventilator aan als RH 2 minuten boven 70% is
trigger:
- platform: numeric_state
entity_id: sensor.alecto_ws1700_dc_02_humidity
for:
hours: 0
minutes: 1
seconds: 0
above: 65
condition:
- condition: state
entity_id: switch.ac_000963b_10
state: "off"
for:
hours: 0
minutes: 0
seconds: 0
action:
- service: switch.turn_on
data: {}
target:
entity_id: switch.ac_000963b_10
mode: single
The fan is not starting, nor is it stopping (with the duplicated automation as mentioned here). When I operate this fan switch from my normal dashboard, it responds right away. Also, when I select to run the automation, the fan switches on right away. I canāt figure out why this is not working.
I see you have made some changes in the code. I assume this is what I should change it to for it to work? Just copy/paste it instead of what I have now (and disable those)?
I looks to me that you made a 2-in-1 action for it.
I just saved the code when humidty was below 65% and the I choose ārun automationā . However, nothing happened again. Looking through the log I found this: