Has the turn off function been updated to work on scenes? I dug through a majority of this thread and the only thing I could find was back in December of '20 indicating that the turn off function only worked for switches and lights. I’m required to use a scene for the turn on function as the light switch is dimmable.
If the turn off function doesn’t work for scenes, what’s the solution in turning off the light switch after the delay has been met?
You can define the wait timer by clicking the settings menu up in the upper right of the number helper dialogue box and select the number of minutes there.
Hello, thanks for this template, it looks great.
There is however something not clear to my by reading the template description. Is it necessary to define a timeout in order to turn off the lights after motion is detected? My use case is: when motion is detected, turn on lights, keep them on as long as motion is detected. When no motion then turn them off.
Is this template suitable for this use case?
Thanks
Another question: why use intermediare input entities rather than picking the raw values on the blueprint configuration? It is a bit annoying to have to create separate entities, display them on lovelace and then go there and setup them on a separate place. Is it a limitation of HA or something?
Is there any chance you could tell me how I could tweak the blueprint to allow for the turn off wait time to work for scenes? I don’t care for illuminance as my motion detectors have their own built in hardware sensor for that.
Take another look at the first post in the examples for the helpers. The time limits are input_datetime’s and the wait time before the entity turns of is an input_number.
To turn off entities/lights that are part of a scene, set the entity that you want to turn off as the target_off_entity. If it concerns multiple entities, create a group for them and set this group as the target_off_entity.
I expect if you set the no_motion_wait helper entity to 0, the entity will turn off as soon as no more motion is detected. However, I wonder how useful this is if your motion sensor has a low cooldown time.
The use of helper entities is a design choice I made for this blueprint. However, you do not have to display them on lovelace in order to set them. You can set entity values from the developer tools page in Home Assistant.
Maybe I misread something, But I cannot figure out what I’m doing wrong:
I have the most simple automation with a door sensor.
If the door opens, a light should turn on inside the house.
When the door closes the light should stay on for a minute.
My Settings:
Motion sensor: door sensor
Target entity: light inside the house:
(OPTIONAL) Turn off wait time (minutes): 1
everything else is not filled in.
When the door opens my light turns on. But when I close the door the light turns of directly and doesn’t wait for 1 minute.
I can set the turn of wait time to 1, 5 or 10, the light always turns of directly when the door closes.
be good to have the option for only turn the lights on when the sun is set/before sunrise. rather than/in addition to a fixed time, for those who don’t have illuminance sensors.
Tried it, didnt’t work. I know use the blueprint from the link below. Also set a no_motion delay and that works. So I think there is something wrong with this blueprint.
There is not something wrong with this blueprint, otherwise we would have more complaints
Like @beurdy said, you cannot use hardcoded values for the no_motion_wait variable. You need to use an input_number helper enttity, this is described in the first post.
In the end the automation would then look something like:
I think there are plenty of other blueprints what support the sunrise/sunset scenario.
If I would add it also to this only it would become a bloated mess I’m afraid.
Yes I am sure. I have changed the target entity to multiple things. Originally I made a scene that would do multiple things once activated but when it was activating any time motion was detected I tried simplifying it with a couple different lights and outlets (one after the other, not all at once). But no matter what time I put in the input_datetime I couldn’t get this blueprint to fire correctly. I ended up makeing a automation that triggers a script. The automation is like this (i’ll post the script below it):
alias: Weekday Wakeup
description: ''
trigger:
- platform: state
entity_id: binary_sensor.lr_motion
to: 'on'
condition:
- condition: time
after: input_datetime.wake_time
before: input_datetime.end_wake_time
weekday:
- mon
- tue
- wed
- thu
- fri
action:
- service: script.wakeup
mode: single
…and the script is below (it turns on various WLED instances, opens youtube on the TV and a few other things but most importantly it turns off the above automation, otherwise additional motion would continue triggering the automation. There is also a 3rd automation which simply turns on the above automation everyday at 4am (it doesn’t trigger it, just turns it on and makes it available for when motion is detected):
these were built with the visual editor and could probably be condensed and simplified but it was my work around at the time back in June and has worked reliably since then.
Trying to set-up this Blueprint for the first time. Want to use the illuminance sensor but when I select the picker it shows “No matching entities found”. I have 3 different sensors that all support luminance.
Can someone help. The blueprint works however the sensor I use is a door sensor. Unfortunately the automation runs when I close the sensor/door, when I actually want it to turn on when opening door. So can I get it to work the other way around? Any advice appreciated.