bootloader, driver/rtc: fix warnings about unused functions

This commit is contained in:
Ivan Grokhotkov 2016-12-09 15:47:32 +08:00
parent bf57594ebe
commit f504e23d0f
2 changed files with 2 additions and 33 deletions

View file

@ -622,6 +622,7 @@ void print_flash_info(const esp_image_header_t* phdr)
#endif #endif
} }
#if CONFIG_CONSOLE_UART_CUSTOM
static uint32_t get_apb_freq(void) static uint32_t get_apb_freq(void)
{ {
// Get the value of APB clock from RTC memory. // 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; return APB_CLK_FREQ_ROM;
} }
} }
#endif
static void uart_console_configure(void) static void uart_console_configure(void)
{ {

View file

@ -378,21 +378,6 @@ static esp_err_t touch_start(touch_pad_t touch_num)
return ESP_OK; 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) 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); 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) int adc1_get_voltage(adc1_channel_t channel)
{ {
uint16_t adc_value; uint16_t adc_value;
uint8_t atten = 0;
RTC_MODULE_CHECK(channel < ADC1_CHANNEL_MAX, "ADC Channel Err", ESP_ERR_INVALID_ARG); RTC_MODULE_CHECK(channel < ADC1_CHANNEL_MAX, "ADC Channel Err", ESP_ERR_INVALID_ARG);
portENTER_CRITICAL(&rtc_spinlock); portENTER_CRITICAL(&rtc_spinlock);
@ -608,23 +592,6 @@ static esp_err_t dac_out_enable(dac_channel_t channel)
return ESP_OK; 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) 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); RTC_MODULE_CHECK(channel < DAC_CHANNEL_MAX, "DAC Channel Err", ESP_ERR_INVALID_ARG);