Ok, how about this? My goal is to have the outside lights turn on from sunset until 6:30pm. That is until sunset becomes after 6:30 pm then the lights just shouldn't turn on. In other words the lights would turn on and be on for a less and less amount of time each day until sunset becomes later than 6:30pm.
Variable Sunset is an integer and is set to 0 at sunrise (see program 3).
---------------------------------------
PROGRAM 1 (Sunset):
If
From Sunset
To Sunset + 2 hours (same day)
Then
$Sunset += 1
Run Program 'LightsOn' (If)
Else
$Sunset = 0
---------------------------------------
---------------------------------------
PROGRAM 2 (LightsOn):
If
From Sunset
To 6:30:00PM (same day)
And $Sunset is 1
Then
Set 'OutsideLights' On
Else
Set 'OutsideLights' Off
---------------------------------------
---------------------------------------
PROGRAM 3 (SunsetReset):
If
From 6:30:00PM
To Sunrise (next day)
Then
$Sunset += 1
Else
$Sunset = 0
---------------------------------------