💡 Sensor Light - Motion Sensor - Door Sensor - Sun Elevation - LUX Value - Scenes - Time - Light Control - Device Tracker - Night Lights

@Blacky - sure thing :slight_smile:

I have a few automations in which I activate the ceiling lights by motion.

At night I have light strips automatically turned on so I don’t want the ceiling lights to turn on when motion is detected since the lightstrips emit enough light.

Hi I have a playarea that I want to use this blueprint with but I only want the light to trigger only if there has been presence for 2 minutes. if I make a automation from scratch this can be done by using the “For” option after selection the motion entity

example
platform: state
entity_id:

  • binary_sensor.mmwave_21_251f7c_zone_1_presence
    for:
    hours: 0
    minutes: 2
    seconds: 0

Is this possable to add or is there a helper that I could setup for this?

When you turn ON your light strips also turn ON a toggle helper and then put it in bypass option 2.

Blacky :smiley:

@littlekools

Welcome to the community.

Have a look at this link on how to create a template Click Here. Look at CCTV Camera Motion Sensor. Once created add this to your trigger.

Blacky :smiley:

1 Like

Hi. First time I check out this blueprint. Looks very nice. However, I have a question. I want to use dynamic lighting only, do I still need a trigger? My plan is to enable the automation when the house “wakes” and disable it at “night time”. I have a really hard time getting the dynamic lighting to work. I set a flashlight to the sensor to trigger the lowest light settings, but nothing happens, the automation never gets triggered.

@vegard

In order for dynamic light to work the trigger must be ON.

Looks like you would like trigger points. A state change (ON) when your house wakes up and disable at night time. Have a look at this blueprint :high_brightness: Smart Light - Entity - Sun Elevation - Ambient & Time Triggers this triggers on state, sun, ambient and time. Then use dynamic lighting. I will be updating it so you can use the sun triggers for daytime.

Blacky :smiley:

@Blacky Hello. I am using “Sensor Light” + “Manual Light” for the same light in room.

Sensor Light:

  1. :white_check_mark: Enable the Bypass - Keep the lights current state
  2. :white_check_mark: Enable the auto OFF for the bypass switch - Keep The Lights Current State
  3. Bypass - Time Delay: 1 minute. If I set 0, then if there is no movement at the moment of switching the bypass, the light immediately turns off

Manual Light:

  1. :white_check_mark: Enable the motion sensor option
  2. :white_check_mark: Enable the timer helper option
  3. Timer delay: 10 minutes

I think the “Manual Light” script should add a timer pause using a bypass to synchronize automatic and manual light for the same lighting.

I added a simple integration.
Triggers:

  1. Timer changed state to active
  2. Bypass state changes (any)

Actions:
If bypass is on:

  • timer pause

Otherwise:

  • start timer

However, after some time, the logic of the light completely breaks down and it starts to turn off after just a few seconds (there is no strict constant)

Thanks for the quick reply. I think I’ve figured it out now :slight_smile: :+1:

1 Like

@Blacky - works like a charm. I guess I didn’t get the function of the bypass right - thanks for the help and the clarification :slight_smile:

1 Like

Thank you for the help. this is my first attempt at a yaml template but i beleave i did got it working. after standing in the middle of the zone for 2 minutes the sensor turned on

what i set up
template:

  • binary_sensor:
    • name: ‘playroom mmwave 2min delay’
      device_class: motion
      icon: mdi:motion-sensor
      state: >
      {{ is_state(‘binary_sensor.mmwave_21_251f7c_zone_1_presence’,‘on’)}}
      delay_on:
      seconds: 120

I’m too embarrassed to admit what was wrong. Just wanted to thank you for taking the time to respond with support.

1 Like

@SeRG1k17

Hi Sergey. thanks for the clear information. I haven’t thought about this link. I put it on the list.

Blacky :smiley:

@littlekools

Nice one looks good… you even updated the icon, nice work.

Tip: If you would like to use minuets you can do it like this.

template:
  - binary_sensor:
      - name: ‘playroom mmwave 2min delay’
        device_class: motion
        icon: mdi:cctv
          {{ is_state(‘binary_sensor.mmwave_21_251f7c_zone_1_presence’,‘on’)}}
        delay_on:
          minutes: 2

Tip: If you would like to use minuets and seconds you can do it like this.

template:
  - binary_sensor:
      - name: ‘playroom mmwave 2min delay’
        device_class: motion
        icon: mdi:cctv
          {{ is_state(‘binary_sensor.mmwave_21_251f7c_zone_1_presence’,‘on’)}}
        delay_on:
          seconds: 30
          minutes: 2

Blacky :smiley:

1 Like

Maybe you understand why my simple script breaks the logic of the light after some time. The light starts to turn off without any regularity but literally after 5-10 seconds :frowning:

1 Like

Dear Blacky,

I’m new here with HA, and just stumbled on your automation just a few days ago. I have set it up to control the lights underneath the outside pergola, and in the trigger group I have both a motion sensor and a door sensor that leads to the pergola, and it works great - thank you.
The only problem I have is if I switch the light switch on manually rather than activating the automation by opening the door or the motion sensor, then the light doesn’t turn of after the predefined time.

I’m struggling to figure out how to get this automation to work (ie to turn of the light after the time delay), when the lights have been switched on by the physical light switch?

If you can please point me in the right direction, that would be very much appreciated.

Thanks,

Jk

@JK200SX

I have another blueprint just for the light switch in Beta, would you like to try it?

What it will do is notice you have turned the light on manually and then you add a input helper into the bypass. You then can use the auto bypass OFF in this BP to turn your light OFF in X amount of time. The lights will stay ON until you turn them OFF or if you have auto off enabled.

Blacky :smiley:

Yes, sure, thank you. Would that automation replace the current one?

No, it is just for the manual switch. You then use a helper in the bypass option 1.

I will set it up and PM you the download link.

Blacky :smiley:

Thanks. Looking forward to trying it!

All done look at your PM messages.