Repeating issue

Hi,

I’m discovering PLEG, and I want to use it to control the shutters in case of high temperature outside, I have put multiple conditions.
I asked to close the shutter at 20% in the living room, only under the following conditions :

  • Outside temperature >= 25
  • Door of the living room is closed
  • Shutter are over 30% opened
  • Only between 2 and 6pm.

here is the condition : pExTemp >= 25 AND sAfternoon AND pLivingDoorOpen == 0 AND pShutter_position >= 30

It works exactly as expected, however if for any reason I want to open the shutter manually, it remains closed and I have to bypass PLEG…
Question is, how can I tell PLEG to fire only once every 2 hours for example ?

Thanks for your help.

Kris

The simplest way to have your Condition fire periodically is to use an interval timer. Create a Schedule like this:

Timer2H StartType: Interval, 2:00:00, StopType: Interval, 00:01:00

Now just include the timer as an and-ed term in your Condition:

ConditionName pExTemp >= 25 AND sAfternoon AND pLivingDoorOpen == 0 AND pShutter_position >= 30 AND Timer2H

The Condition can only fire when Timer2H is true which is for one minute every two hours.

I’ll try that, thanks for the tip Rex !