beautypg.com

Texas Instruments MSP430x1xx User Manual

Page 324

background image

ADC12 Control Registers

15-34

ADC12SSEL

bits
3–4

Select the clock source for the converter core

0:

ADC12 internal oscillator, ADC12OSC

1:

ACLK

2:

MCLK

3:

SMCLK

ADC12DIV

bits
5–7

Select the division rate for the clock source selected by ADC12SSEL bits.

0 to 7: Divide selected clock source by 1 to 8
The divider’s output signal name is ADC12CLK. Thirteen of these clocks are
required for a conversion.

ISSH

bit8

Invert sample-input signal.

0:

The sample-input signal is not inverted.

1:

The sample-input signal is inverted.

SHP

bit9

The SHP bit selects the source of the sampling signal (SAMPCON) to be
either the output of the sampling timer or the sample-input signal directly.

0:

SAMPCOM signal is sourced directly from the sample-input signal.

1:

SAMPCON signal is sourced from the sampling timer. The rising edge
of the sample-input signal triggers the sampling timer.

SHS

bits
10–11

Source select for the sample-input signal.

0:

Control bit ADC12SC is selected.

1:

Timer_A.OUT1

2:

Timer_B.OUT0

3:

Timer_B.OUT1

CStartAdd

bits
12–15

Conversion start address CStartAdd is used to define which ADC12
conversion-memory register (ADC12MEMx) is used for a single conversion
or for the first conversion in a sequence of conversions. The value of
CStartAdd is 0 to 0Fh, corresponding to ADC12MEM0 to ADC12MEM15.
Since there is one corresponding conversion-memory control register
(ADC12MCTLx) for each conversion-memory register (ADC12MEMx),
CStartAdd also points to the corresponding ADC12MCTLx register.

Warning : Modifying ADC control register during active conversion

The enable conversion control bit (ENC) in the ADC12CTL0 register
protects most bits from modification during an active conversion.
However, some bits that are necessary for proper completion of
active conversions and interrupt enable bits can be modified
independently of ENC. The user must use caution when modifying
theses bits to ensure an active conversion is not corrupted, or to
not use corrupted data.

To avoid corrupting any active conversions, stop the conversion,
wait for the busy bit to be reset, reset the ENC bit, then modify the
control bits.