I am trying to write an automation that turns off any light on longer than 1 minute. The automation below trigger after one minute, but the study lights do not toggle. Any suggestions please.
id: '1661835107535'
alias: Turn off lights and fans
description: ''
trigger:
- platform: state
entity_id:
- light.study_lights
to: 'on'
for:
hours: 0
minutes: 1
seconds: 0
condition: []
action:
- service: light.toggle
data: {}
target:
entity_id: trigger.entity_id
mode: single
I’m also struggling to get my lights on longer than 1 min but no clue what code to put into the yaml file.
I have never used this code before and until I learn or get used to what to put in there I have no clue and dont want to make mistakes in there to stop things from working.
I can see where my Automation is in the file just no clue what to add to it for the light to stop on 3 mins
I’m also having issues with lights blinking when using the Aqara Presence Sensor FP2 and totally given up with that sensor. I tried to set it up after nightnight to turn on if I was to have to get up during the night due to hypo to get food from Kitchen and have the lights come on but all I got was more confusions with blinking lights with blinking hypo