22.1 C
New York
Thursday, September 19, 2024

Simon Monk Places Three Standard Microcontroller Boards Head-to-Head in an ADC Showdown



Maker and creator Simon Monk has put three standard microcontroller boards by way of their paces to reply one easy query: which, out of the Espressif ESP32, Raspberry Pi RP2040, and the venerable Microchip ATmega328, delivers the very best analog-to-digital converter (ADC) enter?

“After some inconsistent and unreliable outcomes studying an analog enter from an [Espressif] ESP32 board,” Monk explains in a weblog submit delivered to our consideration by Adafruit, “I made a decision to get all scientific and do some experimenting with an ESP32, a Raspberry Pi Pico and an Arduino UNO R3. My check setup was a bench energy provide offering the reference voltage to be measured by the check board. The output of the bench PSU had a dummy load of a 470Ω resistor and a 100nF capacitor in parallel (the latter largely for superstitions causes, because the voltage output appears to be like extraordinarily secure on a DMM voltmeter.)”

With this easy circuit arrange, Monk linked the output of the benchtop energy provide to the analog enter of the microcontroller on check — switching it by way of 0V as much as the board’s most rated enter voltage. “I used to be significantly enthusiastic about three issues,” Monk explains. “Discovering any dead-zones at every finish of the analog enter voltage vary. Measuring the reproducibility of the readings. Linearity by way of the vary.”

A Wemos LOLIN32 Lite, constructed round an Espressif ESP32 microcontroller, was the primary machine on check — delivering an sudden lifeless zone between 0V and 0.05V and appreciable noise earlier than 0.1V, with 100-sample testing exhibiting ±3 customary deviations (SDs) for nearly all samples. “It retains fairly good linearity,” Monk notes, “as much as the 1V higher restrict.”

The Raspberry Pi RP2040 on the Raspberry Pi Pico was the following board examined, delivering “smaller 3x SD error bars,” Monk explains, “a small lifeless zone on the low voltage finish and a few slight tail-off in linearity on the 3.3V finish.” This latter additionally reveals one other benefit of the RP2040: its analog enter can settle for as much as 3.3V, in comparison with the 1V restrict on the Wemos board.

Lastly, the venerable Arduino UNO — examined right here in its standard R3 kind, relatively than the significantly overhauled and recently-released R4 variant. “Regardless of its age,” Monk writes, “the Arduino UNO R3 continues to be my go-to board for any experimentation or early stage venture work that does not want a selected microcontroller.” And testing delivered a reward for that loyalty: a extremely linear studying from 0V as much as 5V, with minimal deviation within the samples.

“On wanting on the documentation in MicroPython and studying that the analog readings for a Pico and ESP32 come at a large 16 bit precision (a quantity between 0 and 65536),” Monk concludes, “it is simple suppose that their analog inputs are a lot better than the paltry 10 bits of an Arduino (0 to 1023 studying vary). However that is to confuse precision with accuracy. It is why pure megapixels isn’t the easiest way to evaluate a digicam. A lot is dependent upon the lens.”

The complete article is out there on Monk’s web site, together with the supply code used to check every microcontroller.

Related Articles

Latest Articles