Will do when I make it home. Two things to mention though. The bulb and the helper group Iām trying to use are Hues connected via the hue integration. I tried with a Zigbee plug connected via ZHA and it works. Thanks!
This blueprint seems to offer everything what I am looking for but havenāt found a solution for one of the cases.
I have:
- Hue fixture with ability to dim / change color
- Zigbee doorswitch
I would like:
- Light goes full on when door is opened during the day
- Light goes on in a dimmed state when door is opened after sunset/night
- Light goes off after x minutes
- Light goes off immediately when door is closed
All cases work flawless except the last one. If the timeout is set at 0; the light switches ON and OFF when the door is opened/closed. I would like to use the timeout only when opening the door and ignoring it when closing the door.
Is this scenario possible with this blueprint?
alias: TEST Sensor Light Blue Print
description: Living Room Lights and Presence Sensor
use_blueprint:
path: Blackshome/sensor-light.yaml
input:
motion_trigger:
- binary_sensor.living_room_occupancy_presence
light_switch:
entity_id: light.living_room_lights_group
time_delay: 3
include_dynamic_lighting: enable_sun_elevation_colour_brightness
dynamic_lighting_min_colour_temp: 2000
include_time: time_enabled
after_time: "15:00:00"
before_time: "07:00:00"
dynamic_lighting_max_colour_temp: 6500
include_night_lights: night_lights_enabled
night_lights:
entity_id: light.living_room_lights_group
night_lights_conditions:
- time_enabled
night_lights_after_time: "22:00:00"
night_lights_before_time: "06:00:00"
light_transition_on: 1.5
light_transition_off: 2
include_light_control: []
Yes put you will have to do a script. New update is coming out soon as well.
Blacky
Hi Dennis, please adjust your min brightness as it is set to 0 = light OFF. So if you set it on say 10% the light will come ON.
Blacky
IT IS A BIG ONE
Embarking on this journey, countless hours of dedication have been poured into our latest release, and I am thrilled to share it with you all. The top post has already garnered an incredible 201 likes ā thank you for your overwhelming support! If you havenāt already, please take a moment to hit the like button and show some love to the blueprint.
For those who resonate with my work and want to contribute further, thereās an opportunity to make a positive impact. A donation link is available to support ongoing projects. A heartfelt THANK YOU to those who have already generously contributed!
If youāre yet to make a donation and would like to be a part of this journey, consider clicking the Donation Link. Your small contribution goes a long way, and I genuinely appreciate your support!
Attention: Dynamic Lighting Enthusiasts!
Exciting news for users of dynamic lighting options 1 or 2! Weāve introduced some game-changing inputs that will enhance the functionality and take your experience to the next level.
If youāre keen on maintaining your current setup, itās a breeze! Simply follow these steps: Set the āStep Valueā to 100 and adjust the āDead Zoneā to 0. This guarantees that your original preferences will stay intact, ensuring a seamless continuation of your preferred settings.
Your lighting experience, your way ā take control and customize it to perfection!
New Feature
Dynamic lighting
I have updated LUX brightness from all your feedback and my own experiences. No longer will the brightness jump up and down to then when it gets close just change ever so slightlyā¦ that can be annoying. You now can take back control of your lighting transition to a more suitable setting and let dynamic lighting do the rest. If your lights only support brightness then that is no longer a problem, you can now slow it down using the step value. The āDead Zoneā is a Ā± value that realy helps. Think of it like this; Say the dynamic lighting would like to set your lights at 88%, if your dead zone is 7% then if your actual light brightness is in the range (āDead Zoneā) of 81% to 95% then your lights will not change the brightness value. 7% seams high but I have found when testing it is only realy less than 7% of what it should be and is not noticeable. The defaults have been set but you will need to adjust them to your liking.
Below is what been added to dynamic lighting.
- Step Value - With every heartbeat, the system evaluates the lux value, light brightness, and the targeted brightness. If the targeted brightness surpasses the predefined step value, the system applies the set step value to gracefully moderate the rate of changes, facilitating a smoother transition in light brightness.
- Dead Zone - With every heartbeat, the system evaluates the current light brightness and the targeted brightness. If the targeted brightness falls within the defined dead zone, the system maintains the current light brightness. This prevents minor fluctuations in light intensity that could be bothersome to the eye.
- Option 6 - Sun Elevation Lighting - Colour Temp + Lux Controlled Brightness. New option added for you light control.
Scripts
- You are able to run a script at the end like we already do with scenes. All you have to do is put your script in āScenes - Scripts To Turn OFFā and when the automation turns OFF it will run the end script.
Maintenance
- General code clean up - Just doing some housekeeping.
Bugs Fixed
- By-pass auto OFF ā When all three by-passes were ON, option 3 would not turn OFF due to an automation timing issue.
- Auto OFF Enabled ā When two or three were ON and one was turned OFF manually the by-pass auto off would not work.
- HA Restart - By-pass options.
If you like this blueprint? Consider hitting the button in the top post
If you like my blueprints, and would like to show your support or just say thank you? Click Here
Enjoy
Blacky
Great; I have updated immediately !
I assume I still would need to make a script to switch off the lights when using a doorswitch?
Awesome, really happy with the bypass fixes. Now I can restart my HA again without my spouse getting annoyed!
Hm, too soon. I am using a template (occupancy) sensor helper that detects if my TV is on and configured this as a bypass in āBy-pass Switch - Turn lights ONā. But after a restart it takes a little while before the helper becomes available and āoccupiedā again. The automation doesnāt handle this so the lights will turn off after the timeout (and wonāt turn on again on motion because of the bypass).
Okay, thanks for the feedback. We will fix it in the next release. How long does it take for it to become available?
Blacky
Thanks. Iām not sure how long it takes, I think a couple of seconds. Not sure how I can specify this, the unavailable state is not logged.
No problem, I will look at my system, the only thing is my system is realy fast so maybe on a RPi it could be slower. I will work it out.
Blacky
Hi Blacky,
First of all, thanks for the update and great support for this blueprint.
As the functionality is increasing with each update, also the complexity increases and more and more questions will be raised. You have created many FAQās and tips&tricks in this thread, but these are spread over multiple posts.
Is it possible to have alle the FAQās etc centralized on the GitHub so it will be easier to find the answers to all our questions.
+100. I LOVE Blackyās Blueprints, and his devotion to answering every question. But I think heād be doing himself (and us) a huge favor with a centralized FAQ/how-to instructions on Github. The Blueprints are very complex and having detailed help/FAQ/upgrade instructions in one spot would be a god send.
Thank you for the reply. Iāve set it for option 2-turn lights off and put the auto-off to 0. When I press the switch, the lights turn off and then immediately turn back on. Hereās my code. Maybe that will help someone spot my problem.
alias: Family Room Table Lights Toggle and Nightlight
description: ""
use_blueprint:
path: Blackshome/sensor-light.yaml
input:
motion_trigger:
- binary_sensor.presence_fp2_family_room
light_switch:
entity_id:
- light.family_room_left_table_bulb
- light.family_room_right_table_bulb
time_delay: 8
include_light_control:
- use_colour_temperature
include_night_lights: night_lights_enabled
night_lights:
entity_id:
- light.family_room_left_table_bulb
- light.family_room_right_table_bulb
night_time_delay: 1.5
include_night_light_control:
- use_brightness
- use_colour_temperature
night_light_brightness: 10
night_lights_conditions:
- time_enabled
night_lights_after_time: "21:00:00"
night_lights_before_time: "04:00:00"
light_brightness: 50
include_dynamic_lighting: enable_lux_controled_brightness
dynamic_lighting_lux_sensor: sensor.family_room_light_sensor
light_colour_temperature: 3000
dynamic_lighting_max_colour_temp: 3000
night_light_colour_temperature: 3000
include_bypass:
- bypass_enabled_turn_off
include_bypass_auto_off:
- bypass_auto_off_enabled_off
motion_bypass_lights_on: []
motion_bypass_lights_off:
- light.family_room_lamp_switch
motion_bypass_lights_stop: []
bypass_auto_off_delay: 60
bypass_time_delay: 0
Thanks, Blacky!
I updated to 5.7 and I think my problem has been fixed! Thanks!
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
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ā).
-
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? -
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
Lukas
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