/** | |
* @brief Modem wakeup callback | |
* @param [in]int32_t wakeup_in | |
* @retval void | |
*/ | |
/* 0 -- Falling, Means wakeupin falling to wakeup the module, or wakeupout falling to wakeup mcu. */ | |
/* 1 -- Rising, Means wakeupin rising to wakeup the module, or wakeupout rising to wakeup mcu. */ | |
typedef void (*GSW_PM_WAKEUPCALLBACK)(int32_t wakeup_in); | |
/** | |
* @brief Enable autosleep | |
* @param void | |
* @retval GSW_HAL_SUCCESS\GSW_HAL_FAIL | |
*/ | |
int32_t gsw_autosleep_enable(void); | |
/** | |
* @brief Disable autosleep | |
* @param void | |
* @retval GSW_HAL_SUCCESS\GSW_HAL_FAIL | |
*/ | |
int32_t gsw_autosleep_disenable(void); | |
/** | |
* @brief Init power manager module | |
* @param [in]GSW_PM_WAKEUPCALLBACKHandler wakeup_callback | |
* @retval GSW_HAL_SUCCESS\GSW_HAL_FAIL | |
*/ | |
int32_t gsw_pm_sdk_init(GSW_PM_WAKEUPCALLBACK wakeup_callback); | |
/** | |
* @brief Release wake lock, enter sleep | |
* @param [in]int32_t wakeup_in | |
* @retval int | |
*/ | |
int32_t gsw_pm_enter_sleep(const char *gsw_wakelock_name); | |
/** | |
* @brief Creat wakeup lock | |
* @param [in]int32_t wakeup_in | |
* @retval int | |
*/ | |
int32_t gsw_pm_exit_sleep(const char *gsw_wakelock_name); | |
/** | |
* @brief Module log disk drop, used when restarting or hibernating | |
* @param [in]void | |
* @retval void | |
*/ | |
void gsw_modem_log_sync(void); |