Read the statement by Michael Teeuw here.
MMM-ModuleScheduler: How to schedule for every other week
-
Re: MMM-ModuleSceduler- How to schedule for every other week
I’ve been using the very handy scheduling module https://github.com/ianperrin/MMM-ModuleScheduler/ successfully to trigger other modules such as displaying fireworks https://github.com/ChrisF1976/MMM-Fireworks/ on anniversaries by sending notifications to the modules. I’d love to set some more complex schedules like bi-weekly, or odd/even weeks. In theory this can be achieved in the linux crontab by sending an expression such as [ $(expr $(date +%W) % 2) -eq 1 ] that is evaluated before the command is sent.
I’ve tried a few different ways to send this but it looks like the node.js cron does not support this. Wondering if anyone has managed to configure such a setup.
{ notification: 'FireFireFire', schedule: '00 18 * * SUN [ $(expr $(date +%W) % 2) -eq 1 ]', payload: {text: "Its been 2 weeks"}}, // start fireworks 2 weeks on Sunday at 1800 { notification: 'StopFire', schedule: '30 19 * * SUN [ $(expr $(date +%W) % 2) -eq 1 ]', payload: {text: "StopFire"}}, // stop fireworks at 1930Thanks in advance.
-
@elentophanes you cant do biweekly ONLY in cron
the launched pgm needs to handle the every other
i did a search
cron biweekly
and there were examples by testing the week number for even/odd and other things (write a file test sbd erase if exists…)the module scheduler module doesn’t support commands as part of the cron definition.
-
E elentophanes has marked this topic as solved on
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login