šŸ’” Sensor Light - Motion Sensor - Door Sensor - Sun Elevation - LUX Value - Scenes - Time - Light Control - Device Tracker - Night Lights

Thanks, Blacky!

I updated to 5.7 and I think my problem has been fixed! Thanks!

@mars2020 @DuckDuck25

I 100% agree it would be realy nice to have a type of manual of the blueprint. I never initially thought it would just keep on growing like it has. I keep telling my wife ā€œI think it is all done nowā€. One can understand why she doesnā€™t believe me any more, but Iā€™m fortunate that she remains understanding.

I do have a FAQ and a ā€œThe Settings & Best Practice Guidelinesā€ Within the two links there are more links that take you to what you may be looking for. In every link you go to, down the bottom you will find 1 or 2 links that take you back to where you came from being the FAQ or ā€œThe Settings & Best Practice Guidelinesā€. I am not sure if this is the best way, but I am open to and appreciate your feedback.

Blacky :smiley:

Hey Blacky,

first of all a big thanks for this awesome blueprint!
I was fighting the whole last year to set up my presence sensors properly in Google Home. After switching to HA last week I was able to implement a basic lighting automation in minutes thanks to your blueprint. However Iā€™m facing the following two issues with my Aqara FP2 sensor and Iā€™m not sure how to get rid of them. I would be happy to get some tips from you.

As an example Iā€™ve four virtual switches in HA for the sensor: ā€˜tv zoneā€™ just in front of the couch, ā€˜dining zoneā€™ at the tables location, ā€˜kitchen zoneā€™ and ā€˜global zoneā€™ for the whole room (-> containing all zones ā€˜tvā€™, ā€˜diningā€™ & ā€˜kitchenā€™).

  1. As soon as I enter the room (-> presence detected for ā€˜global zoneā€™) thereā€™s one automation that enables the scene ā€˜darkā€™. All lights in the room will stay on for 2 minutes after the last presence detection and will be turned off after these 2 minutes.
    I enter the ā€˜dining zoneā€™, enabling a second automation. Only the dining lamp changes to my ā€˜brightā€™ scene for 1 minute after the last presence detection. After this 1 minute, the lamp will switch back to the ā€˜darkā€™ mode. This works flawless as long as I stay in the room. But by leaving the room (-> ā€˜global zoneā€™ switches to absence) and re-entering the room within the one minute (ā€˜darkā€™ scene still active, dining lamp still on ā€˜brightā€™) the ā€˜global zoneā€™ automation starts again, resulting the dining lamp to change to ā€˜darkā€™. Is there a way to prevent this behavior? Maybe to only run the ā€˜globalā€™ automation when the lights are off? But in this case the automation will not work to turn off the lights after two minutes, right? Whatā€™s about the by-pass option?

  2. As soon as presence is detected in ā€˜tv zoneā€™ only, the ā€˜tvā€™ scene with help of a third automation is being activated. Iā€™ve created a binary sensor via a template that starts the automation in case ā€˜dining zoneā€™ & ā€˜kitchen zoneā€™ are off and ā€˜tv zoneā€™ is on. By walking from the ā€˜kitchen zoneā€™ in the ā€˜dining zoneā€™ thereā€™s the problem that for a few milliseconds the binary sensor switches to on since the ā€˜kitchen zoneā€™ is already off but the ā€˜dining zoneā€™ not on at that point. Is there a way to adjust the template of the binary sensor that it only turns on when all requirements are fulfilled for at least one second?

I would be happy for any kind of support.

Thanks :grinning:

Lukas

1 Like

@Somedia

Nice one, I think a lot of people will switch from having just Google Home once they know about HA.

I am trying to get my head around it all, so I apologise if I have got it wrong. I see you are using scenes to control your lights. If you opt to use only a scene or script, itā€™s advisable to include just one individual light or switch as a separate entity used in your scene or script. This ensures proper automation functionality, as it can accurately reference that specific entity. If only a scene or script is used, the automation lacks awareness of the ON/OFF status of individual lights or switches, potentially leading to malfunctions in its operation.

So can you put one light entity from your scene used in the automation into ā€œLights - Switches - Scenes - Scriptsā€ You will end up having your scene and 1 light/switch entity. If possible best to just use the light control options with entities and no scenes, but you may be using colours so if that is the case then you will have to use scenes.

Test this and see how you go, let us know if you need more help and or if it worked.

Blacky :grinning:

1 Like

New update 5.8

Your lighting experience, your way ā€“ take control and customize it to perfection! :bulb::sparkles:

Maintenance :toolbox:

  • Safe guard HA restart function has been rebuilt. It is a lot cleaner.
  • Descriptions - Just doing some housekeeping.

