diff --git a/components/bootloader/src/main/bootloader_start.c b/components/bootloader/src/main/bootloader_start.c index c3ddf0e10..e567c78ef 100644 --- a/components/bootloader/src/main/bootloader_start.c +++ b/components/bootloader/src/main/bootloader_start.c @@ -622,6 +622,7 @@ void print_flash_info(const esp_image_header_t* phdr) #endif } +#if CONFIG_CONSOLE_UART_CUSTOM static uint32_t get_apb_freq(void) { // Get the value of APB clock from RTC memory. @@ -639,6 +640,7 @@ static uint32_t get_apb_freq(void) return APB_CLK_FREQ_ROM; } } +#endif static void uart_console_configure(void) { diff --git a/components/driver/rtc_module.c b/components/driver/rtc_module.c index ab6112d4f..ecb7e434d 100644 --- a/components/driver/rtc_module.c +++ b/components/driver/rtc_module.c @@ -378,21 +378,6 @@ static esp_err_t touch_start(touch_pad_t touch_num) return ESP_OK; } -static esp_err_t touch_stop(touch_pad_t touch_num) -{ - RTC_MODULE_CHECK(touch_num < TOUCH_PAD_MAX, "Touch_Pad Num Err", ESP_ERR_INVALID_ARG); - portENTER_CRITICAL(&rtc_spinlock); - - //Disable Digital rtc control :work mode and out mode - CLEAR_PERI_REG_MASK(SENS_SAR_TOUCH_ENABLE_REG, (1 << (touch_num + SENS_TOUCH_PAD_WORKEN_S)) | \ - (1 << (touch_num + SENS_TOUCH_PAD_OUTEN2_S)) | \ - (1 << (touch_num + SENS_TOUCH_PAD_OUTEN1_S))); - - portEXIT_CRITICAL(&rtc_spinlock); - - return ESP_OK; -} - esp_err_t touch_pad_config(touch_pad_t touch_num, uint16_t threshold) { RTC_MODULE_CHECK(touch_num < TOUCH_PAD_MAX, "Touch_Pad Num Err", ESP_ERR_INVALID_ARG); @@ -528,7 +513,6 @@ esp_err_t adc1_config_width(adc_bits_width_t width_bit) int adc1_get_voltage(adc1_channel_t channel) { uint16_t adc_value; - uint8_t atten = 0; RTC_MODULE_CHECK(channel < ADC1_CHANNEL_MAX, "ADC Channel Err", ESP_ERR_INVALID_ARG); portENTER_CRITICAL(&rtc_spinlock); @@ -608,23 +592,6 @@ static esp_err_t dac_out_enable(dac_channel_t channel) return ESP_OK; } -static esp_err_t dac_out_disable(dac_channel_t channel) -{ - if (channel == DAC_CHANNEL_1) { - portENTER_CRITICAL(&rtc_spinlock); - CLEAR_PERI_REG_MASK(RTC_IO_PAD_DAC1_REG, RTC_IO_PDAC1_XPD_DAC | RTC_IO_PDAC1_DAC_XPD_FORCE); - portEXIT_CRITICAL(&rtc_spinlock); - } else if (channel == DAC_CHANNEL_2) { - portENTER_CRITICAL(&rtc_spinlock); - CLEAR_PERI_REG_MASK(RTC_IO_PAD_DAC2_REG, RTC_IO_PDAC2_XPD_DAC | RTC_IO_PDAC2_DAC_XPD_FORCE); - portEXIT_CRITICAL(&rtc_spinlock); - } else { - return ESP_ERR_INVALID_ARG; - } - - return ESP_OK; -} - esp_err_t dac_out_voltage(dac_channel_t channel, uint8_t dac_value) { RTC_MODULE_CHECK(channel < DAC_CHANNEL_MAX, "DAC Channel Err", ESP_ERR_INVALID_ARG);