mcu_ab568x/app/projects/AB5682C_128/functions/common/func_lowpwr.h
2025-05-30 18:03:10 +08:00

24 lines
795 B
C
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#ifndef __LOWPWR_H
#define __LOWPWR_H
typedef bool (*is_sleep_func)(void);
bool sleep_process(is_sleep_func is_sleep);
void lowpwr_tout_ticks(void);
void sfunc_pwrdown(u8 vusb_wakeup_en); //软开关方案POWER键/低电时,进入关机状态
void func_pwroff(int pwroff_tone_en); //进入低电或者关机状态
void sys_enter_sleep(u8 lpclk_type);
void reset_sleep_delay_message_display(void);
/**
* @brief 休眠保持3v3供电不使能低功耗io休眠前调用使用时不应执行power_gate_3v3_off()函数)
注意对包括pwr_gate在内的所有GPIO有效功耗影响较大
* @param[in] on : 是否保持3v3供电默认为false
**/
void sleep_power_gate_keep_open(bool on);
#endif // __FUNC_LOWPWR_H