You can use the âTrigger Sensor By-passâ for this and you will have full control. See our FAQ on âHow to use the âTrigger Sensor By-passâ without having a physical switch?â if you like.
Your YAML looks good. Could you try setting your night light brightness to â10â. Just thinking it could be your light and if it works at â10â in normal time it should work in night light time.
Hello!
Thanks for the Blueprints - Iâm new to Home Assistant and have several Hue motion sensors and configured them with the Hue app so far and have now switched everything to Home Assistant and with the Blueprints it works really well. The only thing Iâm missing or maybe havenât found is the ability to adjust the motion sensitivity of the motion detector - I have two motion detectors that are only supposed to trigger at very short distances⌠can you still integrate this?
I have tried adding the condition to my blueprint but I am not having any luck.
This is the blueprint I am using:
blueprint:
name: Motion-activated Light via Switch
description: Turn on a light when motion is detected.
domain: automation
source_url: https://github.com/home-assistant/core/blob/1d9e8c873fb31d27f392a8a3eda5f72886220256/homeassistant/components/automation/blueprints/motion_light.yaml
input:
motion_entity:
name: Motion Sensor
selector:
entity:
domain: binary_sensor
device_class: motion
light_target:
name: switch
selector:
target:
entity:
domain: switch
no_motion_wait:
name: Wait time
description: Time to leave the light on after last motion is detected.
default: 120
selector:
number:
min: 0
max: 3600
unit_of_measurement: seconds
# If motion is detected within the delay,
# we restart the script.
mode: restart
max_exceeded: silent
trigger:
platform: state
entity_id: !input motion_entity
from: "off"
to: "on"
action:
- alias: "Turn on the light"
service: switch.turn_on
target: !input light_target
- alias: "Wait until there is no motion from device"
wait_for_trigger:
platform: state
entity_id: !input motion_entity
from: "on"
to: "off"
- alias: "Wait the number of seconds that has been set"
delay: !input no_motion_wait
- alias: "Turn off the light"
service: switch.turn_off
target: !input light_target
I have tried to input a condition for time into this but I am not getting it to only trigger the lights between certain times of the day when the lights in the room are not needed. All I want to do is set a start and end time for the automation to work so it only works between certain hours of the day. I know it is simple, but I am not having any luck getting it done. Can someone help?
Sorry this blueprint will not adjust the sensitivity of your motion detectors. Some motion detectors have adjustments physically on them and some have software to do this. I would start there.
Hi Aaron, please stay on topic and not post something about your blueprint (HA Blueprint) on this blueprints thread.
Consider moving it to a new topic of your own or asking a question about this blueprint.
If you use my blueprint you can achieve what you would like to do. Use the âImport Blueprintâ blue button at the top to get the blueprint.
Once you import the blueprint go into the blueprint and enter your motion sensor into the âTrigger Sensor - Binary Sensorsâ then your lights into the âLights - Switches - Scenesâ. Now In âUse The Time Options (Optional)â select âEnable the time optionsâ then select the start time, end time and weekdays and then click save, enter in a name you like and your done.
You can then use the blueprint again to create another automation being the same or you may choose different options next time. So it can be a blueprint that you use for many different automations.
Having an issue with my ambient light sensors. I just updated to 2.8 and now I canât pick my Zooz ZSE40 Z-Wave sensors anymore. The sensor shows Illuminance, but when I click the ambient light sensor dropdown, it says âNo Matching Entities Foundâ. I used to be able to select it in previous versions, but it just seems to be missing now.
If you try and create a new automation can you select it?
If not I will have a look at it for you. Could you provide us your YAML of your automation.
Go into your automation and 3 dots at the top click on it and select âEdit in YAMLâ. Copy the code. When you post it into this forum use the â</>â and paste it in there.
I created an automation to switch on all lights in an area. After that I asigned the automation to this area. So I see all configuration about this area with one view.
When the automation starts, it switch the lights on, wait until the timeout und switch everything off in this area, including the automation itself.
Is there a way to use areas, asisgn automation to areas but exclude automations from turning off?
// EDIT \
Maybe the automation should only turn off the lights (no switches or else)?
Hi Ellis, thanks for your question and providing your yaml. You are using a device and the option âYES - My Ambient Light Sensor is affected by the Lightsâ. You will need to expand your device by clicking on the â<>â next to the name and use entities rather than a device. When using the option âYES - My Ambient Light Sensor is affected by the Lightsâ you will need to have at least one entity selected for this option to work.
firstly welcome to the community and your question.
This is not a bug as if you asigned the automation to a area and you turn it off then it will turn off everything.
This is why in the top notes we say âBE CAREFUL when selecting an Area or a Device as it will turn On and OFF everything attached, lights, switches, etc.â
You would be best not to assign the automation to an area if you are using this option otherwise you will need to expand the area and use devices or entities.
Iâam new to the topic home assistant and searched for an automation. So I found your blueprint âSensor Light - âŚâ
What I was expected: Control the lights
What I get: Control every device, including automation and so on
For me personally, it is a mismatching between expectations and reality.
For example: I use switches with measurement for our fridge and so on. Itâs not the best way to disable this device after leaving the room
But I donât want to criticize you, I want to improve. So here are different ways, which I couldnât assess enough. Maybe you could help?
turn off only lights (and maybe switches)
1.1. use âlight.turn_offâ
1.2. use additional / optional âswitch.turn_offâ
Mayby with an selector at the beginning, which devices (-domains) should be disabled at the end?
use only entities with domain light
2.1. with filter at the beginning
You use the domain filter at the target selector. Why you add also switch to it?
selector:
target:
entity:
domain:
- light
- switch
- scene
When you use âonlyâ switch and lights at the beginning, why you turn off everything and not only lights?
I think, if somebody want to use a switch as a light, he could also use the âswitch as xâ helper, canât he?
2.2. with filter for variable âlight_switchâ
I tried with the template engine (developer tools) and get an example: