How does a chip turn a smooth voltage into a number? It plays twenty questions. It guesses the top bit — ‘is the voltage above half?’ — keeps or drops it, then asks about the next bit, halving the uncertainty each step. In ten questions it pins a signal to one part in a thousand. Slide the voltage and watch the bits fall.
A successive-approximation-register (SAR) ADC digitises by BINARY SEARCH. Starting from the most significant bit, it adds each bit’s weight (Vref/2, /4, /8, …) to a trial voltage; if the trial stays below the input it keeps the bit, else drops it. After N steps the retained bits are the digital code and the trial equals the input to within one least-significant-bit (Vref/2ⁿ). A fail-loud self-check throws unless the 10-bit reconstruction lands within 1 LSB of the input voltage — the exact converter inside most microcontrollers.
An ideal binary-weighted DAC and comparator; real SAR ADCs fight capacitor mismatch, comparator noise, and settling time (and add calibration). The binary-search convergence to within 1 LSB is exact.