Can it be made to accept any sensor?
I.E. Use a battery sensor to toggle a the smart plug where the charger is when the battery is below X%.
And disable when battery above Y% percent?
Hi Tiago, have a look at another one of my blueprints called Temperature Control Exhaust Fan - Inverted. I think this is what you are after.
Iâll try it, it does seem to be able to accomplish my idea. But the name kinda threw me away xD.
Yea the name will throw you, but when saving it you will have the option to rename it.
Good luck and hope this helps you.
Blacky
Good point. Iâll do that.
Much appreciated for your work in these fine blueprints.
I use Sensor Light as well.
BLUEPRINT CODE UPDATE
Just a heads up if your still on a old HA version before you update.
From time to time Home Assistant update their code structure and the old code will become âDEPRECATEDâ stopping / breaking automations from working. It effected this blueprint about 4 to 6 months ago. I wanted to wait some time so everyone had a chance to update their HA version before updating the code as older HA versions can not run the new code. This blueprint has now been updated so it will still operate once HA remove the âDEPRECATEDâ code from their system.
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
Hi
Is there a way of adding conditions to the trigger ? For example, I have an alarm system which is integrated to HA, so I want to trigger the lights based on
- The Alarm systems âsunset flagâ
- The alarm systems mode (ie, dont trigger if set to night mode).
Thanks,
Eamon
Hi @Wexfordman
I would have to add this option in. Give us a few days so I can have a look at it and I will get back to you.
Blacky
I have done this, before I update it could you confirm your âsunset flagâ domain. If you are unsure what this is could you please copy paste the entity ID in here.
EDIT: Donât worry I am going to change this so you can have any domain you like.
Some work is required in this upgrade. Please see below on the steps required when upgrading. It is easy and not a breaking change.
Upgrade Features
- Binary Sensor: âUse The Binary Sensor Option (Optional)â, as been upgraded to âUse The Entity State Option (Optional)â. This now allows you to enter in any entity you like and not just a binary sensor. The entity still must have an ON / OFF state. Because of this update you will need to update your YAML as shown below.
New Features
- Global Condition: You can now add in any global condition you like.
STEPS REQUIRED WHEN UPGRADING
If you have never selected to use a âBinary Sensorâ then most likely you wonât need to do anything but you may want to check just encase you have selected âBinary Sensorâ in the past.
1 - Upgrade your blueprint.
2 - Go into your automation (the ones using this blueprint). Click on the 3 dots top right and edit in YAML.
3 - We are looking for the words⌠âinclude_binary_sensorâŚâ & âbinary_sensorâŚâ. If you donât see them then you are all good, nothing to do. If you see them then read on.
4 - We need to delete the 2 lines, click save then the 3 dots and edit in virtual editor.
5 - Then you will need to enable the entity state option and enter in your binary sensor again into input entity.
6 - Click save, youâre done. Now just do the same in your other automations using this blueprint.
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
Thanks blacky, will give it a go over the weekend
Awesome⌠Thanks, @Blacky for your blueprints. I think I use all of them now
Anyway⌠maybe a silly question. I have enabled the ambient light option, set to trigger at 3 lux. But when will the blueprint actually trigger? (1) When the illuminance sensor is 3 (or below) for the first time, or (2) every time when the illuminance sensor reports 3 lux or lower?
I want to use this blueprint to manage my livingroom lights. But when I go to bed, I turn the light off, and then should remain off (obviously). In case of (2) the light will go on again as soon as the illuminance sensors sends an update.
Edit:
Can you add the option that the illuminance sensor is influenced by the light? Just like you have in the other blueprint?
No it will not work that way.
Looks like you are only needing it at night time. If this is the case then try using the sun condition as it will then work for you. The sun elevation can be very close to a lux value. If this is not the case then let me know.
Blacky
No, not really. For example:
Today is a really rainy day. Itâs over 30 minutes until sunset, but the light is already really low (below 7 lux in my room) This causes the light to go on/off every couple of minutes. Just because the lights raise the lux again above the thresholdâŚ
O okay, let look at a few things then
EDIT: Update to then new version 1.7 and set a dead ban between ON lux value and OFF lux value. Could you please provide some feedback here if it now works.
With the problem of the light coming back ON try and use the global conditions and set the sun as a condition. This should disable it 1 hour after sunset and it should be dark and enable it at sunrise to start the day again. So during the day it will work, once it gets dark the condition stops it so when you turn your light ON / OFF at night it will just be manual control. The light will still turn ON at when it gets dark at night (1 hour offset) but you will have to turn it OFF manually when you go to bed.
Blacky
Some work is required in this upgrade see below.
Upgrade Features
-
Ambient Light Sensor: We have now added a LUX value for ON and OFF. You can now set a dead ban so you light doesnât turn ON and OFF to fast on a cloudy day.
Below shows the OFF value higher than the ON value. This will work
Below shows the ON and OFF values equal. This will work
Below shows the OFF value lower than the ON value. This will not work
STEPS REQUIRED WHEN UPGRADING
If using Ambient Light Sensor then you will need to set your OFF value. Below shows a dead ban of 80 lux.
If you would like to keep it the same before this update then set the OFF vale the same as the ON value. Below show the setting the same as before the update.
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
For the life of me, I canât get this blueprint to work and I admit, it is probably user error on something I donât understand. This is as simple as it gets. Living room lamp, turn on with 100% brightness at 5:45 am. Thatâs it! It doesnât run.
Anyone have any thoughts on what Iâm missing?
Everything looks good. I have tested it here again using a device and your set up, just a different time and it works. Things to look at are;
- Do you have the correct device?
- If you have the correct device then expand down to an entity. Maybe it not working with your device, it should but stranger things happen. To expand down to an entity click the â<>â button next to your device name and remove any entities that you dont want to control so you just have your light entity. Below shows you were the button is.
Let us know if this works for you.
Blacky
Finally had the chance to test v1.7. Tnx for adding this @Blacky!
It is almost perfect⌠only thing is that if you add a sunrise/sunset to the global conditions, the whole blueprint doesnât work when this condition is false. Even the manual on/off switch (the by-pass). So when I go to bed, I am unable to turn off the lights
So⌠if the above is correct⌠can we exclude the by pass from the global conditions?
No problem
I just checked it here with a global sun condition and it works how it should so not realy sure what you are doing. If you set a global condition for the sun then it will ether allow the blueprint to work or stop the blueprint from running. Maybe try reversing your sun selection.
Blacky