Revision 9ebb11a9 core/inc/aos_system.h
| core/inc/aos_system.h | ||
|---|---|---|
| 65 | 65 |
#define AOS_SYSTEM_EVENTFLAGS_RESTART (AOS_SYSTEM_EVENTFLAGS_SHUTDOWN | (eventflags_t)(1 << 4)) |
| 66 | 66 |
|
| 67 | 67 |
/** |
| 68 |
* @brief Enumerator to identify shutdown types. |
|
| 69 |
*/ |
|
| 70 |
typedef enum aos_shutdown {
|
|
| 71 |
AOS_SHUTDOWN_NONE, /**< Default value if no shutdown action was initiated */ |
|
| 72 |
AOS_SHUTDOWN_PASSIVE, /**< Passive shutdown (initiated by another module). */ |
|
| 73 |
AOS_SHUTDOWN_HIBERNATE, /**< Active shutdown to hibernate mode. */ |
|
| 74 |
AOS_SHUTDOWN_DEEPSLEEP, /**< Active shutdown to deepsleep mode. */ |
|
| 75 |
AOS_SHUTDOWN_TRANSPORTATION, /**< Active shutdown to transportation mode. */ |
|
| 76 |
AOS_SHUTDOWN_RESTART, /**< Active saystem restart request. */ |
|
| 77 |
} aos_shutdown_t; |
|
| 78 |
|
|
| 79 |
#if (AMIROOS_CFG_SSSP_ENABLE == true) || defined(__DOXYGEN__) |
|
| 80 |
|
|
| 81 |
/** |
|
| 68 | 82 |
* @brief Major version of the implemented SSSP. |
| 69 | 83 |
*/ |
| 70 | 84 |
#define AOS_SYSTEM_SSSP_VERSION_MAJOR 1 |
| ... | ... | |
| 81 | 95 |
#define AOS_SYSTEM_SSSP_TIMEOUT (10 * AMIROOS_CFG_SSSP_SIGNALDELAY) |
| 82 | 96 |
|
| 83 | 97 |
/** |
| 84 |
* @brief Enumerator to identify shutdown types. |
|
| 85 |
*/ |
|
| 86 |
typedef enum aos_shutdown {
|
|
| 87 |
AOS_SHUTDOWN_NONE, /**< Default value if no shutdown action was initiated */ |
|
| 88 |
AOS_SHUTDOWN_PASSIVE, /**< Passive shutdown (initiated by another module). */ |
|
| 89 |
AOS_SHUTDOWN_HIBERNATE, /**< Active shutdown to hibernate mode. */ |
|
| 90 |
AOS_SHUTDOWN_DEEPSLEEP, /**< Active shutdown to deepsleep mode. */ |
|
| 91 |
AOS_SHUTDOWN_TRANSPORTATION, /**< Active shutdown to transportation mode. */ |
|
| 92 |
AOS_SHUTDOWN_RESTART, /**< Active saystem restart request. */ |
|
| 93 |
} aos_shutdown_t; |
|
| 94 |
|
|
| 95 |
/** |
|
| 96 | 98 |
* @brief Enumerator of the several stages of SSSP. |
| 97 | 99 |
*/ |
| 98 | 100 |
typedef enum aos_ssspstage {
|
| ... | ... | |
| 119 | 121 |
*/ |
| 120 | 122 |
typedef uint16_t aos_ssspmoduleid_t; |
| 121 | 123 |
|
| 124 |
#endif /* AMIROOS_CFG_SSSP_ENABLE == true */ |
|
| 125 |
|
|
| 122 | 126 |
/** |
| 123 | 127 |
* @brief AMiRo-OS base system structure. |
| 124 | 128 |
*/ |
| 125 | 129 |
typedef struct aos_system {
|
| 126 |
|
|
| 130 |
#if (AMIROOS_CFG_SSSP_ENABLE == true) || defined(__DOXYGEN__) |
|
| 127 | 131 |
/** |
| 128 | 132 |
* @brief SSSP relevant data. |
| 129 | 133 |
*/ |
| ... | ... | |
| 140 | 144 |
*/ |
| 141 | 145 |
aos_ssspmoduleid_t moduleId; |
| 142 | 146 |
} sssp; |
| 147 |
#endif /* AMIROOS_CFG_SSSP_ENABLE == true */ |
|
| 143 | 148 |
|
| 144 | 149 |
/** |
| 145 | 150 |
* @brief System I/O stream. |
| ... | ... | |
| 192 | 197 |
void aosSysInit(void); |
| 193 | 198 |
#endif |
| 194 | 199 |
void aosSysStart(void); |
| 200 |
#if (AMIROOS_CFG_SSSP_ENABLE == true) || defined (__DOXYGEN__) |
|
| 195 | 201 |
eventmask_t aosSysSsspStartupOsInitSyncCheck(event_listener_t* syncEvtListener); |
| 202 |
#endif |
|
| 196 | 203 |
void aosSysGetUptimeX(aos_timestamp_t* ut); |
| 197 | 204 |
void aosSysGetDateTime(struct tm* dt); |
| 198 | 205 |
void aosSysSetDateTime(struct tm* dt); |
Also available in: Unified diff