Bugs Fixed :bug:

  • By-pass Option 1 ā€“ Turn On action - When all three by-passes were ON, option 3 would not turn OFF due to an automation timing issue.

If you like this blueprint? Consider hitting the :heart: button in the top post :+1:

If you like my blueprints, and would like to show your support or just say thank you? Click Here :smiling_face_with_three_hearts:

Enjoy

Blacky :grinning:

2 Likes

Hi Blacky, first of all, thank you for creating such a useful tool for us.

Iā€™ve got a question regarding the min/max values for sun elevation. Iā€™m just wondering why is there a fixed limit for the lowest possible start point for the sun elevation rising phase and the lowest end point for the sun elevation descending phase? In my example I wanted to decrease the light even later than -10 degrees.

The lowest possible start point for the Sun Elevation rising phase and the lowest end point for the Sun Elevation descending phase is set at -10 degrees. Below these specified points, the settings utilize their minimum configured values.

@erhardjo

Thanks for your kind words and welcome to the community.

It is there to help with adjustments and make it easy. If you would like to go beyond these set values just simply type the number in and click save.

Blacky :smiley:

Thanks for this awesome update!

Yes, I did, but unfortunately it did not work. I tried with -40 degrees, but when -10 degrees were passed, it decreased the light to the configured minimum brightness level.

Okay, I think Iā€™ve found the answer for that behaviour in the code of the blueprint. The limit of -10 degrees is in-line coded (e.g. line 3976, 4046, ā€¦).

@erhardjo

Sorry my bad, I didnā€™t read your question correctlyā€¦ :yawning_face: Thought it was the sun condition.

Yes it is limited to -10. I just thought it is dark by then and a few other thingsā€¦ What level do you want to go toā€¦ and can you maybe give me a use case so I can understand more.

Blacky :smiley:

Hey Blacky,

thanks for your advice, I wasnā€™t aware about the different behavior of scenes and entities.

So I added all lights separately to my ā€˜global zoneā€™ & ā€˜dining zoneā€™ automations. Unfortunately this led to the following two issues:

  • When I enter the room, the ā€˜global zoneā€™ automation turns all lights on to ā€˜darkā€™. As soon as I move into the ā€˜dining zoneā€™ nothing happens since the table lamp in this zone is already on (but should change to ā€˜brightā€™). I would expect the blueprint not only to verify if the light is already on but also if the defined brightness/color temperature is met and if not, to run the automation. Would this be a possible feature to implement in the future?
  • As soon as the one minute has passed in the ā€˜dining zoneā€™, the light turns off (instead of changing back to ā€˜darkā€™). Is it possible to somehow store the previous state of the light before the automation starts and switch back to it after the time has passed?

For now Iā€™ve set the lamps separately in the ā€˜global zoneā€™ and a scene in the ā€˜dining zoneā€™ automation what works as intended. However the transition feature isnā€™t working with scenes, what is one of the top features in my opinion.

Lukas

No problem :slight_smile: I also had a thought about it and maybe I tried to misuse the feature ā€œSun elevation lightingā€. (e.g. -40 degree would not work in summer) .

What I would need instead is a fixed time-based ramp down and ramp up in brightness and colour, according to my daily rhythm (which is not according to the sun). For example, a gentle reduction from 10pm to 2am to increase tiredness.

Just a quick post of appreciation. After runnig Domoticz for almost of 12 years. The last update messed up my Z-wave devices. As i always found Domoticz superior to the restā€¦ But WOW i have what a progress HASS has made!!! Incredible.

And this Blueprintā€¦its the proof of concept how dedicated this community isā€¦

Many Thanks. In just a week i am a big HASS fan!!

1 Like

Couple of questions @Blacky

  1. Should we allow some number of seconds in between one Sensor Light automation finishing (End Time) and another one starting (Start Time)?
    The reason I ask is that I have automation 1 that turns on light A and that automation ends at 6pm. Then I have automation 2 that starts at 6pm, and it turns on light A, B, & C.
    The result I get is that light A turns off and doesnā€™t come on again automatically during the run of automation 2.
    Light A is accessed via an integration - Nanoleaf. But it always turns on fine manually thru the GUI, or if I run the automation 2 manually.

  2. One of my Light Sensor automations always turns the lights off after the defined motion timeout period after I have rebooted my HA server. I think it may be the first automation I made with this Blueprint. None of the other instances of this Blueprint do this.
    Any idea why it would do this?

Cheers,
Geoff.

Hey @Blacky

First of all, this automation is pure genius. Its such a huge time saver for building a sophisticated light setup. I moved from the Philips Hue Bridge and your automation helped me a ton with it.

