Trident IoT Z-Wave SDK
 
Loading...
Searching...
No Matches
ZW_UserTask.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Silicon Laboratories Inc. <https://www.silabs.com/>
2//
3// SPDX-License-Identifier: BSD-3-Clause
4
18#ifndef _USER_TASK_API_H_
19#define _USER_TASK_API_H_
20
21#include <ZW_typedefs.h>
23
40typedef struct {
41 StaticTask_t* taskBuffer;
42 uint8_t* stackBuffer;
45
51
59
81
89
98
120 uint8_t iZwRxQueueTaskNotificationBitNumber,
121 uint8_t iZwCommandStatusQueueTaskNotificationBitNumber,
122 const SProtocolConfig_t * pProtocolConfig);
123
129#endif // _USER_TASK_API_H_
ReturnCode_t ZW_UserTask_CreateTask(ZW_UserTask_t *task, TaskHandle_t *xHandle)
Used to create user application level tasks.
bool ZW_UserTask_ApplicationRegisterTask(void(*appTaskFunc)(SApplicationHandles *), uint8_t iZwRxQueueTaskNotificationBitNumber, uint8_t iZwCommandStatusQueueTaskNotificationBitNumber, const SProtocolConfig_t *pProtocolConfig)
Used to create the main application task at highest UserTask priority.
ReturnCode_t ZW_UserTask_Init(void)
Initializes this module.
ZW_UserTask_Priority_t
Definition ZW_UserTask.h:46
ReturnCode_t
Definition ZW_UserTask.h:64
@ USERTASK_PRIORITY_HIGHEST
High priority UserTask. Good for handling interrupts requests.
Definition ZW_UserTask.h:49
@ USERTASK_PRIORITY_NORMAL
The default 'APP'-task priority.
Definition ZW_UserTask.h:48
@ USERTASK_PRIORITY_BACKGROUND
Right above idle priority. Good for HMI and worker threads.
Definition ZW_UserTask.h:47
@ Code_Fail_Timeout
Failed due to timeout.
Definition ZW_UserTask.h:76
@ Code_Fail_Busy
A resource needed by this operation or call is busy. Try again later. Potential racing condition or u...
Definition ZW_UserTask.h:75
@ Code_Fail_InvalidParameter
Wrong/invalid input parameters.
Definition ZW_UserTask.h:73
@ Code_Fail_InvalidOperation
This operation can not be allowed at this point.
Definition ZW_UserTask.h:72
@ Code_Fail_Unknown
Default failed code with no helping indication.
Definition ZW_UserTask.h:66
@ Code_Fail_LimitReached
A set limit is reached for this operation.
Definition ZW_UserTask.h:68
@ Code_Fail_NotAllowed
This operation cannot be performed, since it is blocked or not allowed.
Definition ZW_UserTask.h:79
@ Code_Fail_Driver
Error occurred at the driver level.
Definition ZW_UserTask.h:77
@ Code_Fail_Suspended
The operation or the entire module is globally suspended and cannot be utilized at this point in time...
Definition ZW_UserTask.h:70
@ Code_Success
Success.
Definition ZW_UserTask.h:65
@ Code_DependencyUnavailable
A required resource or dependency that this operation relies on was not setup or available....
Definition ZW_UserTask.h:74
@ Code_Fail_InvalidState
Not in an appropriate state for this call.
Definition ZW_UserTask.h:71
@ Code_Fail_NoMemory
Failed due to lack of memory.
Definition ZW_UserTask.h:67
@ Code_Fail_NotFound
A specific entity could not be found.
Definition ZW_UserTask.h:69
@ Code_Fail_NotImplemented
This operation is not supported due to limited implementation or need.
Definition ZW_UserTask.h:78
#define VOID_CALLBACKFUNC(completedFunc)
Definition ZW_typedefs.h:46
Definition ZW_application_transport_interface.h:1576
Definition ZW_application_transport_interface.h:1644
A buffer structure to allocate the needed memory for a task in user space.
Definition ZW_UserTask.h:40
StaticTask_t * taskBuffer
Memory needed by the Task for internal states. Pointer to buffer.
Definition ZW_UserTask.h:41
uint8_t * stackBuffer
Pointer to a statically allocated stack-buffer-array for the task. Pointer to buffer.
Definition ZW_UserTask.h:42
uint16_t stackBufferLength
This is measured in bytes and is preferably a multiple of 4, or it will be rounded down.
Definition ZW_UserTask.h:43
Definition ZW_UserTask.h:52
char * pTaskName
The name of the task. (Max characters = configMAX_TASK_NAME_LEN). NULL allowed.
Definition ZW_UserTask.h:54
void * pUserTaskParam
Any parameter variable of own choice that is casted as (void*). Can be NULL.
Definition ZW_UserTask.h:55
ZW_UserTask_Buffer_t * taskBuffer
The buffer collection for the task.
Definition ZW_UserTask.h:57
TaskFunction_t pTaskFunc
The function of the task (Invalid parameter if NULL)
Definition ZW_UserTask.h:53
ZW_UserTask_Priority_t priority
The desired priority of the task.
Definition ZW_UserTask.h:56