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

You Sir are a Genius ! Iā€™m convinced Sun elevation was the problem looking back. Also great suggestions Iā€™ll give the a go as well. Thank You ! :smiley:

Hi Blacky, I have the version 7.1 (HA 2024.11) and I canā€™t updated to latest because of: iohttp.client_exceptions.ClientResponseError: 403, message='rate limit exceeded', url='https://api.github.com/gists/6edfec0ff6a25c5da0d07b88dc908238' . Is it something that you can fix? I see the error in other blueprints of yours but not other ones

@AutoShinobi

No problem glad you got it working.

Blacky :smiley:

@fumantsu

Looks like way to may people are downloading this blueprint per hour (must be over 1 per minute) as github has a rate limit. Try again at the start of the hour as they reset it then. I may have to ask them to increase it.

Let me know how you go.

Blacky :smiley:

1 Like

Hi Blacky,
Thank you for trying to help me!

My triggering entity (event.voordeur_beweging) does not have a state. In Developer Tools, States, I get this:

According to HA documentation: ā€œThese events do not capture a state in the traditional sense. For example, a doorbell does not have a state such as ā€œonā€ or ā€œoffā€ but instead is momentarily pressed.ā€

So thatā€™s why my Binary Sensor does not seem to work:

A workaround could be to create an automation that ā€œtransformsā€ the triggering event to a binary sensor using this trigger:

triggers:
  - trigger: state
    entity_id:
      - event.voordeur_beweging

But that would imply I would have always two automation rules (one to trigger the binary sensor, the other one containing your blueprint).

I donā€™t think thatā€™s an optimal approach.

@Blacky just want to say ā€˜Thank youā€™ :pray: again for this blueprint.
And especially for v7.3 introducing night glow itā€™s appreciated by everybody in the house at night! :night_with_stars:

@DriesA

Yea I thought that was going to be the case. The automation needs an ON / OFF stateā€¦ it canā€™t work even if you change the trigger. Can you upgrade your front door sensor? That would be the best way.

Blacky :smiley:

@nicknol

Hi Nick,

Your welcomeā€¦ It is really nice to get this feedback and I am really glad everyone likes it.

Blacky :smiley:

1 Like

I canā€™t, Itā€™s using the standard Doorbird integration, which works with events. I have now created an automation that changes an Input boolean based on the Doorbird event. And then I created a helper-binary sensor based on that switch, so I can trigger your blueprint.

Hi there and thanks a lot for this Blueprint. Iā€™m using it in a dozen of automations.
However, just stumpled across a case I could not easily apply: my Christmas light schedule.

  • I want to turn them on at dusk
  • turn them off at 23:00 to save energy
  • turn them back on at 06:00
  • turn them off at dawn

I tried playing around with sun in combination with time/schedule settings but didnā€™t manage.

Any support would be much appreciated :slight_smile:

1 Like

@DriesA

Nice one, glad you got it up and running.

Enjoy

Blacky :smiley:

@Stifter

Welcome to the community.

The blueprint you need is :high_brightness: Smart Light. It is one of my blueprints and is what I use for my Christmas lights.

Once you downloaded it you will need to use sun elevation and time triggers.

  • Sun Elevation Falling is your dusk, to turn ON your lights.
  • OFF Time is for your 23:00.
  • ON Time is for your 06:00.
  • Sun Elevation Rising is for your dawn to turn OFF you lights.

Enjoy

Blacky :smiley:

1 Like

@Blacky (and perhaps @Stifter)

Speaking about Christmas lights, I have the following situation:

Trigger Condition Action
isNightTime: ā†’ off luminosity below 80lux Xmas lights on
isNightTime: ā†’ on Xmas lights off
luminosity: ā†’ below 80lux isNightTime: off Xmas lights on
luminosity: ā†’ above 100lux Xmas lights off

isNightTime is a boolean helper which I set elsewhere depending on weekday/weekend/holiday and of course time.Typically starting at a time between 22:00 and 23:45 and ending at a time between 6:00 and 7:30.
luminosity is coming from an outdoor sensor.