I could need a little help, though. In my setup I do not only have motion sensors but also switches.

What I am trying to achieve:

  • Use your motion blueprint for everything motion
  • If the light is turned on by a switch, I want to turn the lights on and massively extend the ā€œdelay before turn offā€ (like 60min, instead of 5 if triggered by motion)
  • If the light is turned off by a switch, I want to turn the lights off and wait before the light is triggered by motion again (ā€œcooldown for like 1 minuteā€)
  • If the lights are controlled by a switch (brightness, cycle scenes, ā€¦) I want the lights to stay that way (until they turn off by time delay of motion or switch) and not get overwritten to the default when motion is detected

What I did:
I made ā€œoverwriteā€ input_booleans for turning on, turning off and overwriting the automatically triggered light setup.
Those are fed into the three bypass options (ON, OFF and Keep Current State). This works perfectly fine. My only issue is with automatically turning off those input boolean helpers.
I built scripts which control the input_booleans, but as this is no finite state machine they sometimes end up in a scrambled/undesired way. (i.e. They do not get turned off after time delay. There are race conditions. It is especially bad if home assistant is restarted.)
ā€¦ And loads of helpers and scripts later I ended up thinking, that I may overcomplicate things.

Where I am now:
In desperate need of some input, of how I can solve this issue in a easy, smart and robust way. I think it would help me a great deal, if this blueprint had different Auto OFF delays for each bypass. This way I would only need to turn the entities on when a light switch is used. Or is there anything else I could do to make things easier?

Thanks again for this great Blueprint!

best regards

1 Like

Hi Blacky,
I am now on:

  • Core2024.1.5
  • Supervisor2023.12.1
  • Operating System11.4
  • Frontend20240104.0

I still get the following error with yot blueprint:

Invalid blueprint: extra keys not allowed @ data[ā€˜blueprintā€™][ā€˜inputā€™][ā€˜ambient_light_sensorā€™][ā€˜selectorā€™][ā€˜filterā€™]. Got None extra keys not allowed @ data[ā€˜blueprintā€™][ā€˜inputā€™][ā€˜dynamic_lighting_lux_sensorā€™][ā€˜selectorā€™][ā€˜filterā€™]. Got None extra keys not allowed @ data[ā€˜blueprintā€™][ā€˜inputā€™][ā€˜end_scenesā€™][ā€˜selectorā€™][ā€˜filterā€™]. Got None extra keys not allowed @ data[ā€˜blueprintā€™][ā€˜inputā€™][ā€˜motion_triggerā€™][ā€˜selectorā€™][ā€˜filterā€™]. Got None extra keys not allowed @ data[ā€˜blueprintā€™][ā€˜inputā€™][ā€˜peopleā€™][ā€˜selectorā€™][ā€˜filterā€™]. Got None extra keys not allowed @ data[ā€˜blueprintā€™][ā€˜inputā€™][ā€˜zoneā€™][ā€˜selectorā€™][ā€˜filterā€™]. Got None

Would you mind have a look into this?
Thanks for your awsome work.

I have a Zwave Fibaro Eye and want to switch a simple Zwave Wall socket which switches a Led Cove.

I have the following config: (pretty simple)

  • Trigger Sensor - Binary Sensors - Schedule * = Fibaro Eye Sensor state (Any)

  • Lights - Switches - Scenes - Scripts * = Entity LedCove

  • Time Delay = 0.5 (testing purpose)

  • Ambient Light - Low Lux Value = 8 lux

  • Ambient Light - High Lux Value = 10 lux

  • Ambient Light Sensor = Fibaro Eye Illuminance

But what ever value i put in the High lux Value its always turning on the switch/light
What am i overseeing here??

I have just migrated from Domoticz to Hass. So i have a lot to learn. But my Wife and Kids are moaning haha.

For now i have made an automation to turn your automation script on or off depending on luxā€¦

Hope someone can point me in the right direction

Blackyā€¦Iā€™m having trouble getting lights to reliably turn on and stay on when triggered by a group of binary sensors. The binary sensor group is a combination of PIR sensor PLUS a radar sensor made by Screek (https://www.screek.io/). I added the radar sensor so that it would continue to sense my presence even if I was sitting relatively still in the area.

The entities for the radar sensor are as shown in the attached picture. There is moving target, presence and still target. I put them all into the binary group, expecting that if any of those shows anything but CLEAR, it will trigger your automation.

But itā€™s not working. I come in the front door, the lights come on, but I sit down for longer than the time out in your automation, and the lights turn off. Yet, some of the entities are still not clear. Why arenā€™t the lights staying on?

I must be thinking about this wrong. Anywhere I should start to look?