37 #define WSF_OS_DIAG FALSE 45 #define WSF_TASK_FROM_ID(handlerID) (((handlerID) >> 4) & 0x0F) 48 #define WSF_HANDLER_FROM_ID(handlerID) ((handlerID) & 0x0F) 51 #define WSF_INVALID_TASK_ID 0xFF 54 #if WSF_OS_DIAG == TRUE 55 #define WSF_OS_GET_ACTIVE_HANDLER_ID() WsfActiveHandler 57 #define WSF_OS_GET_ACTIVE_HANDLER_ID() WSF_INVALID_TASK_ID 64 #define WSF_MSG_QUEUE_EVENT 0x01 65 #define WSF_TIMER_EVENT 0x02 66 #define WSF_HANDLER_EVENT 0x04 134 void WsfSetEvent(wsfHandlerId_t handlerId, wsfEventMask_t event);
uint8_t wsfEventMask_t
Event handler event mask data type.
void WsfSetEvent(wsfHandlerId_t handlerId, wsfEventMask_t event)
Set an event for an event handler.
uint8_t wsfTaskEvent_t
Task event mask data type.
uint8_t bool_t
Boolean data type.
uint8_t event
General purpose event value passed to event handler.
void WsfTaskUnlock(void)
Unlock task scheduling.
bool_t wsfOsReadyToSleep(void)
Check if WSF is ready to sleep.
wsfQueue_t * WsfTaskMsgQueue(wsfHandlerId_t handlerId)
Return the task message queue used by the given handler.
uint16_t param
General purpose parameter passed to event handler.
void WsfOsShutdown(void)
Shutdown OS.
void(* wsfEventHandler_t)(wsfEventMask_t event, wsfMsgHdr_t *pMsg)
Event handler callback function.
void WsfTaskSetReady(wsfHandlerId_t handlerId, wsfTaskEvent_t event)
Set the task used by the given handler as ready to run.
uint8_t wsfHandlerId_t
Event handler ID data type.
uint8_t status
General purpose status value passed to event handler.
void wsfOsDispatcher(void)
Event dispatched. Designed to be called repeatedly from infinite loop.
void WsfTaskLock(void)
Lock task scheduling.
unsigned short uint16_t
Unsigned 16-bit value.
wsfHandlerId_t WsfOsSetNextHandler(wsfEventHandler_t handler)
Set the next WSF handler function in the WSF OS handler array. This function should only be called as...
General purpose queue service.
wsfHandlerId_t wsfTaskId_t
Task ID data type.
wsfHandlerId_t WsfActiveHandler
Diagnostic Task Identifier.
Common message structure passed to event handler.
unsigned char uint8_t
Unsigned 8-bit value.