esp32/rtc: fix xtal unstable in some cases when sleep

1. add xtal buf wait to fix high temperature restart issue
2. add min sleep value to fix xtal stop due to too short sleep time issue
This commit is contained in:
jingli
2022-10-09 14:53:59 +08:00
parent 0fa55c897f
commit 0a44d09f4f
17 changed files with 36 additions and 29 deletions

View File

@@ -97,6 +97,7 @@ extern "C" {
#define RTC_CNTL_XTL_BUF_WAIT_SLP_US (1000)
#define RTC_CNTL_CK8M_WAIT_SLP_CYCLES (4)
#define RTC_CNTL_WAKEUP_DELAY_CYCLES (4)
#define RTC_CNTL_MIN_SLP_VAL_MIN (2)
#define RTC_CNTL_CK8M_DFREQ_DEFAULT 172
#define RTC_CNTL_SCK_DCAP_DEFAULT 255