Jump to content
View in the app

A better way to browse. Learn more.

Universal Devices Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Door sensor turn on light then stay on 5 min after close. program vs scene

Featured Replies

Posted

I currently have a scene with a light and door sensor.  The light turns on and off instantaneously when the door is opened and closed.

I want to adjust this logic so the light will remains on for 5 minutes after the door closes.  The only way I can figure to do this is to remove the light and door sensor from the scene and create  program that when the door is open turn on the light then another for when the door is closed, wait 5 minutes then turn off the light.  What is fear is that the program will delay the how quickly the light turns on.  I really cannot have a delay to the on function.

Is there some other way to achieve this?

Couldn't you just leave the current scene, then have a program that if status of light is on then wait 5 mins and turn off?

I use 2 programs:

Entry Light On - [ID 0005][Parent 0046]

If
        'Devices / Sensors / Door / Front- Door Sensor' Status is On
 
Then
        Set 'Rooms / Entry / Entry Ceiling Light' On
 
Else
        Run Program 'Entry Light Off' (Then Path)
 

 

Entry Light Off - [ID 0006][Parent 0046]

If
   - No Conditions - (To add one, press 'Schedule' or 'Condition')
 
Then
        Wait  1 minute 
        Set 'Rooms / Entry / Entry Ceiling Light' Off
 
Else
   - No Actions - (To add one, press 'Action')
 

33 minutes ago, TomL said:

Couldn't you just leave the current scene, then have a program that if status of light is on then wait 5 mins and turn off?

If the door is left open it would work but he wants the light to stay on once closed

16 hours ago, uffy said:

I currently have a scene with a light and door sensor.  The light turns on and off instantaneously when the door is opened and closed.

I want to adjust this logic so the light will remains on for 5 minutes after the door closes.  The only way I can figure to do this is to remove the light and door sensor from the scene and create  program that when the door is open turn on the light then another for when the door is closed, wait 5 minutes then turn off the light.  What is fear is that the program will delay the how quickly the light turns on.  I really cannot have a delay to the on function.

Is there some other way to achieve this?

No. Scenes resides in devices which respond much faster than programs can so there no way to override it. 

There will be a delay with a program but wouldn't be too much of one. I'd try it and see how bad it is. You may be able to live with it. 

  • Author
1 hour ago, markv58 said:

I use 2 programs:

Entry Light On - [ID 0005][Parent 0046]

If
        'Devices / Sensors / Door / Front- Door Sensor' Status is On
 
Then
        Set 'Rooms / Entry / Entry Ceiling Light' On
 
Else
        Run Program 'Entry Light Off' (Then Path)
 

 

Entry Light Off - [ID 0006][Parent 0046]

If
   - No Conditions - (To add one, press 'Schedule' or 'Condition')
 
Then
        Wait  1 minute 
        Set 'Rooms / Entry / Entry Ceiling Light' Off
 
Else
   - No Actions - (To add one, press 'Action')
 

How will this respond to the door opened then closed then opened then closed again 30 sec later?  Will the light turn off 1 minute after the first closure or the second?

Edited by uffy

1 minute ago, uffy said:

How will this respond to the door opened then closed then opened again?  Will the light turn off 1 minute after the first closure or the second?

As written if the second opening is during the wait it will restart the wait, so one minute after the second opening.  

There is a way to force the one minute wait to expire and the light to shut off before it can be re-triggered.  Takes 2 more lines in the 2nd program:

 Entry Light Off - [ID 0006][Parent 0046]

If
   - No Conditions - (To add one, press 'Schedule' or 'Condition')
 
Then
      	Disable Entry Light On  
		Wait  1 minute 
        Set 'Rooms / Entry / Entry Ceiling Light' Off
		Enable Entry Light On
 
Else
   - No Actions - (To add one, press 'Action')

 

Guest
This topic is now closed to further replies.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.