12.07.2015 Views

ATmega32A Datasheet - Sunrom Technologies

ATmega32A Datasheet - Sunrom Technologies

ATmega32A Datasheet - Sunrom Technologies

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>ATmega32A</strong>If the ADC is not to be used during scan, the recommended input values from Table 24-5 shouldbe used. The user is recommended not to use the Differential Gain stages during scan. Switchcapbased gain stages require fast operation and accurate timing which is difficult to obtainwhen used in a scan chain. Details concerning operations of the differential gain stage is thereforenot provided.The AVR ADC is based on the analog circuitry shown in Figure 24-10 with a successive approximationalgorithm implemented in the digital logic. When used in Boundary-scan, the problem isusually to ensure that an applied analog voltage is measured within some limits. This can easilybe done without running a successive approximation algorithm: apply the lower limit on the digitalDAC[9:0] lines, make sure the output from the comparator is low, then apply the upper limiton the digital DAC[9:0] lines, and verify the output from the comparator to be high.The ADC need not be used for pure connectivity testing, since all analog inputs are shared witha digital port pin as well.When using the ADC, remember the following:• The Port Pin for the ADC channel in use must be configured to be an input with pull-updisabled to avoid signal contention.• In Normal mode, a dummy conversion (consisting of 10 comparisons) is performed whenenabling the ADC. The user is advised to wait at least 200 ns after enabling the ADC beforecontrolling/observing any ADC signal, or perform a dummy conversion before using the firstresult.• The DAC values must be stable at the midpoint value 0x200 when having the HOLD signallow (Sample mode).As an example, consider the task of verifying a 1.5V ±5% input signal at ADC channel 3 whenthe power supply is 5.0V and AREF is externally connected to V CC .The lower limit is: 1024 ⋅ 1.5V ⋅0,95 ⁄ 5V = 291 = 0x123The upper limit is: 1024 ⋅ 1.5V ⋅1.05 ⁄ 5V = 323 = 0x143The recommended values from Table 24-5 are used unless other values are given in the algorithmin Table 24-6. Only the DAC and Port Pin values of the Scan-chain are shown. The column“Actions” describes what JTAG instruction to be used before filling the Boundary-scan Registerwith the succeeding columns. The verification should be done on the data scanned out whenscanning in the data on the same row in the table.8155C–AVR–02/11246

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!