Understanding ADC Resolution and How to Calculate It
ADC resolution determines how precisely an analogue signal is digitised. Learn how bit depth, reference voltage, and LSB size affect accuracy — with worked examples and chip comparisons.
What Is an ADC?
An Analogue-to-Digital Converter (ADC) translates a continuous analogue voltage into a discrete digital number that a microcontroller or processor can work with. Every time your Arduino reads a sensor, a temperature chip reports a value, or a soundcard records audio, an ADC is doing the conversion.
The fundamental question is: how accurately does the digital number represent the original voltage? The answer comes down to resolution.
ADC Resolution: Bits and Steps
Resolution is expressed in bits. An n-bit ADC divides its input voltage range into 2ⁿ discrete steps. The more bits, the finer the divisions:
| Bit depth | Steps (2ⁿ) | Typical use |
|---|---|---|
| 8-bit | 256 | Basic sensors, PWM generation |
| 10-bit | 1024 | Arduino Uno (built-in ADC) |
| 12-bit | 4096 | STM32, ESP32, most modern MCUs |
| 16-bit | 65,536 | Audio, precision measurement |
| 24-bit | 16,777,216 | Lab instruments, audio DACs |
A 10-bit ADC maps the full input voltage range to 1024 possible output codes (0–1023). A 12-bit ADC maps the same range to 4096 codes — four times finer.
Reference Voltage (Vref)
The reference voltage (Vref) defines the full-scale input range of the ADC. The converter treats any input at Vref as its maximum code (e.g., 1023 for 10-bit) and 0V as code 0.
Common Vref values:
- 3.3V — used with 3.3V logic microcontrollers (STM32, RP2040, ESP32 at 3.3V)
- 5V — used with 5V logic microcontrollers (Arduino Uno, ATmega328P)
- 4.096V — chosen deliberately so each LSB equals exactly 1mV (for 12-bit ADCs)
- External precision reference — used in lab-grade applications for accuracy
If your signal exceeds Vref, the ADC will saturate at the maximum code. If your signal is much less than Vref, you waste resolution. Matching Vref to the expected signal range is an important design decision.
The LSB: Smallest Measurable Step
The Least Significant Bit (LSB) value is the voltage represented by a single code increment — the smallest change the ADC can detect:
LSB = Vref / 2ⁿ
Worked example: Arduino Uno
The Arduino Uno uses a 10-bit ADC with a 5V reference:
LSB = 5V / 2¹⁰ = 5 / 1024 ≈ 4.88 mV
Any voltage change smaller than 4.88mV is invisible to the ADC — it won't register as a different code.
Worked example: 12-bit ADC with 3.3V reference
LSB = 3.3V / 2¹² = 3.3 / 4096 ≈ 0.806 mV
Much finer resolution than the Arduino — useful for reading sensors that produce small voltage swings.
Converting a Digital Code Back to Voltage
Once you have the raw ADC code, you convert it back to a voltage using:
Voltage = Code × (Vref / 2ⁿ)
= Code × LSB
Example: An Arduino reads a code of 512 with Vref = 5V:
Voltage = 512 × (5 / 1024) = 512 × 4.88mV ≈ 2.5V
This is exactly half the reference voltage — which makes sense for code 512 on a 10-bit ADC.
Effective Number of Bits (ENOB)
Theoretical resolution and real-world performance are not the same. Noise, non-linearity, and offset errors reduce the effective resolution. The Effective Number of Bits (ENOB) quantifies this:
ENOB = (SINAD − 1.76) / 6.02
Where SINAD is the signal-to-noise-and-distortion ratio in dB, typically found in the ADC datasheet. A "12-bit" ADC might have an ENOB of 10.5 bits at high frequencies.
For most hobbyist applications, ENOB isn't critical. For precision measurement or audio, always check the datasheet SINAD figure rather than trusting the headline bit count.
Voltage Divider Pre-Conditioning
If your signal range doesn't match Vref, a voltage divider can scale it down before the ADC input. For example, if you want to measure a 0–12V signal with a 3.3V ADC:
Divider ratio = Vout / Vin = 3.3 / 12 = 0.275
Using R1 = 27kΩ and R2 = 10kΩ:
Vout = Vin × (R2 / (R1 + R2)) = Vin × (10 / 37) ≈ Vin × 0.270
The scaling factor slightly reduces resolution, but it protects the ADC from overvoltage and brings the signal into the measurable range.
Common ADC Chips and Resolutions
| Chip | Bits | Interface | Notes |
|---|---|---|---|
| MCP3204 | 12-bit | SPI | Popular 4-channel ADC for Arduino |
| ADS1115 | 16-bit | I²C | Texas Instruments, built-in PGA |
| MCP3421 | 18-bit | I²C | Very high resolution, slow |
| AD7124 | 24-bit | SPI | Lab-grade, sigma-delta |
| Built-in (ATmega328P) | 10-bit | Internal | Used in Arduino Uno/Nano |
| Built-in (STM32F4) | 12-bit | Internal | Up to 3 independent ADCs |
Practical Tips for Better ADC Accuracy
- Decouple the power rail — add a 100nF ceramic capacitor between AVCC and GND close to the ADC pin.
- Use an external voltage reference — onboard MCU references can drift with temperature; use a precision external reference (e.g., REF3033) for critical measurements.
- Average multiple samples — take 4–16 readings and average them to reduce noise by a factor of √N.
- Keep analogue and digital grounds separate where possible, joining them at a single point.
- Route analogue input traces away from high-frequency digital signals to minimise coupled noise.
Use the ADC Calculator
The ADC Calculator on DevGizmo lets you enter bit depth, reference voltage, and output code to instantly calculate LSB size, step count, and the corresponding voltage. It also includes presets for common chips like the Arduino Uno ADC, ADS1115, and MCP3204.
Related Reading
- DAC Explained: Converting Digital Values to Voltage — the reverse process: turning digital codes back into analogue voltages
- Voltage Divider Circuits Explained — pre-conditioning analogue signals to fit within Vref before sampling