Successive-approximation ADC: Difference between revisions

Content deleted Content added
Inaccuracies in non-ideal analog circuits: add citated limit to SAR as 18-bits as of 2012, according to Analog Devices article, and mention delta-sigma as able to go higher.
m Algorithm: I renamed "s" to "sgn" but forgot to rename it here too.
Line 15:
The successive-approximation register is initialized with 1 in the [[most significant bit]] (MSB) and zeroes in the lower bits. The register's code is fed into the DAC, which provides an analog equivalent of its digital code (initially {{math|1={{sfrac|1|2}}''V''<sub>ref</sub>}}) to the comparator for comparison with the sampled input voltage. If this analog voltage exceeds {{math|''V''<sub>in</sub>}}, then the comparator causes the SAR to reset this bit; otherwise, the bit is left as 1. Then the next bit is set to 1 and the same test is done, continuing this [[Binary search algorithm|binary search]] until every bit in the SAR has been tested. The resulting code is the digital approximated output of the sampled input voltage.
 
The algorithm's objective for the {{math|''n''<sup>th</sup>}} iteration is to approximately digitize the input voltage to an accuracy of {{frac|1|2<sup>''n''</sup>}} relative to the reference voltage. To show this mathematically, the normalized input voltage is represented as {{math|''x''}} in {{math|[−1,&nbsp;1]}} by letting {{math|1=''V''<sub>in</sub> = ''xV''<sub>ref</sub>}}. The algorithm starts with an initial approximation of {{math|1=''x''<sub>0</sub> = 0}} and during each iteration {{math|''i''}} produces the following approximation:<blockquote>{{math|''i''<sup>th</sup>}} approximation: {{math|1=''x''<sub>''i''</sub> = ''x''<sub>''i''−1</sub> − {{sfrac|''sgn''(''x''<sub>''i''−1</sub> − ''x'')|2<sup>''i''</sup>}}}}</blockquote>where the binary [[signum function]] {{math|''sgn''}} mathematically represents the comparison of the previous iteration's approximation {{math|1=''x''<sub>i-1</sub>}} with the normalized input voltage {{math|''x''}}:<math display="block"> ssgn(x_{i-1} - x) = \begin{cases}
+1 & \text{if } x_{i-1} \geq x, \\
-1 & \text{if } x_{i-1} < x. \end{cases}</math>It follows using mathematical induction that the approximation of the {{math|''n''<sup>th</sup>}} iteration theoretically has a bounded accuracy of: {{math|{{!}}''x''<sub>''n''</sub> − ''x''{{!}} ≤ {{sfrac|1|2<sup>''n''</sup>}}}}.