Programming The A/D Command Register - Intel 8XC196MC User Manual

Table of Contents

Advertisement

AD_TIME
The A/D time (AD_TIME) register programs the sample window time and the conversion time for each
bit. This register programs the speed at which the A/D can run — not the speed at which it can convert
correctly. Consult the data sheet for recommended values. Initialize the AD_TIME register before
initializing the AD_COMMAND register. Do not write to this register while a conversion is in progress;
the results are unpredictable.
7
SAM2
SAM1
Bit
Bit
Number
Mnemonic
7:5
SAM2:0
4:0
CONV4:0

12.4.4 Programming the A/D Command Register

The A/D command register controls the operating mode, the analog input channel, and the con-
version trigger.
SAM0
CONV4
A/D Sample Time
These bits specify the sample time. Use the following formula to
compute the sample time.
×
T
F
SAM
XTAL1
------------------------------------------------ -
SAM
=
8
where:
SAM = 1 to 7
= the sample time, in µsec, from the data sheet
T
SAM
F
= the input frequency on XTAL1, in MHz
1
XTAL
A/D Convert Time
These bits specify the conversion time for each bit. Use the following
formula to compute the conversion time.
×
T
CO NV
--------------------------------------------------- -
CO NV
=
2 B
where:
CONV = 2 to 31
= the conversion time, in µsec, from the data sheet
T
CONV
F
= the input frequency on XTAL1, in MHz
1
XTAL
B
= the number of bits to be converted (8 or 10)
Figure 12-4. A/D Time (AD_TIME) Register
Get other manuals https://www.bkmanuals.com
ANALOG-TO-DIGITAL (A/D) CONVERTER
CONV3
CONV2
Function
2
F
3
XTAL1
1
×
Address:
1FAFH
Reset State:
FFH
0
CONV1
CONV0
12-7

Advertisement

Table of Contents
loading

This manual is also suitable for:

8xc196md8xc196mh

Table of Contents