FreeRTOScpp
|
Lowest Level Wrapper. More...
#include <TaskCPP.h>
Public Member Functions | |
TaskBase (TaskHandle_t handle) | |
Constructor. More... | |
virtual | ~TaskBase () |
Destructor. More... | |
TaskHandle_t | getTaskHandle () const |
Get Task Handle. More... | |
bool | give () |
Notify a Task as a semaphore. More... | |
void | give_ISR (portBASE_TYPE &waswoken) |
bool | notify (uint32_t value, eNotifyAction act) |
Notify a Task. More... | |
bool | notify_ISR (uint32_t value, eNotifyAction act, portBASE_TYPE &waswoken) |
bool | notify_query (uint32_t value, eNotifyAction act, uint32_t &old) |
bool | notify_query_ISR (uint32_t value, eNotifyAction act, uint32_t &old, portBASE_TYPE &waswoken) |
void | priority (TaskPriority priority_) |
Set Task priority. More... | |
void | resume () |
Resume the Task. More... | |
void | suspend () |
Suspend the Task. More... | |
Static Public Member Functions | |
static void | delay (TickType_t time) |
Delay for a period of time. More... | |
static void | delay (Time_ms ms) |
Delay for a period of time, specified in milliseconds. More... | |
static uint32_t | take (bool clear=true, TickType_t ticks=portMAX_DELAY) |
Wait for a task Give notification. More... | |
static uint32_t | take (bool clear, Time_ms ticks) |
Wait for a task Give notification. More... | |
static uint32_t | wait (uint32_t clearEnter, uint32_t clearExit=0xFFFFFFFF, uint32_t *value=nullptr, TickType_t ticks=portMAX_DELAY) |
Wait for task notification. More... | |
static uint32_t | wait (uint32_t clearEnter, uint32_t clearExit, uint32_t *value, Time_ms ms) |
static uint32_t | waitIndex (UBaseType_t idx, uint32_t clearEnter, uint32_t clearExit=0xFFFFFFFF, uint32_t *value=nullptr, TickType_t ticks=portMAX_DELAY) |
static uint32_t | waitIndex (UBaseType_t idx, uint32_t clearEnter, uint32_t clearExit, uint32_t *value, Time_ms ms) |
Protected Member Functions | |
TaskBase () | |
Default Constructor: Needs a subclass to fill in the handle later, so protected. More... | |
Protected Attributes | |
TaskHandle_t | taskHandle |
Handle for the task we are managing. More... | |
Private Member Functions | |
TaskBase (TaskBase const &)=delete | |
We are not copyable. More... | |
void | operator= (TaskBase const &)=delete |
We are not assignable. More... | |
Lowest Level Wrapper.
Create the specified task with a provided task function.
If the TaskBase object is destroyed, the FreeRTOS Task will be deleted (if deletion has been enabled)
|
inlineprotected |
Default Constructor: Needs a subclass to fill in the handle later, so protected.
Referenced by FreeRTOScpp::TaskS< stackDepth >::TaskS().
|
inline |
Constructor.
|
inlinevirtual |
|
privatedelete |
We are not copyable.
|
inlinestatic |
Delay for a period of time.
time | the number of ticks to delay |
This is a static member function as it affects the CALLING task, not the task it might be called on
|
inlinestatic |
Delay for a period of time, specified in milliseconds.
ms | The number of milliseconds to delay |
This is a static member function as it affects the CALLING task, not the task it might be called on
References FreeRTOScpp::ms2ticks(), priority(), and taskHandle.
|
inline |
|
inline |
Notify a Task as a semaphore.
Sends a notification to a task using a semaphore based protocol. Generally the task should we using the take() function to receive the notification.
References taskHandle.
Referenced by FreeRTOScpp::TaskClassS< stackDepth >::TaskClassS(), and FreeRTOScpp::TaskClassS< stackDepth >::~TaskClassS().
|
inline |
References taskHandle.
|
inline |
|
inline |
References taskHandle.
|
inline |
References taskHandle.
|
inline |
References taskHandle.
|
privatedelete |
We are not assignable.
|
inline |
Set Task priority.
Only available if INCLUDE_vTaskPrioritySet == 1
priority_ | The TaskPriority to give the Task. |
References taskHandle.
Referenced by delay().
|
inline |
|
inline |
|
inlinestatic |
Wait for a task Give notification.
Specialized wait() designed to work with the give()/give_ISR() notifications.
clear | Flag to indicate if the action on succesful take is to clear (True) or decrement (False) the notification value. Effectively decides between a binary (True) or counting (False) semaphore behavior. |
ticks | The time to wait for the semaphore. |
Referenced by taskcpp_task_thunk().
|
inlinestatic |
Wait for a task Give notification.
Specialized wait() designed to work with the give()/give_ISR() notifications.
clear | Flag to indicate if the action on successful take is to clear (True) or decrement (False) the notification value. Effectively decides between a binary (True) or counting (False) semaphore behavior. |
ticks | The time to wait for the semaphore. |
References FreeRTOScpp::ms2ticks().
|
inlinestatic |
Wait for task notification.
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
protected |
Handle for the task we are managing.
Referenced by delay(), getTaskHandle(), give(), give_ISR(), notify(), notify_ISR(), notify_query(), notify_query_ISR(), priority(), resume(), suspend(), FreeRTOScpp::TaskS< stackDepth >::TaskS(), and ~TaskBase().