ESP32 ADC precision

nassimk
Posts: 1
Joined: Wed Dec 14, 2016 8:21 pm

ESP32 ADC precision

Postby nassimk » Wed Dec 14, 2016 8:46 pm

Hi,

I'm testing the ESP32's ADC functionality on the SparkFun ESP32 Thing.
Here is my test code :

Code: Select all

ESP_ERROR_CHECK(adc1_config_width(ADC_WIDTH_12Bit));
ESP_ERROR_CHECK(adc1_config_channel_atten(ADC1_CHANNEL_7, ADC_ATTEN_0db));

while (true) {
	vTaskDelay(300 / portTICK_PERIOD_MS);
        printf("ADC value : %d\n", adc1_get_voltage(ADC1_CHANNEL_7));
}
What is the best precision i can normally reach ? Currently, my zero value is around 90mV...
The measure seems also very noisy, it constantly oscillates on the 4 first bits.

Thank you in advance for your help.

johnlee
Posts: 34
Joined: Sun Nov 15, 2015 4:27 am

Re: ESP32 ADC precision

Postby johnlee » Sun Dec 18, 2016 4:13 pm

the ADC is 12-bit. but it could be affected by:
1. ground bounce due to power amplifier,
2. missing decoupling capacitors, and
3. insufficient settling time.

Who is online

Users browsing this forum: Bing [Bot] and 300 guests