|
LibJuno 1.0.1
LibJuno is a lightweight C11 library designed specifically for embedded systems.
|
#include "juno/macros.h"#include "juno/module.h"#include "juno/sm/sm_api.h"#include "juno/status.h"#include "unistd.h"#include <stdio.h>
Typedefs | |
| typedef enum TRAFFIC_LIGHT_T | TRAFFIC_LIGHT_T |
Enumerations | |
| enum | TRAFFIC_LIGHT_T { TRAFFIC_RED , TRAFFIC_YELLOW , TRAFFIC_GREEN , TRAFFIC_COUNT } |
Functions | |
| struct TRAFFIC_LIGHT_STATE_T | JUNO_MODULE_DERIVE (union JUNO_SM_STATE_T JUNO_MODULE(JUNO_SM_STATE_ROOT_T, int iCounter;TRAFFIC_LIGHT_T tNextLight;TRAFFIC_LIGHT_T tThisLight;) |
| The action that should be executed in this state. | |
| static JUNO_RESULT_BOOL_T | ShouldExit (JUNO_SM_STATE_ROOT_T *ptJunoSm) |
| Returns a bool result whether the current state should exit. | |
| static JUNO_STATUS_T | ResetState (JUNO_SM_STATE_ROOT_T *ptJunoSm) |
| struct TRAFFIC_LIGHT_SM_T | JUNO_MODULE_DERIVE (union JUNO_SM_T JUNO_MODULE(JUNO_SM_ROOT_T, TRAFFIC_LIGHT_STATE_T tStates;[TRAFFIC_COUNT]) |
| int | main (void) |
Variables | |
| static const JUNO_SM_STATE_API_T | tSmStateApi |
| typedef enum TRAFFIC_LIGHT_T TRAFFIC_LIGHT_T |
| enum TRAFFIC_LIGHT_T |
| struct TRAFFIC_LIGHT_STATE_T JUNO_MODULE_DERIVE | ( | union JUNO_SM_STATE_T JUNO_MODULE( | JUNO_SM_STATE_ROOT_T, |
| int iCounter;TRAFFIC_LIGHT_T tNextLight;TRAFFIC_LIGHT_T tThisLight; | |||
| ) |
The action that should be executed in this state.
| struct TRAFFIC_LIGHT_SM_T JUNO_MODULE_DERIVE | ( | union JUNO_SM_T JUNO_MODULE( | JUNO_SM_ROOT_T, |
| TRAFFIC_LIGHT_STATE_T tStates; | [TRAFFIC_COUNT] | ||
| ) |
| int main | ( | void | ) |
|
static |
|
static |
Returns a bool result whether the current state should exit.
|
static |