FreeRTOS:
Common I/O
AWS IoT Common I/O library
|
Return to main page ↑ |
Macros | |
#define | IOT_RESET_SUCCESS ( 0 ) |
#define | IOT_RESET_FUNCTION_NOT_SUPPORTED ( 1 ) |
#define | IOT_RESET_INVALID_VALUE ( 2 ) |
Enumerations | |
enum | IotResetReason_t { eResetPowerOnBoot, eResetWarmBoot, eResetColdBoot, eResetWatchdog, eResetBusTimeout, eResetPmic, eResetBrownOut, eResetOther } |
enum | IotResetBootFlag_t { eResetWarmBootFlag, eResetColdBootFlag } |
Functions | |
void | iot_reset_reboot (IotResetBootFlag_t xResetBootFlag) |
iot_reset_reboot is used to reboot the device. More... | |
int32_t | iot_reset_shutdown () |
iot_reset_shutdown is used to shutdown the device. If the target does not support shutdown of the device, IOT_RESET_FUNCTION_NOT_SUPPORTED is returned to the user. More... | |
int32_t | iot_get_reset_reason (IotResetReason_t *xResetReason) |
iot_get_reset_reason is used to get the last reset reason. If the underlying HW does not support the feature of persisting the reset reason, then this API will return IOT_RESET_FUNCTION_NOT_SUPPORTED error with the value in out as don't care. More... | |
#define IOT_RESET_SUCCESS ( 0 ) |
Return values used by reset driverReset operation completed successfully.
#define IOT_RESET_FUNCTION_NOT_SUPPORTED ( 1 ) |
Reset function not supported.
#define IOT_RESET_INVALID_VALUE ( 2 ) |
At least one parameter is invalid.
enum IotResetReason_t |
enum IotResetBootFlag_t |
void iot_reset_reboot | ( | IotResetBootFlag_t | xResetBootFlag | ) |
iot_reset_reboot is used to reboot the device.
[in] | xResetBootFlag | flag to determine either to do cold-reset or warm-reset. cold-reset means the device is restarted and does not keep any blocks of the SOC powered on i.e. device is shutdown and rebooted), and warm-reset means the device is restarted while keeping some of the SoC blocks powered on through the reboot process. For example warm-boot may keep the RAM contents valid after reset by keeping the power on for RAM banks, while cold-boot will wipe off the contents. One of the IotResetBootFlag_t value. |
int32_t iot_reset_shutdown | ( | ) |
iot_reset_shutdown is used to shutdown the device. If the target does not support shutdown of the device, IOT_RESET_FUNCTION_NOT_SUPPORTED is returned to the user.
int32_t iot_get_reset_reason | ( | IotResetReason_t * | xResetReason | ) |
iot_get_reset_reason is used to get the last reset reason. If the underlying HW does not support the feature of persisting the reset reason, then this API will return IOT_RESET_FUNCTION_NOT_SUPPORTED error with the value in out as don't care.
[out] | xResetReason | One of the reset reasons specified in IotResetReason_t types |