Professional Documents
Culture Documents
ก ก ก
14.1
14.1 ก กก
! "
ก# %$ & '( ) * "'"+ ' ) , '" ! -
!' . ก ก/ "0) " ก 1 ก2 3- - ก . ก "0
' ' 4 - - '"ก ) " "0% -) * ) "ก "0
)"ก ก ก) * (Analog to Digital conversion , A/D) %
- 'ก )', ' 4! - - "! - ) * $ 3- - ก . ก $ ก
F ก ก กG - . ก % -) * ก -
) * ก (Digital to Analog Conversion , D/A )
14.2 ก ก ) * ก
163
) + +ก ) * ก'" &")( Binary Weighted DAC R/2R
Ladder ก . &"'" )" "0
Vout = 0 ^
164
)( 3- Vref = +5V Vout )', [Z ) * b1c ' ! - -9.375 ^ ก . % -'" . 'ก
I0 - %(-+ ' - % 0I +. + Eout
14.5 DAC 8
165
14.7 Thevenin equivalent )[, Rth
3 Vth K Thevenin
". ' 3 Vth ! - "0
0 Vth = 46.875 mV, 1 Vth = 93.75 mV, 2 Vth = 0.1875 V, 3 Vth = 0.375 V,
4 Vth = 0.75 V, 5 Vth = 1.5 V, 6 Vth = 3V 7 Vth = 6V
14.2.3 กD ก DAC
Resolution
) * ") Gก " Z " D/A ' 3 - ! - "0 I0 $ก . D/A , +. ! -
ก
V
Vres = REF
n
2
A! K A ก
Analog Levels = 2 n
166
@@ D (Accuracy)
) * ก ) " ) " + ก + "+. ! - ก ก. ) * ) ^)_ ^ +) ^[Z )', ) G'
)ก (Full scale)
@ R (Speed)
' 3I + ') G Output settling time _I ) * ) " - %(-)[, - +) ^[Z )', [Z '"
ก ) "
ก U"!V !E DAC
DAC " " - % -+ ) ^[Z ก' '+ [Z )', [Z % -+ ' ก I0 ) ^[Z กG
- '"+ ' ก I0 ก )[' I0 [Z 0 กG - % -+ ) ^[Z )[' I0 % 0 ) ก -
3I ก 0 % ) * DAC กG'"ก 4 )["0 )( ก ก 4 )["0 % DAC '" 2 % +, Non-
linear distortion Non-monotonic distortion
Non-Linear Distortion:
ก/ ก 4 )["0 "0 % -+ ) ^[Z ) G !') ก
Non-Monotonic Distortion
ก/ ก 4 )["0 "0 % -+ ) ^[Z ) G !') ก + 0 % -+
) ^[Z 0 " [Z '"+ )[' I0
167
14.10 ก 4 [ Monotonic
\ ก @
V =V − V +ref −V ref−
+ X 10
V OUT = Output Voltage
2 V
OUT ref n
-
ref = VoltageReference-
V max −V min
V OUT = V min + X 10 n
2 −1 V +
ref = VoltageReference+
V min =Minimum output voltage
V +ref −V ref−
Re solution =
V max = Maximum outputvoltage
2 X
n
10 = Input value base10
V max −V min
Re solution = n n= .
2 −1
V OUT = V ref + X 10 Re solution
−
14.2.4 DAC0800
DAC 0800 ) * ' " . - ") * DAC '" [Z 8 % )- ^[Z ) * ก .
) * ' $ 4.11 G ก! ก' %$ $ " 14.12
168
14.11 ก/ 3 DAC0800
K @ 3 D
1 GND Ground
2 IOUTc Output
4. IOUT Outputc
5 B1 MSB Input
: : :
12 B8 LSB Input
14 VREF(+) Reference voltage for output
15 VREF(-) Reference voltage for output
169
D ก V E3F BV\ # !
D ก AT89C2051 ก DAC0800
170
0" - 3$ก % )- * - ก) * , "
)"ก ADC ก "0 I ! )- * !JJK " $% $ "[ - ' .! ' 4
% ! -
ก ก) * 0 '" $ &" )(
ก) * ก %(- Analog comparator ' $ " 14.16 _I % -) ^[Z
ก' 1 ก ก "0 '" &" , "ก)(
- Digital Ramp ADC (Counter method)
- Successive Approximation
- Parallel Comparator (1Flash2)
- Dual Slope
14.16 ก/ ADC 1
171
14.3.1 Digital Ramp ADC (Counter method)
172
G ก! ก ' &" "0 $% $ " 14.18 '"ก . "0
1) )', ) ' % - START = 0 ) * ก ")_G Control logic Control
Register % -) * 0 Zก [ - ' 0 ก. . " - )_G , ")_G ) * " 7
ก "0 START - ) * 1 )[, ) ' ก .
2) + ก 3$ก % -) * + ก Vax DAC
3) + Vax 3$ก . ! ) " ) " ก + [Z Va ) " ) " (Comparator)
3- Va > Vax ) ^[Z ) " ) " ) * 1 EOC = 1 )',
Clock ) - ' Control logic )_G " Z% -) * 1 [ - ' 0 ) , ก Z ' 1
. -ก ! ) " ) " % '
3- Va < Vax ) ^[Z EOC = 1 )', Clock ) - ' Control logic ")_G
" Z% -) * 0 [ - ' 0 ) , ก Z ' 1 . -ก !
) " ) " % '
ก . $% - 3 "0 ก . + Zก (% " "0'" 8 ) , Va = Vax
) ^[Z EOC ) ก 0 Z . ) * ก ) G 0 ก .
&"ก "0% -+ ') G ' กก ก "ก 0 + กG3$ก I ) * &" " '%(-ก ' ก
173
- ก ADC 2 '" . 4 ) G _I '" - 8 ^ 0 )G 0 ^2 ^
4 ^ 6 ^ 0 - %(- ) " ) " 3 ' $ " 14.20 0 )', K [Z
)( 5 V ) - ' ) " ) " 0 3 .ก ) " ) " ก - ! -) ^[Z
) * 011 )- I % -) [^ Z ) * ! " 10 ' $ " 14.20
14.3.4 ADC c
ก ก "! -ก ' - '"ADC , "ก)( ADC "%(-% ก (Joystick)
++ '[ ) ^ Apple II '" $ '$ " 14.21 . Threshold Detector %(- Op-amp "
%(- - " inverting ) * 2.5 ^ , %(- 74LS14 , 74HCT14 กG! - .
กก. - Potentiometer _I ) * + ' - " + ! - กก . %(-ก + RC
time constant ")ก กก Z% -ก C 1 µF 0 "0ก ( ^ ( ^ Z "0 -
ก ' !' + )_ )_ ^
174
14.3.5 KF ก 3 !K ADC
Resolution
) ', ก % DAC ) * ก. + + '4 [ ก quantizing _I ) * ก 4 [ ก
+ " -
Accuracy
) ', ก % DAC ) * ก + "3$ก - )', ) " ก + " - ก + "ก. ! -
Conversion Time
) "%(-% ก
Sampling Rate
+ '3" ก )( 3- ) * 44 kHz กG ' 3I ก )ก I0 Zก
22.7 µS
14.23 ก/ ก Z'
175
14.3.6 ADC0804 8-Bit µP Compatible A/D Converters
176
14.3.7 ADC K ! 10 " K T89C51AC2
T89C51AC2 '" ADC 10 F$ % '"+Z ' ) "0
[Z ! - 8 ( ' )[ ก_^
) * ADC 10
) % ก 20 µS
%(- - +2.4 3I +3 ^
[Z ! - 0 0 3I 3 ^
' 3 ) ^ [ ^_"[" $! -
ก. + '3" Šก ! -
Integral non-linearity ! 1 LSB $ Z !')ก 2 LSB
Differential non-linearity ! 0.5 LSB $ Z !')ก 1 LSB
ADA E ก
%(-) % ก 11 Šก ) setup !' - ก 4 µS '"! ก'
) ก ' $ " 14.27
177
14.27 ! ก 'ก . ADC T89C51AC2
" B กD KF
ADCF (ADC Configuration Register) %(-ก. - " [ ^ P1
178
ADCON (ADC Control Register) %(-ก. ก . ) * 3 ก .
ADDH A ADDL (ADC Data high byte and low byte register) ) * + " ! -
179
D ก @ @\ ADC
3- - ก % - ADC ' 3 ) ^ [ ^! - - % - EA = 1 -
180
A " B V BK T89C51AC2
14.33 ) ^[ ^ T89C51AC2
A! @ @ K " BV B
ก ก 3 !@ @ @ K ก " BV B
! @ @ K " BV B cK T89C51AC2
181