No announcement yet.

Modulo & cron function

  • Filter
  • Time
  • Show
Clear All
new posts

  • Modulo & cron function

    I'd like to see some easy trigger that do modulo triggers.
    • A modulo timer that triggers when the timer rolls over, i.e., if timer mod 4 then xxx, which would trigger every 4 seconds.
    • A modulo test that can be applied to how long a device has been in a given state, i.e., if light has been on for mod 60 then xxx, which would trigger every 60 seconds.
    • A modulo counter that can be applied to a counter, i.e., if counter mod 25 then xxx, which would trigger every time the counter was incremented 25 times.
    • Lastly if cron mycron12 then xxx, triggers whenever a cron event triggers.

    I realize that cron is much like schedules but it allows for much finer control that I think schedules do at least for repeating events that care based on several time/date combinations. The cron format should exactly follow the unix standard to make it easily documented and implemented.

    I think that modulo is the most important but getting cron would be icing on the cake.

    Now watch, someone going is tell me that this can be done now and I just didn't find the tests.
    John (N6BER), Joyce, Lucas (Golden Ret mix), Bella (Great Pyrenees) and Lance (GP).

    HomeSeer Version: HS3 Standard Edition
    Linux version: Linux auto 4.15.0-43-generic #46-Ubuntu SMP Thu Dec 6 14:45:28 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
    Number of Devices: 347
    Number of Events: 535
    Available Threads: 399
    HSTouch Enabled: True

    Enabled Plug-Ins AirplaySpeak BLBackup EasyTrigger
    1.3.6927.42284: LiftMaster MyQ mcsMQTT PHLocation Pushover 3P Z-Wave