![]() |
PDK Documentation
|
Task module for the RTOS Porting Interface.
============================================================================
Go to the source code of this file.
Data Structures | |
| struct | TaskP_Params |
| Basic SemaphoreP Parameters. More... | |
Macros | |
| #define | OS_TICKS_IN_MILLI_SEC 1 /* 1000us tick */ |
| Number Ticks by OS in 1 millisecond. More... | |
Typedefs | |
| typedef void * | TaskP_Handle |
| Opaque client reference to an instance of a TaskP. More... | |
Enumerations | |
| enum | TaskP_Status { TaskP_OK = 0, TaskP_FAILURE = (-(int32_t)1) } |
| Status codes for TaskP APIs. More... | |
Functions | |
| TaskP_Handle | TaskP_create (void *taskfxn, const TaskP_Params *params) |
| Function to create a task. More... | |
| TaskP_Status | TaskP_delete (TaskP_Handle *handle) |
| Function to delete a task. More... | |
| void | TaskP_Params_init (TaskP_Params *params) |
| Initialize params structure to default values. More... | |
| void | TaskP_sleep (uint32_t timeout) |
| Function for Task sleep in units of OS tick. More... | |
| void | TaskP_sleepInMsecs (uint32_t timeoutInMsecs) |
| Function for Task sleep in units of msecs. More... | |
| void | TaskP_setPrio (TaskP_Handle handle, uint32_t priority) |
| Function for Task sleep. More... | |
| TaskP_Handle | TaskP_self (void) |
| Function returns the Task handle of current task. More... | |
| TaskP_Handle | TaskP_selfmacro (void) |
| Function returns the Task handle of current task.This is an inline function. More... | |
| void | TaskP_yield (void) |
| Function Yield processor to equal priority task. More... | |
| uint32_t | TaskP_isTerminated (TaskP_Handle handle) |
| Check if task is terminated. More... | |
| #define OS_TICKS_IN_MILLI_SEC 1 /* 1000us tick */ |
Number Ticks by OS in 1 millisecond.
| typedef void* TaskP_Handle |
Opaque client reference to an instance of a TaskP.
A TaskP_Handle returned from the TaskP_create represents that instance and is used in the other instance based functions
| enum TaskP_Status |
| TaskP_Handle TaskP_create | ( | void * | taskfxn, |
| const TaskP_Params * | params | ||
| ) |
Function to create a task.
| taskfxn | Function pointer of the task. |
| params | Pointer to the instance configuration parameters. |
| TaskP_Status TaskP_delete | ( | TaskP_Handle * | handle | ) |
Function to delete a task.
| handle | A TaskP_Handle returned from TaskP_create |
| void TaskP_Params_init | ( | TaskP_Params * | params | ) |
Initialize params structure to default values.
| params | Pointer to the instance configuration parameters. |
| void TaskP_sleep | ( | uint32_t | timeout | ) |
Function for Task sleep in units of OS tick.
| timeout | sleep ticks. |
| void TaskP_sleepInMsecs | ( | uint32_t | timeoutInMsecs | ) |
Function for Task sleep in units of msecs.
| timeoutInMsecs | sleep in units of msecs. |
| void TaskP_setPrio | ( | TaskP_Handle | handle, |
| uint32_t | priority | ||
| ) |
Function for Task sleep.
| handle | A TaskP_Handle returned from TaskP_create. |
| priority | New priority to be set. |
| TaskP_Handle TaskP_self | ( | void | ) |
Function returns the Task handle of current task.
| TaskP_Handle TaskP_selfmacro | ( | void | ) |
Function returns the Task handle of current task.This is an inline function.
| void TaskP_yield | ( | void | ) |
Function Yield processor to equal priority task.
| uint32_t TaskP_isTerminated | ( | TaskP_Handle | handle | ) |
Check if task is terminated.
Typically a task MUST be terminated before it can be deleted.