Texas Instruments MSC1210 User Manual

Page 140

Advertising
background image

Input Multiplexer

12-4

The positive input channel and the negative input channel are selected in the
ADC Multiplexer register (ADMUX, SFR D7h). The high four bits of ADMUX
(bits 4 through 7) select the positive channel, while the low four bits (bits 0
through 3) select the negative channel. The ADMUX SFR has the following
definition:

7

6

5

4

3

2

1

0

Reset Value

SFR D7H

INP3

INP2

INP1

INP0

INN3

INN2

INN1

INN0

01H

INP3-0 (bits 7-4)—Input Multiplexer Positive Channel. This bit selects the
positive signal input.

INP3

INP2

INP1

INP0

Positive Input

0

0

0

0

AIN0 (default)

0

0

0

1

AIN1

0

0

1

0

AIN2

0

0

1

1

AIN3

0

1

0

0

AIN4

0

1

0

1

AIN5

0

1

1

0

AIN6

0

1

1

1

AIN7

1

0

0

0

AINCOM

1

1

1

1

Temperature Sensor (requires ADMUX = FF

H

)

INN3-0 (bits 3-0)—Input Multiplexer Negative Channel. This bit selects the
negative signal input.

INN3

INN2

INN1

INN0

Negative Input

0

0

0

0

AIN0

0

0

0

1

AIN1 (default)

0

0

1

0

AIN2

0

0

1

1

AIN3

0

1

0

0

AIN4

0

1

0

1

AIN5

0

1

1

0

AIN6

0

1

1

1

AIN7

1

0

0

0

AINCOM

1

1

1

1

Temperature Sensor (requires ADMUX = FF

H

)

Therefore, to select AIN1 as the positive channel and AIN6 as the negative
channel, the following assignment would be made to the ADMUX register:

ADMUX = 0x16h; // 0001=AIN1, 0110=AIN6

By default, ADMUX defaults to 01

H

at power up, so AIN0 is the default positive

input and AIN1 is the default negative input.

Advertising