I have the following automation. When I approach my home (based on the android companion app as a device trigger) to open my garage door. Although it is working ok sometimes it opens the garage door twice.
It opens the door, I enter, and after 1-2 minutes it reopens it. Probably due to the lack of the companion app to determine exactly my location.
I am thinking to add a boolean to and when the garage door is open to turn on for 20 minutes.
After 20 minutes to turn off (the input boolean) and add a condition to the automation to turn on the garage door only when input boolean is off.
Do you think it will work? Is there a better way to achieve this?
- id: Open Garage Door when close to home
alias: Open Garage Door when close to home
trigger:
platform: zone
entity_id: device_tracker.sm_g955f
zone: zone.myhome
event: enter # or "leave"
condition:
condition: state
entity_id: binary_sensor.openclose_18
state: 'off'
action:
- service: switch.toggle
data:
entity_id: switch.sonoff_100082f95b
3 posts - 1 participant