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.

Programming a simple light timer program?

Featured Replies

Posted

Hi,

 

I have a new LED bulb & I was thinknig it would be nice to have it come on each night at 515pm & shut off at 1115pm.

 

This is what I have so far:

 

Program1:

 

If
       Time is  5:15:00PM

Then
       Set 'Main: Living Room LED Bulb' On

Else
  - No Actions - (To add one, press 'Action')

 

Program2:

If
       Time is 11:15:00PM

Then
       Set 'Main: Living Room LED Bulb' Off

Else
  - No Actions - (To add one, press 'Action')


 

Thanks,

Rich

Hi Rich,

 

This should work for your requirements.

 

With kind regards,

Michel

You might instead try.

 

If
       Time is  from 5:15:00PM to 11:15:00PM same day

Then
       Set 'Main: Living Room LED Bulb' On

Else
       Set 'Main: Living Room LED Bulb' Off

  • Author

Thanks, the single program seems cleaner!

Thanks, the single program seems cleaner!

 

It probably is a bit cleaner, if this meets your needs.

 

My only observation is that there are times when separating the two programs make sense. Keep this in mind as your needs and desires evolve.

Thanks, the single program seems cleaner!

 

It probably is a bit cleaner, if this meets your needs.

 

My only observation is that there are times when separating the two programs make sense. Keep this in mind as your needs and desires evolve.

 

This does become the case with multiple conditions besides on at one time off at another time.

 

For example, if you want it to turn on at one time only if the status of another light is off.

 

If from 8pm to 10pm same day

and status light x is off

 

Then

set light y on

 

Else

set light y off

 

The above program will run every time someone changes the status of light x. The result will by that light y turns off every time light x changes and the time is not 8 to 10. Also, if someone turns light x on between 8 to 10, light y will turn off.

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.