Just to be sureā¦ we are discussing this option. Agree?
With that by-pass if the state is ON it will disable the automation. If the state is OFF it will enable the automation. Just tested it again and it is working.
Blacky
Still not sure if I understand you.
I want have have a manual (physical) switch that will turn off the lights when I go to bed. Is this by-pass the correct setting for that?
It looks like ON and OFF can only ever be used together.
But if you just want to turn off and not turn on, you canāt use the time feature, right?
I currently use automation in which I switch a light on and off based on brightness. But always switch it off at a certain fixed time.
This blueprint just turns things ON and OFF. You can add any condition you like and is why I put it there. So you could add a condition that state must be ON then it will only turn OFF.
To do this, add condition, click state, select your entity, select ON.
Blacky
Thanks for the blueprint. A suggestion, maybe move the time setting to the top, instead of the end. For me I need to make semi frequent changes to the time and I would think that this would be the most used section anyway.
Thanksā¦Steely
Thanks for your suggestion, I will add it to the list and keep it in mind.
Blacky
Hi Blacky,
Iām just feeling very stupid, I canāt seem to get the automation to work. I have a hue light and it looks like the only requirement is the first field which is specified with the entity of the hue, which can toggle using the entities page.
what am i missing, iām so desperate to use some of your great additions.
dumfounded dan
This blueprint can turn ON and OFF your light. You get to choose what you would like out of the 4 options. You can choose more than one option.
- Use The Entity State Option (Optional)
- Use The Sun Option (Optional)
- Use The Ambient Option (Optional)
- Use The Time Options (Optional)
If you are more after a sensor light that works from a PIR type of sensor then look at my sensor light blueprint.
Blacky
Hi
in part i have discovered part of my problem
Iām using momentary buttons for my switches, and as such the light comes ON with press and then OFF with release.
There may be some workaround but is it possible to add an on transition of state. When you create a standard automation using state as trigger you have the option of selecting a from/to state or both, but for a momentary button only one is required.
I will be interested in you thoughts on this.
looking up daniel
Hi Daniel,
I have 2 blueprints for this that you can check out;
Probably it would be best if you explain what you are trying to do, then I will be able to help and not give you a bum steer.
Blacky
This is my first message on this board so i hope i do i right.
First, thanks for this amazing blueprint but i have a question and canāt find the answer yet.
Iām not sure how the ON/OFF features relates to each other (AND/OR?)
This my use-case:
If it is a weekday AND after 16:00 AND LUX became below 300 (somewhere after 16:00), then turn on lights untill 22:00, After 22:00 do nothing.
This is what i have now:
alias: "- Woonkamerverlichting blueprint voor licht"
description: ""
use_blueprint:
path: Blackshome/entities-on-off-trigger-conditions.yaml
input:
entity_switch:
entity_id:
- light.ecodim_bv_ecodim_zigbee_3_0_level_on_off
- switch.servieskast_on_off
- light.televisie_rechts_level_light_color_on_off
- light.tz3000_49qchf10_ts0502a_24741efe_level_light_color_on_off
- light.zitbank_links_level_light_color_on_off
- light.zitbank_rechts_level_light_color_on_off
include_light_control: use_brightness
include_entity_input: entity_disabled
include_ambient: ambient_enabled
ambient_light_sensor: sensor.xiaomi_lumi_sen_ill_mgl01_illuminance
ambient_light_value: 300
ambient_light_value_off: 800
after_time: "16:00:00"
before_time: "22:00:00"
include_weekdays: weekday_enabled
weekday_options:
- mon
- tue
- wed
- thu
- fri
light_brightness: 50
Is this possible?
Firstly welcome to the community
Your welcome and thanks for your kind words.
Nice you put in a use case as this realy helps me answer your question.
Try this I have the same thing you are trying to do;
- Import my
Sensor Light blueprint.
- Create a schedule helper and set up your time from 16:00 to 22:00. Go to settings/devices & services/ helper tab at the top/ create helper button down the bottom / select schedule then enter in a name and just select the time you would like for each day and click create.
- In the āSensor Lightā blueprint this schedule will be your trigger. Enter it in.
- Select the entities you would like to turn ON and OFF in āLights - Switches - Scenesā.
- Now for your āLUX became below 300 (somewhere after 16:00)ā. You can āUse The Ambient Optionsā but because you have said āsomewhere after 16:00ā looks like you may like to use āThe Sun Optionā. I use sun but totally up to you, so choose what you would like. If you use sun then just the āSun Elevation Fallingā is the one you will need to adjust because you going to turn it OFF at 22:00 well before the sun rises. Tip: if you use āSun Elevation Fallingā then your starting time can be well before the sun sets like you have with 16:00. Either way if you set the time early your sun or LUX values will be the trigger to turn ON your entity and then it will turn OFF at 22:00.
Hope this helps you and let us know how you go.
Blacky
Thanks Blacky for this great response.
I think iāve set it al up but have one more question (for now ).
Iām not sure what to do with the Sun Elevation because i want it to depend on the weather conditions. IF it is a rainy day, lights go on after 16:00. But when itās sunny, lights stay off till LUX drops below ambient threshold (between 16:00 and 22:00).
alias: "-LICHT: Woonkamerverlichting"
description: >-
Schakel woonkamerverlichting aan na 16:00 (werkdagen) en als LUX lager is dan
300. Schakel licht uit als LUX hoger is dan 600. Na 22:00 niet meer doen.
use_blueprint:
path: Blackshome/sensor-light.yaml
input:
motion_trigger:
- schedule.ikbenthuis
light_switch:
entity_id:
- light.tz3000_49qchf10_ts0502a_24741efe_level_light_color_on_off
- light.televisie_rechts_level_light_color_on_off
- light.zitbank_links_level_light_color_on_off
- light.zitbank_rechts_level_light_color_on_off
- light.ecodim_bv_ecodim_zigbee_3_0_level_on_off
- switch.servieskast_on_off
include_ambient: ambient_enabled
ambient_light_sensor: sensor.xiaomi_lumi_sen_ill_mgl01_illuminance
ambient_light_value: 300
ambient_light_high_value: 600
weekday_options:
- mon
- tue
- wed
- thu
- fri
Time to test. See if i can generate some rainy clouds
All looks good. The days to run should be selected in your schedule but I can see that time is not enabled anyway so all should be good.
Yea then what you have selected āAmbient Optionsā will work for what you are trying to do. Perfect
Blacky
It works and iām very happy.
One little thing, not all entities go OFF when LUX is above high threshold.
Entity: light.ecodim_bv_ecodim_zigbee_3_0_level_on_off will stay on.
They should all go OFF. I would suspect a loss in communication or something on your end as we send the data to all.
Itās all working perfectly. Thanks for your help!
Hi,
Sorry its taken time to get back to you. I have 7 RPiās connected via the remote RPi integration which in turn support about 60 push buttons, they are mostly for Hue lights of different flavors, but some fans and a couple of heaters.
They are working via simple automations and basically just turn on/off.
I saw you great blueprint that could control a whole range of different functions.
Iām interested in turning some lights on/off at specific times and also some with reference to the sun.
Like: sunset + 1 hour ā turn light on
Turn light on/off according to the current ambient light level (i have a number of hue motion sensors that also include ambient light sensors)
I would also in the future like to dim lights using the button (which i can do using the app)
this is why i was drawn to your blueprint
daniel