Embedded Systems & Firmware

A 12-bit A/D converter with a 3.3 V reference reads a value of 2048. What is the closest input voltage?

  1. AAbout 2.05 V
  2. BAbout 3.3 V
  3. CAbout 1.65 V
Show answer and explanation

Answer: C. About 1.65 V

A 12-bit A/D converter represents 0 to 3.3 V in 4096 steps. A reading of 2048 is exactly half, so the voltage is 2048 ÷ 4096 × 3.3 V = 1.65 V, with each step about 0.8 mV. Firmware converts readings with "value × reference ÷ 4096", but any error in the reference voltage carries straight into the result, so the reference accuracy matters when precision is needed.

  • A. That reads the value as millivolts.
  • B. 3.3 V would read about 4095.
  • C. Correct. Exactly half of the 4096 steps.
Practice this topic Back to topic

More Embedded Systems & Firmware questions

  1. When a microcontroller captures many A/D conversion results at regular intervals, what is the advantage of using DMA?
  2. When representing peripheral registers with C bit-field structs, what needs care?
  3. On many microcontrollers, what is the advantage of declaring a large table that never changes (such as font data) as const?
  4. What can be done through debug interfaces such as JTAG and SWD?
  5. You want to run a control calculation every 1 ms on a microcontroller without an OS. Which implementation is most suitable?