![]() |
FuSa 8-Bit Libraries Safety Framework
|
Contains API prototype for the Scheduler Task Manager. More...
Files | |
| file | task_manager_scheduler.c |
| Implements API for the Scheduler Task Manager. | |
Functions | |
| void | TM_Scheduler (const scheduleEntry_t schedule[], uint8_t scheduleLength, uint32_t nextScheduleDeadline) |
| Manages and synchronizes safety system and application Tasks from a user defined schedule. | |
Contains API prototype for the Scheduler Task Manager.
The Scheduler Task Manager is responsible for running both safety system and application specific Tasks when the device is initialized and has exited the Safe State.
| void TM_Scheduler | ( | const scheduleEntry_t | schedule[], |
| uint8_t | scheduleLength, | ||
| uint32_t | nextScheduleDeadline ) |
Manages and synchronizes safety system and application Tasks from a user defined schedule.
This function executes safety system and application-specific scheduler Tasks with fixed durations, while ensuring the FDTI of the system.
After clearing the Watchdog Timer, all Tasks in the schedule are executed in sequence. Once the Task manager has handled the last Task in the schedule, the Synchronous Watchdog Timer is cleared and sets a deadline for when the first task in the next schedule should run Tasks.
| schedule | Array of schedule entries with a Task function pointer and duration in system clock cycles. Any Task set to a NULL pointer is skipped. Duration is limited to a 24-bit value. |
| scheduleLength | Number of entries in schedule. A value of '0' indicates an empty schedule and no application Tasks will run. |
| nextScheduleDeadline | Duration in system clock cycles for the time between completion of the last Task in the current schedule to calling the first Task in the next schedule. |
Definition at line 33 of file task_manager_scheduler.c.