[][src]Function esp_idf_bindgen::adc1_get_raw

pub unsafe extern "C" fn adc1_get_raw(channel: adc1_channel_t) -> c_int

@brief Take an ADC1 reading from a single channel. @note ESP32: When the power switch of SARADC1, SARADC2, HALL sensor and AMP sensor is turned on, the input of GPIO36 and GPIO39 will be pulled down for about 80ns. When enabling power for any of these peripherals, ignore input from GPIO36 and GPIO39. Please refer to section 3.11 of 'ECO_and_Workarounds_for_Bugs_in_ESP32' for the description of this issue.

@note Call adc1_config_width() before the first time this function is called.

@note For any given channel, adc1_config_channel_atten(channel) must be called before the first time this function is called. Configuring a new channel does not prevent a previously configured channel from being read.

@param channel ADC1 channel to read

@return - -1: Parameter error - Other: ADC1 channel reading.