Skip to main content

Embedded Systems · Microcontrollers, memory-mapped I/O, and peripherals

A 12-bit ADC with V_REF=3.300 V and V_LSB=V_REF/4096 is read sixteen times in…

Problem

Embedded Systems practice problem

A 12-bit ADC with VREF=3.300 VV_{\mathrm{REF}}=3.300\,\mathrm{V} and VLSB=VREF/4096V_{\mathrm{LSB}}=V_{\mathrm{REF}}/4096 is read sixteen times in succession on a DC input. The sixteen right-aligned codes, in the order taken, are1550155315491552155115541550155215511553154815521551155015531551.\begin{array}{cccccccc} 1550 & 1553 & 1549 & 1552 & 1551 & 1554 & 1550 & 1552\\ 1551 & 1553 & 1548 & 1552 & 1551 & 1550 & 1553 & 1551. \end{array}Software oversampling forms the integer sum SS of the sixteen codes and the 14-bit resultN14=⌊S/4⌋.N_{14}=\bigl\lfloor S/4\bigr\rfloor.The reconstructed oversampled voltage is v^14=N14⋅VLSB/4\hat{v}_{14}=N_{14}\cdot V_{\mathrm{LSB}}/4. The arithmetic mean of the sixteen reconstructed 12-bit voltages is vˉ=(S/16)VLSB\bar{v}=(S/16)V_{\mathrm{LSB}}. Ignore missing codes.

(a) Compute SS, N14N_{14}, v^14\hat{v}_{14}, and vˉ\bar{v}. Report voltages in millivolts.

(b) Compute the unique 12-bit code NmedN_{\mathrm{med}} obtained by sorting the sixteen samples and averaging the eighth and ninth in the ordered list (use the arithmetic mean, which may be a half-integer), and the corresponding voltage NmedVLSBN_{\mathrm{med}}V_{\mathrm{LSB}}.

(c) Determine the sample standard deviation of the sixteen codes using the divisor 1515, and convert that standard deviation to millivolts. Then compute the standard error of the mean s/16s/\sqrt{16} in millivolts.

(d) A second routine reports v^′=N14⋅VREF/16384\hat{v}'=N_{14}\cdot V_{\mathrm{REF}}/16384. Decide whether v^′=v^14\hat{v}'=\hat{v}_{14} for every integer N14N_{14}, and evaluate both reconstructions on the N14N_{14} of part (a).

Hint

Hint

Oversampling here is an integer sum followed by a power-of-two shift, not a floating-point average. The median of sixteen sorted samples sits between positions eight and nine.

Check your work

Work the problem yourself first. Then open it in Training to check your answer and read the full worked solution.

Create a free account to check your answer and see the solution. Create a free account.

More Embedded Systems practice problems

Back to Embedded Systems

An original ProofAnvil practice problem, written for this course. ProofAnvil is a practice course, not a homework-answer service.