If instead ADCINA1 needed to be oversampled by 3X, then SOC1, SOC2, and SOC3 could all be given the
same configuration as SOC0.
ADCSOC1CTL = 4846h;
// (ACQPS=6, CHSEL=1, TRIGSEL=9)
ADCSOC2CTL = 4846h;
// (ACQPS=6, CHSEL=1, TRIGSEL=9)
ADCSOC3CTL = 4846h;
// (ACQPS=6, CHSEL=1, TRIGSEL=9)
When configured as such, four conversions of ADCINA1 will be started in series on an ePWM3 SOCA event with
the resulting values stored in the ADCRESULT0 – ADCRESULT3 registers.
Another application may require 3 different signals to be sampled from the same trigger. This can be done by
simply changing the CHSEL field for SOC0-SOC2 while leaving the TRIGSEL field unchanged.
ADCSOC0CTL = 4846h;
// (ACQPS=6,
CHSEL=1,
TRIGSEL=9)
ADCSOC1CTL = 4886h;
// (ACQPS=6,
CHSEL=2,
TRIGSEL=9)
ADCSOC2CTL = 48C6h;
// (ACQPS=6,
CHSEL=3,
TRIGSEL=9)
When configured this way, three conversions will be started in series on an ePWM3 SOCA event. The result of
the conversion on channel ADCINA1 will show up in ADCRESULT0. The result of the conversion on channel
ADCINA2 will show up in ADCRESULT1. The result of the conversion on channel ADCINA3 will show up in
ADCRESULT2. The channel converted and the trigger have no bearing on where the result of the conversion
shows up. The RESULT register is associated with the SOC.
Note
These examples are incomplete. Clocks must be enabled via the PCLKCR0 register and the ADC
must be powered to work correctly. For a description of the PCLKCR0 register, see the
System
Control and Interrupts
chapter. For the power-up sequence of the ADC, see
. The
CLKDIV2EN bit in the ADCCTL2 register must also be set to a proper value to obtain correct
frequency of operation. For more information on the ADCCTL2 register, refer to
8.2.1 ADC Acquisition (Sample and Hold) Window
External drivers vary in their ability to drive an analog signal quickly and effectively. Some circuits require longer
times to properly transfer the charge into the sampling capacitor of an ADC. To address this, the ADC supports
control over the sample window length for each individual SOC configuration. Each ADCSOCxCTL register has
a 6-bit field, ACQPS, that determines the sample and hold (S+H) window size. The value written to this field is
one less than the number of cycles desired for the sampling window for that SOC. Thus, a value of 15 in this
field will give 16 clock cycles of sample time. The minimum number of sample cycles allowed is 7 (ACQPS=6).
The total sampling time is found by adding the sample window size to the conversion time of the ADC, 13 ADC
clocks. Examples of various sample times are shown in
Table 8-1. Sample Timings with Different Values of ACQPS
SYSCLKOUT
ADC Clock
ACQPS
Sample Window
Conversion Time
(13 cycles)
Total Time to Process
Analog Voltage
90 MHz
45 MHz
6
155.56 ns
288.89 ns
444.44 ns
90 MHz
45 MHz
25
577.78 ns
288.89 ns
866.67 ns
(1)
The total times are for a single conversion and do not include pipelining effects that increase the average speed over time.
, the ADCIN pins can be modeled as an RC circuit. With VREFLO connected to ground, a
voltage swing from 0 to 3.3 V on ADCIN yields a typical RC time constant of 2 ns.
Analog-to-Digital Converter (ADC)
514
TMS320x2806x Microcontrollers
SPRUH18I – JANUARY 2011 – REVISED JUNE 2022
Copyright © 2022 Texas Instruments Incorporated
Содержание TMS320 2806 Series
Страница 2: ......