text
stringlengths
1
9.98k
__index_level_0__
int64
0
4.17k
< Power down Internal 8M oscillator uint32_t deep_slp : 1; //!< power down digital domain uint32_t wdt_flashboot_mod_en : 1; //!< enable WDT flashboot mode uint32_t dig_dbias_slp : 5; //!< set bias for digital domain, in sleep mode uint32_t rtc_dbias_slp : 5; //!< set bias ...
289
< Deep sleep (power down digital domain) #define RTC_SLEEP_PD_VDDSDIO BIT(5) //!< Power down VDDSDIO regulator #define RTC_SLEEP_PD_INT_8M BIT(10) //!< Power down Internal 8M oscillator #define RTC_SLEEP_PD_XTAL BIT(11) //!< Power down main XTAL //These flags are not power domains...
289
< WIFI wakeup (light sleep only) #define RTC_UART0_TRIG_EN BIT(6) //!< UART0 wakeup (light sleep only) #define RTC_UART1_TRIG_EN BIT(7) //!< UART1 wakeup (light sleep only) #define RTC_BT_TRIG_EN BIT(10) //!< BT wakeup (light sleep only) #define RTC_XTAL32K_DEAD_TRIG_EN BIT(12) #de...
289
< Number of rtc_fast_clk cycles to wait for 8M clock to be ready uint32_t xtal_wait : 8; //!< Number of rtc_fast_clk cycles to wait for XTAL clock to be ready uint32_t pll_wait : 8; //!< Number of rtc_fast_clk cycles to wait for PLL to be ready uint32_t clkctl_init : 1; //!< Perform c...
289
bbpll_fpu = 0, \ .cpu_waiti_clk_gate = 1, \ .cali_ocode = 0\ } /** */ void rtc_init(rtc_config_t cfg); // CLOCK TREE DEFS ALIAS // **WARNING**: The following are only for backwards compatibility. // Please use the declarations in soc/clk_tree_defs.h instead. /** */ typedef soc_cpu_clk_src_t rtc_cpu_freq_s...
289
< Main XTAL, divided by 2 #define RTC_FAST_FREQ_8M SOC_RTC_FAST_CLK_SRC_RC_FAST //!< Internal 17.5 MHz RC oscillator /** */ typedef soc_xtal_freq_t rtc_xtal_freq_t; #define RTC_XTAL_FREQ_40M SOC_XTAL_FREQ_40M //!< 40 MHz XTAL #define RTC_XTAL_FREQ_32M SOC_XTAL_FREQ_32M //!< 32 MH...
289
/* */ #pragma once #ifdef __cplusplus extern "C" { #endif /** void esp_ocode_calib_init(void); #ifdef __cplusplus } #endif
290
/* */ #pragma once #include #include #include #include "soc/soc_caps.h" #include "soc/pmu_struct.h" #include "hal/pmu_hal.h" // TODO: [ESP32C5] IDF-8643 #ifdef __cplusplus extern "C" { #endif #define HP_CALI_DBIAS 25 #define LP_CALI_DBIAS 26 // FOR XTAL FORCE PU IN SLEEP #define PMU_PD_CUR_SLEEP_ON 0...
291
h used for the PMU state machine in sleep flow*/ typedef union { struct { uint32_t reserved0 : 21; uint32_t vdd_spi_pd_en: 1; uint32_t mem_dslp : 1; uint32_t mem_pd_en : 4; uint32_t wifi_pd_en : 1; uint32_t reserved1 : 1; uint32_t cpu_pd_en :...
291
6 us */ #define PMU_LP_WAKEUP_DELAY_CYCLES (0) #define PMU_LP_XTAL_STABLE_WAIT_SLOW_CLK_CYCLES (30) /* Slow OSC as PMU slow clock source is about 201 us */ #define PMU_LP_ANALOG_WAIT_TARGET_CYCLES (23) /* Slow OSC as PMU slow clock source is about 154 us */ #define PMU_LP_DIGITAL_POWER_SUPPLY...
291
hp_sys = { \ .dig_power = { \ .vdd_spi_pd_en = ((pd_flags) & PMU_SLEEP_PD_VDDSDIO) ? 1 : 0, \ .wifi_pd_en = ((pd_flags) & PMU_SLEEP_PD_MODEM) ? 1 : 0, \ ....
291
xpd_bb_i2c = 0, \ .xpd_bbpll_i2c = 0, \ .xpd_bbpll = 0 \ }, \ .xtal = { ...
291
clk_power = { \ .xpd_xtal32k = ((pd_flags) & PMU_SLEEP_PD_XTAL32K) ? 0 : 1, \ .xpd_rc32k = ((pd_flags) & PMU_SLEEP_PD_RC32K) ? 0 : 1, \ .xpd_fosc = 1 \ } ...
291
xpd_rc32k = ((pd_flags) & PMU_SLEEP_PD_RC32K) ? 0 : 1, \ .xpd_fosc = ((pd_flags) & PMU_SLEEP_PD_RC_FAST) ? 0 : 1 \ }, \ .xtal = { \ .xpd_xtal...
291
hp_sys = { \ .analog = { \ .drv_b = PMU_HP_DRVB_LIGHTSLEEP, \ .pd_cur = PMU_PD_CUR_SLEEP_DEFAULT, \ .bias_sleep = PMU_BIASSLP_SL...
291
slp_xpd = PMU_LP_SLP_XPD_SLEEP_DEFAULT, \ .slp_dbias = PMU_LP_SLP_DBIAS_SLEEP_DEFAULT, \ .xpd = PMU_LP_XPD_SLEEP_DEFAULT, \ .dbg_atten = PMU_DBG_ATTEN_LIGHTSLEEP_DEFAULT, \ .dbias = PMU_LP_DBIAS_LIGHTSLEEP_...
291
lp_sys[PMU_MODE_LP_SLEEP] = { \ .analog = { \ .drv_b = PMU_LP_DRVB_DEEPSLEEP, \ .pd_cur = PMU_PD_CUR_SLEEP_DEFAULT, \ .bias_sleep = PMU_BIASSLP_SLEE...
291
hp_sys = { \ .min_slp_slow_clk_cycle = PMU_HP_SLEEP_MIN_SLOW_CLK_CYCLES, \ .analog_wait_target_cycle = PMU_HP_ANALOG_WAIT_TARGET_CYCLES, \ .digital_power_supply_wait_cycle = PMU_HP_DIGITAL_POWER_SUP...
291
digital_power_up_wait_cycle = PMU_LP_DIGITAL_POWER_UP_WAIT_CYCLES \ }, \ .hp_lp = { \ .xtal_stable_wait_slow_clk_cycle = PMU_LP_XTAL_STABLE_WAIT_SLOW...
291
lp = { \ .min_slp_time_us = 450, \ .wakeup_wait_cycle = 4, \ .analog_wait_time_us = 154, \ .xtal_wait_stable_time_us = 250, \ .clk_switch_cycle = 1, \ .clk_power_on_wai...
291
regdma_a2s_work_time_us = 382, \ .regdma_rf_on_work_time_us = 70, \ .regdma_rf_off_work_time_us = 23, \ .xtal_wait_stable_time_us = 250, \ .pll_wait_stable_time_us = 1 \ } \ } #ifdef __cplusplus } #endi...
291
/* */ #pragma once #include #include #include #include "soc/soc.h" #include "soc/clk_tree_defs.h" #ifdef __cplusplus extern "C" { #endif // / THIS FILE IS CONSIDERED AS A PRIVATE HEADER FILE / /*** IT IS NOT RECOMMENDED TO USE THE APIS IN THIS FILE DIRECTLY IN APPLICATIONS ****/ // /** */ #define MHZ (1000000...
292
< The clock from which CPU clock is derived uint32_t source_freq_mhz; //!< Source clock frequency uint32_t div; //!< Divider, freq_mhz = SOC_ROOT_CLK freq_mhz / div uint32_t freq_mhz; //!< CPU clock frequency } rtc_cpu_freq_config_t; #define RTC_CLK_CAL_FRACT 19 //!< ...
292
< External slow clock signal input by lp_pad_gpio0, as one type of 32k clock // RTC_CAL_RC_FAST //!< Internal 20MHz RC oscillator } rtc_cal_sel_t; /** */ typedef struct { soc_xtal_freq_t xtal_freq : 8; //!< Main XTAL frequency uint32_t cpu_freq_mhz : 10; ...
292
< Internal RC32K clock adjustment parameter (higher value leads to higher frequency) } rtc_clk_config_t; /** */ #define RTC_CLK_CONFIG_DEFAULT() { \ .xtal_freq = CONFIG_XTAL_FREQ, \ .cpu_freq_mhz = 80, \ .fast_clk_src = SOC_RTC_FAST_CLK_SRC_RC_FAST, \ .slow_clk_src = SOC_RTC_SLOW_CLK_SRC_RC32K, \ ...
292
// Please use the declarations in soc/clk_tree_defs.h instead. /** */ typedef soc_xtal_freq_t rtc_xtal_freq_t; #define RTC_XTAL_FREQ_40M SOC_XTAL_FREQ_40M //!< 40 MHz XTAL #define RTC_XTAL_FREQ_48M SOC_XTAL_FREQ_48M //!< 48 MHz XTAL #ifdef __cplusplus } #endif
292
/* */ #pragma once #include #include #include #include "soc/soc.h" #include "soc/clk_tree_defs.h" #ifdef __cplusplus extern "C" { #endif // / THIS FILE IS CONSIDERED AS A PRIVATE HEADER FILE / /*** IT IS NOT RECOMMENDED TO USE THE APIS IN THIS FILE DIRECTLY IN APPLICATIONS ****/ // /** */ #define MHZ (1000000...
293
34v in fact /* Delays for various clock sources to be enabled/switched. */ #define SOC_DELAY_RTC_FAST_CLK_SWITCH 3 #define SOC_DELAY_RTC_SLOW_CLK_SWITCH 300 #define SOC_DELAY_RC_FAST_ENABLE 50 #define SOC_DELAY_RC_FAST_DIGI_SWITCH 5 /* Core voltage: */ #define DIG_DBIAS_80M RTC_CN...
293
< The clock from which CPU clock is derived uint32_t source_freq_mhz; //!< Source clock frequency uint32_t div; //!< Divider, freq_mhz = source_freq_mhz / div uint32_t freq_mhz; //!< CPU clock frequency } rtc_cpu_freq_config_t; #define RTC_CLK_CAL_FRACT 19 //!< Number...
293
< RTC_FAST_CLK clock source to choose soc_rtc_slow_clk_src_t slow_clk_src : 2; //!< RTC_SLOW_CLK clock source to choose uint32_t clk_rtc_clk_div : 8; uint32_t clk_8m_clk_div : 3; //!< RTC 8M clock divider (division is by clk_8m_div+1, i.e. 0 means 8MHz frequency) uint32_t slow_clk_dcap :...
293
wifi_powerup_cycles = OTHER_BLOCKS_POWERUP, \ .wifi_wait_cycles = OTHER_BLOCKS_WAIT, \ .bt_powerup_cycles = OTHER_BLOCKS_POWERUP, \ .bt_wait_cycles = OTHER_BLOCKS_WAIT, \ .cpu_top_powerup_cycles = OTHER_BLOCKS_POWERUP, \ .cpu_top_wait_cycles = OTHER_BLOCKS_WAIT, \ .dg_wrap_powerup_cycles = OTHER...
293
< Set to 1 to power UP digital part in sleep uint32_t rtc_fpu : 1; //!< Set to 1 to power UP RTC memories in sleep uint32_t cpu_fpu : 1; //!< Set to 1 to power UP digital memories and CPU in sleep uint32_t i2s_fpu : 1; //!< Set to 1 to power UP I2S in sleep uint32_t bb_fpu : 1; //!< Set to ...
293
< force normal voltage in sleep mode (digital domain memory) uint32_t rtc_mem_inf_follow_cpu : 1;//!< keep low voltage in sleep mode (even if ULP/touch is used) uint32_t rtc_fastmem_pd_en : 1; //!< power down RTC fast memory uint32_t rtc_slowmem_pd_en : 1; //!< power down RTC slow memory uint32_...
293
< set bias for RTC domain, in sleep mode uint32_t dbg_atten_slp : 4; //!< voltage parameter, in sleep mode uint32_t bias_sleep_slp : 1; //!< circuit control parameter, in sleep mode uint32_t pd_cur_slp : 1; //!< circuit control parameter, in sleep mode uint32_t vddsdio_pd_en : ...
293
< RTC FAST and SLOW memories are automatically powered up and down along with the CPU #define RTC_SLEEP_PD_VDDSDIO BIT(5) //!< Power down VDDSDIO regulator #define RTC_SLEEP_PD_WIFI BIT(6) //!< Power down WIFI #define RTC_SLEEP_PD_BT BIT(7) //!< Power down BT #define RTC_SLEE...
293
< GPIO wakeup #define RTC_TIMER_TRIG_EN BIT(3) //!< Timer wakeup #define RTC_WIFI_TRIG_EN BIT(5) //!< WIFI wakeup (light sleep only) #define RTC_UART0_TRIG_EN BIT(6) //!< UART0 wakeup (light sleep only) #define RTC_UART1_TRIG_EN BIT(7) //!< UART1 wakeup (light sleep only) #d...
293
< Number of rtc_fast_clk cycles to wait for 8M clock to be ready uint32_t xtal_wait : 8; //!< Number of rtc_fast_clk cycles to wait for XTAL clock to be ready uint32_t pll_wait : 8; //!< Number of rtc_fast_clk cycles to wait for PLL to be ready uint32_t clkctl_init : 1; //!< Perform c...
293
bbpll_fpu = 0, \ .cpu_waiti_clk_gate = 1, \ .cali_ocode = 0\ } /** */ void rtc_init(rtc_config_t cfg); // CLOCK TREE DEFS ALIAS // **WARNING**: The following are only for backwards compatibility. // Please use the declarations in soc/clk_tree_defs.h instead. /** */ typedef soc_cpu_clk_src_t rtc_cpu_freq_s...
293
< Main XTAL, divided by 2 #define RTC_FAST_FREQ_8M SOC_RTC_FAST_CLK_SRC_RC_FAST //!< Internal 17.5 MHz RC oscillator /** */ typedef soc_xtal_freq_t rtc_xtal_freq_t; #define RTC_XTAL_FREQ_40M SOC_XTAL_FREQ_40M //!< 40 MHz XTAL #define RTC_XTAL_FREQ_32M SOC_XTAL_FREQ_32M //!< 32 MH...
293
/* */ #pragma once #include "esp_rom_sys.h" /** */ #ifdef ESP_PLATFORM #include "esp_log.h" #define ESP_HW_LOGE(tag, fmt, ...) ESP_EARLY_LOGE(tag, fmt, ##__VA_ARGS__) #define ESP_HW_LOGW(tag, fmt, ...) ESP_EARLY_LOGW(tag, fmt, ##__VA_ARGS__) #define ESP_HW_LOGI(tag, fmt, ...) ESP_EARLY_LOGI(tag, fmt, ##__VA_ARGS__...
294
/* */ #pragma once #include "esp_psram.h" #warning "esp_spiram.h is deprecated, please migrate to esp_psram.h"
295
/* */ #pragma once #include #include #include #include "soc/soc.h" #include "soc/rtc_periph.h" #include "soc/clk_tree_defs.h" #ifdef __cplusplus extern "C" { #endif // / THIS FILE IS CONSIDERED AS A PRIVATE HEADER FILE / /*** IT IS NOT RECOMMENDED TO USE THE APIS IN THIS FILE DIRECTLY IN APPLICATIONS ****/ // /...
296
< The clock from which CPU clock is derived uint32_t source_freq_mhz; //!< Source clock frequency uint32_t div; //!< Divider, freq_mhz = source_freq_mhz / div uint32_t freq_mhz; //!< CPU clock frequency } rtc_cpu_freq_config_t; /** */ typedef enum { RTC_CAL_RTC_MUX...
296
e. 0 means 8MHz frequency) uint32_t slow_clk_dcap : 8; //!< RTC 150k clock adjustment parameter (higher value leads to lower frequency) uint32_t clk_8m_dfreq : 8; //!< RTC 8m clock adjustment parameter (higher value leads to higher frequency) } rtc_clk_config_t; /** */ #define R...
296
< Number of fractional bits in values returned by rtc_clk_cal /** */ uint32_t rtc_clk_cal(rtc_cal_sel_t cal_clk, uint32_t slow_clk_cycles); /** */ uint32_t rtc_clk_cal_ratio(rtc_cal_sel_t cal_clk, uint32_t slow_clk_cycles); /** */ uint64_t rtc_time_us_to_slowclk(uint64_t time_in_us, uint32_t period); /** */ uin...
296
< power down RTC fast memory uint32_t rtc_slowmem_pd_en : 1; //!< power down RTC slow memory uint32_t rtc_peri_pd_en : 1; //!< power down RTC peripherals uint32_t modem_pd_en : 1; //!< power down Modem(wifi and btdm) uint32_t int_8m_pd_en : 1; //!< Power down Internal 8M os...
296
< power down VDDSDIO regulator uint32_t xtal_fpu : 1; //!< keep main XTAL powered up in sleep uint32_t deep_slp_reject : 1; //!< enable deep sleep reject uint32_t light_slp_reject : 1; //!< enable light sleep reject uint32_t dbg_atten_slp : 2; //!< voltage parameter }...
296
< Power down main XTAL #define RTC_SLEEP_PD_INT_8M BIT(8) //!< Power down Internal 8M oscillator //These flags are not power domains, but will affect some sleep parameters #define RTC_SLEEP_DIG_USE_8M BIT(16) #define RTC_SLEEP_USE_ADC_TESEN_MONITOR BIT(17) #define RTC_SLEEP_NO_ULTRA_LOW ...
296
< EXT0 GPIO wakeup #define RTC_EXT1_TRIG_EN BIT(1) //!< EXT1 GPIO wakeup #define RTC_GPIO_TRIG_EN BIT(2) //!< GPIO wakeup (light sleep only) #define RTC_TIMER_TRIG_EN BIT(3) //!< Timer wakeup #define RTC_SDIO_TRIG_EN BIT(4) //!< SDIO wakeup (light sleep only) #define RTC_MAC_TRIG_EN BIT(5) //!< MAC ...
296
< Number of rtc_fast_clk cycles to wait for XTAL clock to be ready uint32_t pll_wait : 8; //!< Number of rtc_fast_clk cycles to wait for PLL to be ready uint32_t clkctl_init : 1; //!< Perform clock control related initialization uint32_t pwrctl_init : 1; //!< Perform power control relat...
296
uint32_t enable : 1; //!< Enable VDDSDIO regulator uint32_t tieh : 1; //!< Select VDDSDIO voltage. One of RTC_VDDSDIO_TIEH_1_8V, RTC_VDDSDIO_TIEH_3_3V uint32_t drefh : 2; //!< Tuning parameter for VDDSDIO regulator uint32_t drefm : 2; //!< Tuning parameter for VDDSDIO regulator uint...
296
< APLL /** */ typedef soc_rtc_slow_clk_src_t rtc_slow_freq_t; #define RTC_SLOW_FREQ_RTC SOC_RTC_SLOW_CLK_SRC_RC_SLOW //!< Internal 150 kHz RC oscillator #define RTC_SLOW_FREQ_32K_XTAL SOC_RTC_SLOW_CLK_SRC_XTAL32K //!< External 32 kHz XTAL #define RTC_SLOW_FREQ_8MD256 SOC_RTC_SLOW_CLK_SRC_RC_FAST_D256 //!< ...
296
/* */ #pragma once #ifdef __cplusplus extern "C" { #endif /** void esp_ocode_calib_init(void); #ifdef __cplusplus } #endif
297
/* */ #pragma once #include #include #include #include "soc/pmu_struct.h" #include "hal/pmu_hal.h" #ifdef __cplusplus extern "C" { #endif #define HP_CALI_DBIAS_DEFAULT 25 #define LP_CALI_DBIAS_DEFAULT 26 // FOR XTAL FORCE PU IN SLEEP #define PMU_PD_CUR_SLEEP_ON 0 #define PMU_BIASSLP_SLEEP_ON 0 // FO...
298
h used for the PMU state machine in sleep flow*/ typedef union { struct { uint32_t reserved0 : 21; uint32_t vdd_spi_pd_en: 1; uint32_t mem_dslp : 1; uint32_t mem_pd_en : 4; uint32_t wifi_pd_en : 1; uint32_t reserved1 : 1; uint32_t cpu_pd_en :...
298
6 us */ #define PMU_LP_WAKEUP_DELAY_CYCLES (0) #define PMU_LP_XTAL_STABLE_WAIT_SLOW_CLK_CYCLES (30) /* Slow OSC as PMU slow clock source is about 201 us */ #define PMU_LP_ANALOG_WAIT_TARGET_CYCLES (23) /* Slow OSC as PMU slow clock source is about 154 us */ #define PMU_LP_DIGITAL_POWER_SUPPLY...
298
hp_sys = { \ .dig_power = { \ .vdd_spi_pd_en = ((pd_flags) & PMU_SLEEP_PD_VDDSDIO) ? 1 : 0, \ .wifi_pd_en = ((pd_flags) & PMU_SLEEP_PD_MODEM) ? 1 : 0, \ ....
298
xpd_bb_i2c = 0, \ .xpd_bbpll_i2c = 0, \ .xpd_bbpll = 0 \ }, \ .xtal = { ...
298
clk_power = { \ .xpd_xtal32k = ((pd_flags) & PMU_SLEEP_PD_XTAL32K) ? 0 : 1, \ .xpd_rc32k = ((pd_flags) & PMU_SLEEP_PD_RC32K) ? 0 : 1, \ .xpd_fosc = 1 \ } ...
298
xpd_rc32k = ((pd_flags) & PMU_SLEEP_PD_RC32K) ? 0 : 1, \ .xpd_fosc = ((pd_flags) & PMU_SLEEP_PD_RC_FAST) ? 0 : 1 \ }, \ .xtal = { \ .xpd_xtal...
298
hp_sys = { \ .analog = { \ .drv_b = PMU_HP_DRVB_LIGHTSLEEP, \ .pd_cur = PMU_PD_CUR_SLEEP_DEFAULT, \ .bias_sleep = PMU_BIASSLP_SL...
298
slp_xpd = PMU_LP_SLP_XPD_SLEEP_DEFAULT, \ .slp_dbias = PMU_LP_SLP_DBIAS_SLEEP_DEFAULT, \ .xpd = PMU_LP_XPD_SLEEP_DEFAULT, \ .dbg_atten = PMU_DBG_ATTEN_LIGHTSLEEP_DEFAULT, \ .dbias = PMU_LP_DBIAS_LIGHTSLEEP_...
298
lp_sys[PMU_MODE_LP_SLEEP] = { \ .analog = { \ .drv_b = PMU_LP_DRVB_DEEPSLEEP, \ .pd_cur = PMU_PD_CUR_SLEEP_DEFAULT, \ .bias_sleep = PMU_BIASSLP_SLEE...
298
hp_sys = { \ .min_slp_slow_clk_cycle = PMU_HP_SLEEP_MIN_SLOW_CLK_CYCLES, \ .analog_wait_target_cycle = PMU_HP_ANALOG_WAIT_TARGET_CYCLES, \ .digital_power_supply_wait_cycle = PMU_HP_DIGITAL_POWER_SUP...
298
digital_power_up_wait_cycle = PMU_LP_DIGITAL_POWER_UP_WAIT_CYCLES \ }, \ .hp_lp = { \ .xtal_stable_wait_slow_clk_cycle = PMU_LP_XTAL_STABLE_WAIT_SLOW...
298
lp = { \ .min_slp_time_us = 450, \ .wakeup_wait_cycle = 4, \ .analog_wait_time_us = 154, \ .xtal_wait_stable_time_us = 250, \ .clk_switch_cycle = 1, \ .clk_power_on_wai...
298
regdma_a2s_work_time_us = 382, \ .regdma_rf_on_work_time_us = 70, \ .regdma_rf_off_work_time_us = 23, \ .xtal_wait_stable_time_us = 250, \ .pll_wait_stable_time_us = 1 \ } \ } #ifdef __cplusplus } #endi...
298
/* */ #pragma once #include #include #include #include "soc/soc.h" #include "soc/clk_tree_defs.h" #ifdef __cplusplus extern "C" { #endif // / THIS FILE IS CONSIDERED AS A PRIVATE HEADER FILE / /*** IT IS NOT RECOMMENDED TO USE THE APIS IN THIS FILE DIRECTLY IN APPLICATIONS ****/ // /** */ #define MHZ (1000000...
299
< The clock from which CPU clock is derived uint32_t source_freq_mhz; //!< Source clock frequency uint32_t div; //!< Divider, freq_mhz = SOC_ROOT_CLK freq_mhz / div uint32_t freq_mhz; //!< CPU clock frequency } rtc_cpu_freq_config_t; #define RTC_CLK_CAL_FRACT 19 //!< ...
299
< External slow clock signal input by lp_pad_gpio0, as one type of 32k clock RTC_CAL_RC_FAST //!< Internal 20MHz RC oscillator } rtc_cal_sel_t; /** */ typedef struct { soc_xtal_freq_t xtal_freq : 8; //!< Main XTAL frequency uint32_t cpu_freq_mhz : 10; ...
299
< Internal RC32K clock adjustment parameter (higher value leads to higher frequency) } rtc_clk_config_t; /** */ #define RTC_CLK_CONFIG_DEFAULT() { \ .xtal_freq = CONFIG_XTAL_FREQ, \ .cpu_freq_mhz = 80, \ .fast_clk_src = SOC_RTC_FAST_CLK_SRC_RC_FAST, \ .slow_clk_src = SOC_RTC_SLOW_CLK_SRC_RC_SLOW, \ ...
299
// Please use the declarations in soc/clk_tree_defs.h instead. /** */ typedef soc_cpu_clk_src_t rtc_cpu_freq_src_t; #define RTC_CPU_FREQ_SRC_XTAL SOC_CPU_CLK_SRC_XTAL //!< XTAL #define RTC_CPU_FREQ_SRC_PLL SOC_CPU_CLK_SRC_PLL //!< PLL (480M) #define RTC_CPU_FREQ_SRC_8M SOC_CPU_CLK_SRC_RC_FAST //!< Internal 17.5M ...
299
/* */ #pragma once #include #include #include #include "soc/pmu_struct.h" #include "hal/pmu_hal.h" #ifdef __cplusplus extern "C" { #endif #define HP_CALI_DBIAS_DEFAULT 17 #define LP_CALI_DBIAS_DEFAULT 18 // FOR XTAL FORCE PU IN SLEEP #define PMU_PD_CUR_SLEEP_ON 0 #define PMU_BIASSLP_SLEEP_ON 0 #defin...
300
h used for the PMU state machine in sleep flow*/ typedef union { struct { uint32_t reserved0 : 21; uint32_t vdd_spi_pd_en: 1; uint32_t mem_dslp : 1; uint32_t mem_pd_en : 4; uint32_t wifi_pd_en : 1; uint32_t reserved1 : 1; uint32_t cpu_pd_en :...
300
hp_sys = { \ .dig_power = { \ .vdd_spi_pd_en = ((pd_flags) & PMU_SLEEP_PD_VDDSDIO) ? 1 : 0, \ .wifi_pd_en = ((pd_flags) & PMU_SLEEP_PD_MODEM) ? 1 : 0, \ ....
300
xpd_bbpll_i2c = 0, \ .xpd_bbpll = 0 \ }, \ .xtal = { \ .xpd_xtal...
300
xpd_xtal32k = ((pd_flags) & PMU_SLEEP_PD_XTAL32K) ? 0 : 1, \ .xpd_rc32k = ((pd_flags) & PMU_SLEEP_PD_RC32K) ? 0 : 1, \ .xpd_fosc = 1 \ } \ }, ...
300
xpd_fosc = ((pd_flags) & PMU_SLEEP_PD_RC_FAST) ? 0 : 1 \ }, \ .xtal = { \ .xpd_xtal = ((pd_flags) & PMU_SLEEP_PD_XTAL) ? 0 : 1, \ } ...
300
hp_sys = { \ .analog = { \ .xpd_trx = PMU_XPD_TRX_SLEEP_DEFAULT, \ .drv_b = PMU_HP_DRVB_LIGHTSLEEP, \ .pd_cur = PMU_PD_CUR_SLEEP_DEFAULT, \ .bi...
300
slp_dbias = PMU_LP_SLP_DBIAS_SLEEP_DEFAULT,\ .xpd = PMU_LP_XPD_SLEEP_DEFAULT, \ .dbias = PMU_LP_DBIAS_SLEEP_0V7_DEFAULT \ } \ } \ } #define PMU_SLEEP_...
300
pd_cur = PMU_PD_CUR_SLEEP_DEFAULT, \ .bias_sleep = PMU_BIASSLP_SLEEP_DEFAULT, \ .slp_xpd = PMU_LP_SLP_XPD_SLEEP_DEFAULT, \ .slp_dbias = PMU_LP_SLP_DBIAS_SLEEP_DEFAULT,\ .xpd = PMU_LP_XPD_SLEEP_DEFAULT, \ .dbias ...
300
digital_power_up_wait_cycle = PMU_HP_DIGITAL_POWER_UP_WAIT_CYCLES, \ .pll_stable_wait_cycle = PMU_HP_PLL_STABLE_WAIT_CYCLES \ }, \ .lp_sys = { ...
300
lp = { \ .min_slp_time_us = 450, \ .analog_wait_time_us = 154, \ .xtal_wait_stable_time_us = 250, \ .clk_switch_cycle = 1, \ .clk_power_on_wait_cycle = 1, \ .power_supply_wai...
300
/* */ #pragma once #include #include #include #include "soc/soc.h" #include "soc/clk_tree_defs.h" #ifdef __cplusplus extern "C" { #endif // / THIS FILE IS CONSIDERED AS A PRIVATE HEADER FILE / /*** IT IS NOT RECOMMENDED TO USE THE APIS IN THIS FILE DIRECTLY IN APPLICATIONS ****/ // /** */ #define MHZ (1000000...
301
< The clock from which CPU clock is derived uint32_t source_freq_mhz; //!< Source clock frequency uint32_t div; //!< Divider, freq_mhz = source_freq_mhz / div uint32_t freq_mhz; //!< CPU clock frequency } rtc_cpu_freq_config_t; #define RTC_CLK_CAL_FRACT 19 //!< Number...
301
< External slow clock signal input by lp_pad_gpiox, as one type of 32k clock RTC_CAL_RC_FAST //!< Internal 8MHz RC oscillator } rtc_cal_sel_t; /** */ typedef struct { soc_xtal_freq_t xtal_freq : 8; //!< Main XTAL frequency uint32_t cpu_freq_mhz : 10; ...
301
< Internal RC32K clock adjustment parameter (higher value leads to higher frequency) } rtc_clk_config_t; /** */ #define RTC_CLK_CONFIG_DEFAULT() { \ .xtal_freq = SOC_XTAL_FREQ_32M, \ .cpu_freq_mhz = 96, \ .fast_clk_src = SOC_RTC_FAST_CLK_SRC_RC_FAST, \ .slow_clk_src = SOC_RTC_SLOW_CLK_SRC_RC_SLOW, \ ...
301
// Please use the declarations in soc/clk_tree_defs.h instead. /** */ typedef soc_cpu_clk_src_t rtc_cpu_freq_src_t; #define RTC_CPU_FREQ_SRC_XTAL SOC_CPU_CLK_SRC_XTAL //!< XTAL #define RTC_CPU_FREQ_SRC_PLL SOC_CPU_CLK_SRC_PLL //!< PLL (96M) #define RTC_CPU_FREQ_SRC_8M SOC_CPU_CLK_SRC_RC_FAST //!< Internal 8M RTC ...
301
/* */ #pragma once #include "sdkconfig.h" #include "esp_assert.h" #include "esp_flash_partitions.h" #define MSPI_TIMING_MSPI1_IS_INVOLVED 1 //This means esp flash driver needs to be notified #define MSPI_TIMING_CONFIG_NUM_MAX 20 //This should be larger than the max available timin...
302
CONFIG_SPIRAM_MODE_OCT //PSRAM Module Clock // #if CONFIG_SPIRAM #if CONFIG_SPIRAM_SPEED_40M #define MSPI_TIMING_PSRAM_MODULE_CLOCK 40 #elif CONFIG_SPIRAM_SPEED_80M #define MSPI_TIMING_PSRAM_MODULE_CLOCK 80 #else //CONFIG_SPIRAM_SPEED_120M #define MSPI_TIMING_PSRAM_MODULE_CLOCK ...
302
MSPI_TIMING_PSRAM_NEEDS_TUNING ESP_STATIC_ASSERT(MSPI_TIMING_FLASH_EXPECTED_CORE_CLK_MHZ % MSPI_TIMING_PSRAM_MODULE_CLOCK == 0, "FLASH and PSRAM Mode configuration are not supported"); #define MSPI_TIMING_CORE_CLOCK_MHZ MSPI_TIMING_FLASH_EXPECTED_CORE_CLK_MHZ //If only PSRAM needs tuning, the core cl...
302
tuning_config_table = MSPI_TIMING_##type##_CONFIG_TABLE_CORE_CLK_##core_clock##M_MODULE_CLK_##module_clock##M_##mode, \ .available_config_num = MSPI_TIMING_##type##_CONFIG_NUM_CORE_CLK_##core_clock##M_MODULE_CLK_##module_clock##M_##mode, \ .default_config_...
302
/* */ #pragma once #include #include #include #include "soc/soc.h" #include "soc/clk_tree_defs.h" #ifdef __cplusplus extern "C" { #endif // / THIS FILE IS CONSIDERED AS A PRIVATE HEADER FILE / /*** IT IS NOT RECOMMENDED TO USE THE APIS IN THIS FILE DIRECTLY IN APPLICATIONS ****/ // /** */ #define MHZ (100000...
303
34v in fact /* Delays for various clock sources to be enabled/switched. */ #define SOC_DELAY_RTC_FAST_CLK_SWITCH 3 #define SOC_DELAY_RTC_SLOW_CLK_SWITCH 300 #define SOC_DELAY_RC_FAST_ENABLE 50 #define SOC_DELAY_RC_FAST_DIGI_SWITCH 5 /* Core voltage needs to be increased in two cases: */...
303
< The clock from which CPU clock is derived uint32_t source_freq_mhz; //!< Source clock frequency uint32_t div; //!< Divider, freq_mhz = source_freq_mhz / div uint32_t freq_mhz; //!< CPU clock frequency } rtc_cpu_freq_config_t; #define RTC_CLK_CAL_FRACT 19 //!< Number...
303
< RTC_FAST_CLK clock source to choose soc_rtc_slow_clk_src_t slow_clk_src : 2; //!< RTC_SLOW_CLK clock source to choose uint32_t clk_rtc_clk_div : 8; uint32_t clk_8m_clk_div : 3; //!< RTC 8M clock divider (division is by clk_8m_div+1, i.e. 0 means 8MHz frequency) uint32_t slow_clk_dcap :...
303
wifi_powerup_cycles = OTHER_BLOCKS_POWERUP, \ .wifi_wait_cycles = OTHER_BLOCKS_WAIT, \ .bt_powerup_cycles = OTHER_BLOCKS_POWERUP, \ .bt_wait_cycles = OTHER_BLOCKS_WAIT, \ .rtc_powerup_cycles = OTHER_BLOCKS_POWERUP, \ .rtc_wait_cycles = OTHER_BLOCKS_WAIT, \ .cpu_top_powerup_cycles = OTHER_BLOCKS_...
303
< Set to 1 to power UP digital part in sleep uint32_t rtc_fpu : 1; //!< Set to 1 to power UP RTC memories in sleep uint32_t cpu_fpu : 1; //!< Set to 1 to power UP digital memories and CPU in sleep uint32_t i2s_fpu : 1; //!< Set to 1 to power UP I2S in sleep uint32_t bb_fpu : 1; //!< Set to ...
303
< force normal voltage in sleep mode (digital domain memory) uint32_t rtc_mem_inf_follow_cpu : 1;//!< keep low voltage in sleep mode (even if ULP/touch is used) uint32_t rtc_fastmem_pd_en : 1; //!< power down RTC fast memory uint32_t rtc_slowmem_pd_en : 1; //!< power down RTC slow memory uint32_...
303
< circuit control parameter, in monitor mode uint32_t dbg_atten_slp : 4; //!< voltage parameter, in sleep mode uint32_t bias_sleep_slp : 1; //!< circuit control parameter, in sleep mode uint32_t pd_cur_monitor : 1; //!< circuit control parameter, in monitor mode uint32_t pd_cur_slp...
303