Hi guys,
I will like to have the garage light to auto turn on and after 5 minutes off, but if I press a button I will like they stay on until I press the button again (or off after 60 minutes)
whats happening now is that the lights goes off after 5 minutes and I have continue to do the dance to keep it on!
This is my current script
alias: Garage Lights Auto ON for X minutes (when Motion or garage door open)
description: ""
trigger:
- platform: state
entity_id:
- binary_sensor.garage_door_contact_sensor
to: "on"
- type: motion
platform: device
device_id: 5b98f1025e631970ffc9d4df32147fec
entity_id: binary_sensor.garage_motion
domain: binary_sensor
condition:
- condition: device
type: is_off
device_id: acb3b4b8d936e4f7eb7f24c52571d5c4
entity_id: switch.garage_lights
domain: switch
action:
- type: turn_on
device_id: acb3b4b8d936e4f7eb7f24c52571d5c4
entity_id: switch.garage_lights
domain: switch
- delay:
hours: 0
minutes: 2
seconds: 0
milliseconds: 0
- type: turn_off
device_id: acb3b4b8d936e4f7eb7f24c52571d5c4
entity_id: switch.garage_lights
domain: switch
mode: queued