Description
The EventScheduler Module is designed to trigger events at specific times.
Usage
The EventScheduler can be used to create a calendar of times for Actions to be fired, which can then be connected to other Modules to run their functionality. An example could be to change between Timelines during certain times or days, or to trigger a Timeline only on holidays of that year.
Procedure
With the setting "Number of Events" you can specify how many events should be generated.
In the field "Time Format" you can set the scheme according to which the ticker runs.
The actual triggering in the background is done with a string comparison of the time and the event.
Then, generate the desired number once with "createEvents()", here "dynamicRebuildFromDescriptions()" is used thereby the complete Lua code is regenerated.
In the respective events now the time can be entered as string e.g. 15:45:00 The input must correspond to this scheme otherwise the query does not work, the time function checks the value of the events and with agreement the event is called.
It is also possible to enter the event using another Module, but this will not trigger the event, if nothing is sent to the function, the event will be triggered, so you can e.g. create a new function and connect it, by sending nil as default, the event will then be triggered
The code in the Module only makes a string comparison for the different events, so the notation must be observed.
By selecting the time format, this is already displayed in the Action Time, it is important that the string corresponds to this notation.
Typical Workflow
- Enter the number of desired entries.
- Generate entries.
- Enter the time in the respective entry
Examples
In this example, I have set the time format to DayName H:M:S. This means that the event is only triggered on this day at the desired time. I have also set an event time here with a Send Text Module. This also allows events to be set and triggered dynamically. Care has been taken to ensure that setting an event does not trigger the event. To set a time, we simply write the desired time in the Action.
Data
Actions
Action |
Info |
Input |
Output |
---|---|---|---|
ref | - | - | |
init | - | - | |
uninit | - | - | |
convertTime | (hidden) | time (string), format (string) | - |
createEvent | (hidden) | - | - |
deleteEvents | (hidden) | - | - |
debugPrint | (hidden) | - | - |
registerEvent | (hidden) | time (string), ActionName (string), recurrence (string) | - |
Time | val (), doSet (bool) | - | |
Events | FOLDER | FOLDER | FOLDER |
dropdown | (hidden) | - | - |
Parameters
Name |
Content |
Type Hint |
Options Source |
Options Action |
Auto Init | TRUE | bool | [] | |
Event Name | Start | string | [] | |
Time Format | HH:MM:SS | string | self.dropdown | self.init |
Info | Please enter the time in the selected time format. Follow the syntax as displayed in "Time Format". | [] | ||
Event Time | 17:00:00 | string | [] | |
Create | Create | button | self.createEvent | |
Clear All | Clear All | button | self.deleteEvents |
PIXERA 1.9.139 | 22. September 2022 | CL