FreeRTOS C++ Wrappers
|
Make a class based task. Derive from TaskClass and the 'task()' member function will get called as the task based on the class. More...
#include <TaskCPP.h>
Public Member Functions | |
TaskClass (char const *name, TaskPriority priority, unsigned portSHORT stackDepth) | |
Constructor. More... | |
virtual void | task ()=0 |
task function. The member function task needs to More... | |
Public Member Functions inherited from Task | |
Task (char const *name, void(*taskfun)(void *), TaskPriority priority, unsigned portSHORT stackDepth, void *parm=0) | |
Constructor. More... | |
virtual | ~Task () |
Destructor. More... | |
Additional Inherited Members | |
Public Attributes inherited from Task | |
TaskHandle_t | handle |
Handle for the task we are managing. More... | |
Make a class based task. Derive from TaskClass and the 'task()' member function will get called as the task based on the class.
If task() returns the task will be deleted if deletion has been enabled.
|
inline |
Constructor.
name | The name of the task. |
priority | The priority of the task. Use the TaskPriority enum values or a related value converted to a TaskPriority |
stackDepth | Size of the stack to give to the task |
Note: At construction time the task will be created, so if the the scheduler has been started, the created task needs to have a priority less than the creating task so it can't start until after the class deriving from TaskClass has finished it constructor (or other measures need to have been taken to make sure this happens, like stopping the scheduler).
|
pure virtual |
task function. The member function task needs to