Jump to content

Programming a repeating timer


propman07

Recommended Posts

Posted

Hello-

 

I'm trying to program a timer to control an exhaust fan. Here's what I would like to do.

 

Between the hours of 1:00 pm and 11:00 pm

turn on exhaust fan

start a 60 minute timer

at the end of the 60 minutes, turn off the exhaust fan

start a 20 minute timer

at the end of the 20 minute timer, turn the exhaust fan on

repeat until 11:00 pm.

 

Here is the program that I have so far.

If
        (
             From     1:00:00PM
             To      11:00:00PM (same day)
        )
 
Then
        Set 'Hardware / POE Fan' On
        Wait  1 hour 
        Set 'Hardware / POE Fan' Off
        Wait  20 minutes 
 
Else
        Set 'Hardware / POE Fan' Off

So the program works correctly, but only one time. I can't figure out how to make it repeat until the end time.

 

Thanks for any assistance.

Posted

Use the Repeat statement.

 

If
(
From 1:00:00PM
To 11:00:00PM (same day)
)

Then

Repeat 9 times
   Set 'Hardware / POE Fan' On
   Wait 1 hour
   Set 'Hardware / POE Fan' Off
   Wait 20 minutes

Else
Set 'Hardware / POE Fan' Off

Guest
This topic is now closed to further replies.

  • Recently Browsing

    • No registered users viewing this page.
  • Who's Online (See full list)

  • Forum Statistics

    • Total Topics
      37k
    • Total Posts
      371.5k
×
×
  • Create New...