EmbeddedEra EmbeddedEra

‹ Tools · ADC resolution

ADC resolution calculator

Vref and the bit width give the size of one count. Add an input divider and it also tells you the largest voltage the divider can present without exceeding Vref.

Accepts 4k7, 4.7k, 10µ, 2R2.

ADC resolution Live
LSB size — — — —
LSB = Vref / 2^bits embeddedera.com/tools

Need the divider itself? ›

The formula

LSB = Vref / 2^bits Code = round(Vin / LSB) Vin = Code · LSB

When to use it

Picking a bit width, sizing a battery-monitor divider so full charge stays under Vref, or converting a raw ADC code you read off a register. Works for an external ADC or any microcontroller’s internal one — only Vref and the bit count matter.

Pitfalls

  • Resolution is not accuracy. A 16-bit ADC with a noisy or drifting reference can be worse than a clean 12-bit one — the LSB size says nothing about the reference’s own error.
  • The full-scale code is one LSB below Vref, never equal to it: a 12-bit ADC at 3.3 V tops out at 4095 counts, which is 3.2992 V, not 3.3 V.
  • With a divider, the ADC sees Vin reduced by the ratio, not Vin itself — feed the result back through the divider’s own tolerance before trusting the last bit.
  • Effective resolution is usually worse than the datasheet’s number of bits once board noise is included; a 16-bit converter often delivers 12 to 14 clean bits on a real board.

Need the whole analog front end designed, not just the ADC pin?