Common IO - basic v1.0.0
Common IO - basic v1.0.0 Library
 
Loading...
Searching...
No Matches
iot_reset.h File Reference

This file contains all the Reset HAL API definitions. More...

#include <stdint.h>

Go to the source code of this file.

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 for the reason of the last reset More...
 
enum  IotResetBootFlag_t { eResetWarmBootFlag , eResetColdBootFlag }
 enum for the type of reset to perform More...
 

Functions

void iot_reset_reboot (IotResetBootFlag_t xResetBootFlag)
 iot_reset_reboot is used to reboot the device.
 
int32_t iot_reset_shutdown (void)
 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.
 

Detailed Description

This file contains all the Reset HAL API definitions.