FreeRTOS C++ Wrappers
Public Member Functions | List of all members
TaskClass Class Referenceabstract

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>

Inheritance diagram for TaskClass:
Inheritance graph
Collaboration diagram for TaskClass:
Collaboration graph

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...
 

Detailed Description

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.

Constructor & Destructor Documentation

TaskClass::TaskClass ( char const *  name,
TaskPriority  priority,
unsigned portSHORT  stackDepth 
)
inline

Constructor.

Parameters
nameThe name of the task.
priorityThe priority of the task. Use the TaskPriority enum values or a related value converted to a TaskPriority
stackDepthSize 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).

Member Function Documentation

virtual void TaskClass::task ( )
pure virtual

task function. The member function task needs to


The documentation for this class was generated from the following file: