Jump to content

Conditional commands


gschoffstall
Go to solution Solved by paulbates,

Recommended Posts

A program acts to turn on a set of lights. It has IF commands to check if a motion sensor is on, a remote switch has been pressed, or if an X10 command has been issued. I need to make the program time sensitive to make the lights come on dim within a time range, but leave the rest of the functionality alone. Can this be done within the same program? If not, how? Thanks.

Link to comment

Here's the subject program as it is currently working. Problem is, at night the 100% command is jarring. I want to modify the action of the motion detector to only set the Bedroom 2 level at 20% between, say 10:00 pm and 6:00 am. I just don't know how to fit that in with the current structure. Any suggestions are welcome. Thanks.

image.png.31d52cf0d7787b826306bf759547e6c4.png

 

 

Link to comment

I take a different approach. I have three programs - two for the conditions at night before and after midnight (Breezeway Motion Off Dim and Off Off) and one for the conditions during the day (Breezeway Motion Daytime). Then I use another program which runs at the crossover time and turns on the outside lights to also enable one program and disable the others. Then I use the program that runs at midnight and one that runs in the morning to change which of those is enabled and disabled. I just found this easier than trying to do it all in one program.

Sunset Actions - [ID 0003][Parent 000D]

If
        Time is Sunset 
 
Then
        Set 'Garage Sconces (SC)' On 20%
        Set 'Breezeway' On 15%
        Set 'Front Sconces (SC Front Dr)' On 20%
        Set 'Rear Sconces (Screen Porch SC' On 20%
        Set 'Front Balcony Sconces' On 20%
        Set 'Rear Balcony Sconces' On 20%
        Set 'Foyer Sconces' On
        Set 'Slat Wall' On 12%
        Wait  5 seconds
        Resource 'Notify Sunset'
        Enable Program 'PreDawn Sconces'
        Enable Program 'PreDawn Slatwall'
        Enable Program 'Breezeway Motion'
        Enable Program 'Breezeway Motion Off Dim'
        Disable Program 'Breezeway Motion Daytime'
 
Else
   - No Actions - (To add one, press 'Action')
 

Link to comment
1 hour ago, gschoffstall said:

Hey gang, I see a way to trigger events based on time, but I don't see a way to set a time window. What am I missing?

 

To add detail to Javi's comment, here is an example of a program that turns on lights at 6am and then off at 8am:

If
        From     6:00:00AM
        To       8:00:00AM (same day)
 
Then
        Set 'Ambient Lights' On
 
Else
        Set 'Ambient Lights' Off


 

Link to comment
Guest
This topic is now closed to further replies.

×
×
  • Create New...