Hello, i’m new to HA and therefor have a simple (or so I thought) motion and LUX activated light.
Below a given LUX level the light is supposed to turn on based on identified motion in the room. Does not work.
I’ve tried two different motion sensors and LUX sensors.
I’m not familiar with traces, so do not understand the error messages it is sending, see below. Perhaps someone can help me interpret these messages?
Executed: February 9, 2025 at 08:39:54
Error: In 'not': In 'state': In 'state' condition: unknown entity input_select.home_mode
conditions/0
[Error in describing condition: Cannot read properties of undefined (reading 'entity_id')]
Executed: February 9, 2025 at 08:39:54
Error: In 'state': In 'state' condition: unknown entity input_select.home_mode
conditions/0/entity_id/0
[Error in describing condition: Cannot read properties of undefined (reading 'entity_id')]
Executed: February 9, 2025 at 08:39:54
Error: In 'state' condition: unknown entity input_select.home_mode
entity: input_select.home_mode
Ok, now i’m really confused. As sain, i’m a beginner.
But the script you sent was not the yaml file i posted, or? Is so, why did i now see this portion (input_seletc…) in my yaml file?
And, what precisely should i delete?
As of a few releases ago, you don’t need to mess around in that directory to edit a blueprint for a particular automation.
Simply open up the automation page where the blueprint is in use > click the 3 dot menu at the top right > choose “Take Control”.
This lets you edit the blueprint right in the GUI
Hello and thanks.
So learned now that when i import blueprints it’s not just the text or yaml that gets imported, but a link back to where the blueprint was found, with some additional entries?
These entries were not mentioned in the video i watched, so i thought it was a simple way to get such an automation.
If I now need to begin editing in yaml, which as a noob i’m struggling with, it makes the benefit of the blueprint a bit useless.
My original objective was an automation that turns on lights based on movement and max lux level.
I have another automation that i’m playing with that is supposed to do the same, but in that one the lights turn off, even when motion is still there and the room is below max LUX.
Perhaps there is a easy error here:
alias: Office Light Motion Lux control
description: ""
triggers:
- trigger: state
entity_id:
- binary_sensor.office_occupancy764_occupancy
from: null
to: "on"
conditions:
- type: is_illuminance
condition: device
device_id: 08b00cb685dfc8dbd2939866a1cac729
entity_id: 284b4a8a3524c32bcb0360373c47fc35
domain: sensor
below: 3000
actions:
- alias: Turn on the light
action: light.turn_on
data:
kelvin: 3304
brightness_pct: 59
transition: 2
target:
entity_id:
- light.officevitrine55f0
- light.office_desk_lamp
- light.petraofficedesk53de
- alias: Wait until there is no motion from device
wait_for_trigger: []
continue_on_timeout: false
timeout:
hours: 0
minutes: 0
seconds: 3
milliseconds: 0
- alias: Wait the number of seconds that has been set
delay:
hours: 0
minutes: 3
seconds: 0
- alias: Turn off the light
action: light.turn_off
data:
flash: short
transition: 5
target:
entity_id:
- light.office_desk_lamp
- light.officevitrine55f0
- light.petraofficedesk53de
mode: restart
max_exceeded: silent
From a quick test, “taking control” means extracting a full-fledge automation from the blueprinted one, right?
So you’re not actually editing the blueprint, but creating an automation that doesn’t use the blueprint.
Yep indeed. You’re basically creating an automation with the blueprint as a starting point.
Same as using a regular blueprint, but fully customisable per automation. Quite handy when needing to create a bunch of automations based off the same blueprint, each with different mandatory inputs.
yes but, if i’m only editing in the visual editor i do not even see the kind of entry that is causing a problem in my case. It was only visible while editing in yaml, which as a noob i’m avoiding doing.
If you want the light to turn back off when motion has no longer been detected, then you need to define an actual trigger in the wait_for_trigger part and set continue_on_timeout to true.
Ok, thanks all for the help.
I think i need to start with something even much simpler…i’m losing the sight for the forest due to all the trees.
I’ll come back to this one later when i’ve learned a few more fundamental things.
Somehow i keep running into one problem after another, and thougth that blueprints would be the “no brainer” of how to start with automations…
I just wanted to turn some lights on and off based on motion and max LUX level.