Particular month schedule trigger

How can I add a month condition to a scene?
For example, turn on light only in July and September of every year.

Thank you,

The rapid way is some lua code, added into “also run this lua code”. The code should return true if the scene has to be run, so it’s basically stopping or allowing the scene after the triggers are fired.

In your case, this is the code:

local currentTime ="*t")
return currentTime.month >=7 and currentTime.month <=9 -- summer only

Change your code accordingly.


Other options are PLEG and Reactor. I have a wall outlet that is controlled from mid-November to mid-January. I plug my Christmas Tree into it. It turns off the outlet in any mode but Home. I first set this up in PLEG a few years ago, and migrated the logic to Reactor late last year.

1 Like

Thank you very much therealdb.
It works great !!!


Best Home Automation shopping experience. Shop at getvera!

© 2020 Vera Control Ltd., All Rights Reserved. Terms of Use | Privacy Policy | Forum Rules