I want the Christmas lights to be on when itā€™s not nighttime and when itā€™s somehow dark.

I couldnā€™t get my head around how to achieve my goal with one of your blueprints, @Blacky
Hence I created my own one, which might have some issues since it is freshly written by me - without much experience.

@nicknol

Hi Nick, thanks for the info. This is easy.

  1. Your trigger will be the NightTime boolean, but because you would like it ON when the NightTime boolean is OFF we need to invert it. To do this we can create a Template binary sensor helper.

    To create a Template binary sensor, follow these steps:

    • Navigate to Settings > Device & Services > Helpers tab at the top.
    • Click the Create helper button.
    • Select Template and then choose Template a binary sensor.

    Next, provide a Name and Device class of your choice. If applicable, you can link this template to an existing device so it appears under that deviceā€™s details.

    In the State template field, add the code below, replacing binary_sensor.your_night_time_boolean_here with your entity NightTime boolean ID.

{{ is_state('binary_sensor.your_night_time_boolean_here', 'off') }}
  1. Now that is created add it into the trigger.
  2. In Ambient enable it, add your lux sensor, set your Ambient Light - Low Lux Value to 80 and your Ambient Light - High Lux Value to 100.
  3. Add your light in.
  4. Save and your done.

Merry Xmass.

Blacky :smiley:

Thank you @Blacky

what would happen when the luminosity is getting below 80 but it is still nightTime?

my need is that the Xmas lights are not switched on, because it is still nightTime
and as soon as nightTime is over, the Xmas lights are switched on (assuming luminosity is still below 80)

@nicknol

What you do is once you create your template binary sensor helper (as shown above) then you add that helper into the trigger only in a new automation for your Xmas lights.

When isNightTime = ON (assume this is when you are sleeping) the helper will be OFF. Because the helper is the trigger and it is OFF the automation will not run.

When isNightTime = OFF the helper will be ON so now the automation can run. Because we set the ambient condition it can only come ON when it is below 80 and will turn OFF when it crosses over 100.

Blacky :smiley:

Hi,

After many years of using AppDaemon with custom apps, I recently discovered this and decided to give it a try. I had a couple of hiccups, but everything is now working well.

However, I have two issues, and Iā€™m hoping someone might know how to fix them:

  1. When the TV is on and it gets dark, the lights stay off because I have a bypass set up for the TV due to the Ambilight. However, when the TV is turned off, the lights donā€™t switch on automatically. They only turn on after the timer finishes and thereā€™s movement again. (Manually turning the lights on works fine.)

  2. I have kids, and sometimes one of them manually turns off the lights. When this happens, the lights stay off and wonā€™t turn back on until the timer finishes and thereā€™s movement detected again.

Any help would be greatly appreciated!

Keep up the great workā€‹:muscle::+1:

@botany112

  1. If you have a bypass and the bypass is ON it disables the automation.

    • When you turn the bypass OFF, your light is OFF and your motion sensor is ON then it will turn the light ON. No timer.
    • When you turn the bypass OFF, your light is ON and your motion sensor is OFF it will use the Bypass - Time Delay before it turns OFF your light.
    • If you lights is turned ON by a scene or a script then you need to use the Scenes & Scripts - Toggle Helper.
  2. When the automation is running and you turn the light OFF it will turn it back ON when the motion sensor goes from OFF to ON. No timer just need to be re-triggered.

Blacky :smiley:

Hello,
Iā€™ve just imported your blueprint but saving a very simple automation (1 trigger (binary sensor) - 1 light - no other options) always give me the following error while saving:
ā€œMessage malformed: extra keys not allowed @ data[ā€˜triggersā€™]ā€
I assume it has something to do with the selected trigger, but already changed to other binary sensors without luck
Kind regards,
Tim

@houdaerttim

Welcome to the community.

If you can update your Home Assistant then it will be resolved.

Blacky :smiley:

1 Like