RKH
|
Related to underlying OS/RTOS. More...
Functions | |
void | rkh_sma_activate (RKH_SMA_T *me, const RKH_EVT_T **qSto, RKH_QUENE_T qSize, void *stkSto, rui32_t stkSize) |
Initializes and activates a previously created state machine application (SMA) as known as active object. More... | |
void | rkh_sma_terminate (RKH_SMA_T *me) |
Terminate a state machine application (SMA) as known as active object. More... | |
void | rkh_sma_post_fifo (RKH_SMA_T *me, const RKH_EVT_T *e, const void *const sender) |
Send an event to a state machine application (SMA) as known as active object through a queue using the FIFO policy. A message is a pointer size variable and its use is application specific. More... | |
void | rkh_sma_post_lifo (RKH_SMA_T *me, const RKH_EVT_T *e, const void *const sender) |
Send an event to a state machine application (SMA) as known as active object through a queue using the LIFO policy. A message is a pointer size variable and its use is application specific. More... | |
RKH_EVT_T * | rkh_sma_get (RKH_SMA_T *me) |
Get an event from the event queue of an state machine application (SMA) as known as active object. The events received are pointer size variables and their use is application specific. More... | |
Related to underlying OS/RTOS.
void rkh_sma_activate | ( | RKH_SMA_T * | me, |
const RKH_EVT_T ** | qSto, | ||
RKH_QUENE_T | qSize, | ||
void * | stkSto, | ||
rui32_t | stkSize | ||
) |
Initializes and activates a previously created state machine application (SMA) as known as active object.
A state machine application (SMA) is declared with the RKH_SMA_T data type and is defined with the rkh_sma_activate() service.
[in] | me | pointer to previously created state machine application. |
[in] | qSto | base address of the event storage area. A message storage area is declared as an array of pointers to RKH events. |
[in] | qSize | size of the storage event area [in number of entries]. |
[in] | stkSto | starting address of the stack's memory area. |
[in] | stkSize | size of stack memory area [in bytes]. |
void rkh_sma_terminate | ( | RKH_SMA_T * | me | ) |
Terminate a state machine application (SMA) as known as active object.
A state machine application may call this service to terminate itself. Once terminated, the state machine application must be re-created in order for it to execute again.
[in] | me | pointer to previously created state machine application. |
Send an event to a state machine application (SMA) as known as active object through a queue using the FIFO policy. A message is a pointer size variable and its use is application specific.
[in] | me | pointer to previously created state machine application. |
[in] | e | actual event sent to the state machine application. |
[in] | sender | pointer to the sender object. It is not necessarily a pointer to an active object. In fact, if RKH_SMA_POST_FIFO() is called from an interrupt or other context, it can create a unique object just to unambiguously identify the publisher of the event. |
Send an event to a state machine application (SMA) as known as active object through a queue using the LIFO policy. A message is a pointer size variable and its use is application specific.
[in] | me | pointer to previously created state machine application. |
[in] | e | actual event sent to the state machine application. |
[in] | sender | pointer to the sender object. It is not necessarily a pointer to an active object. In fact, if RKH_SMA_POST_FIFO() is called from an interrupt or other context, it can create a unique object just to unambiguously identify the publisher of the event. |
Get an event from the event queue of an state machine application (SMA) as known as active object. The events received are pointer size variables and their use is application specific.
[in] | me | pointer to previously created state machine application. |