Utilities Web

ADC Resolution, LSB, and Voltage Calculator

Calculate LSB voltage, quantization error, dynamic range, code↔voltage conversion, ENOB, and oversampling from resolution and reference voltage

How to Use

  1. Choose a device preset (Arduino / ESP32 / STM32 / 16bit) or enter resolution (bit) and reference voltage Vref
  2. Select LSB convention (2^N Standard / 2^N−1 Endpoint)
  3. 1LSB voltage, code count, quantization error, dynamic range, and ideal SNR are displayed
  4. Enter code or voltage and the other is calculated bidirectionally
  5. Compare LSB values for different bit depths at the same Vref in the resolution comparison table
  6. Enter SINAD to calculate ENOB (effective resolution), or enter extra bits to calculate the required oversampling ratio

Use Cases

  • When you want to know what 1LSB is in mV/µV from resolution and reference voltage
  • When you want to convert ADC readings (code) to voltage or voltage to code
  • When you want to confirm whether to divide by 1024 or 1023 when converting Arduino's analogRead to voltage
  • When you want to calculate effective resolution (ENOB) from SINAD in a datasheet
  • When you want to know how many times oversampling you need to gain a certain number of resolution bits

Frequently Asked Questions

When converting analogRead to voltage, do you divide by 1024 or 1023? ▼

Both are used. 1024 (=2^N) is faithful to the ADC transfer function, with each code representing a bin of width Vref/1024 (a reading of 1023 is 4.9951V, not exactly 5V). 1023 (=2^N−1) provides a linear mapping of 0〜Vref, where a reading of 1023 is exactly 5V. Most precisely, divide by 1024 and add an offset of +0.5LSB. You can check both results using the convention toggle in this tool.

What is the relationship between LSB, quantization error, and dynamic range? ▼

1 LSB = Vref ÷ 2^N is the voltage per code, and quantization error is ±0.5 LSB. Dynamic range is 6.02·N dB (the ratio of full scale to 1LSB), and ideal SNR for a full-scale sine wave is 6.02·N + 1.76 dB. When you increase N by 1 bit, LSB halves and dynamic range improves by about 6dB. LSB varies with Vref and convention, but dynamic range/SNR is determined only by N.

How much can resolution be improved with oversampling? ▼

To improve resolution by w bits, accumulate 4^w times as many samples and divide by 2^w (decimation). For example, to make 12-bit equivalent to 14-bit requires 4^2 = 16 times oversampling. However, this assumes the input has random noise of at least 1LSB (or dithering if needed); if noise is too small, the effect won't work. Effective resolution = N + w, effective LSB = Vref ÷ 2^(N+w).

Related Tools