Basic Pleg question

So this is probably a super basic question for you but I just can’t figure how to make it work correctly with Pleg… I have a switch that I want to turn on at a specific time… (that part works :slight_smile: ) but I also want it to shutdown 4 hours after… Taking in consideration that the Vera unit might reboot in between for whatever reason… So I created a schedule called “AirExchange_ON” as below with a Offtype Interval of 4 hours :

I also created the condition (not sure to understand it…):

and the following logic action:

Doing so, the switch turns on but not off after 4 hours …
So I guess I’m misunderstanding the “Offtype Interval” …

Should I instead add an interval in the logic action as follow ?

Would that resist a vera reboot and still turn off the switch after the initial 4hour period ?

Thanks :slight_smile:

I always do my OFF delays in the action as you have in your last screen shot.

Yes they should persist after a LUUP engine reload.

thanks for your help :slight_smile: