Ch"ơng 14 Phối phép 8031/51 với bộ nhớ ngoài 14.1 Bộ nhớ bán dẫn. !"#$% &'($ $)* +, $'- ./ 010 2345 6#73 89 $'- 81$ :;$ 2'10 $',5 .) 010 <=0 +>$' 0?, 0'@$% $'A :B$% 6AC$%D +E 0'F0 .) +'G3 %3,$ +"5* 0H&I !"#$% +'3J+ 2J 0?, +K+ 0L 010 'M +'N$% :O, +"P$ 89 .3 QR 6S +'T 010 89 $'- 81$ :;$ <AC0 :U$% $'A 'V3 6A5 %3W 0'AV$% +"T$' .) :W 63M5 0'>$'I X10 89 $'- 81$ :;$ <AC0 $N3 +"O0 +3J& 3 XYZ .) 0'@$% 6) 89 $'- [) XYZ <(5 +3P$ '\3 ./ +']$% +3$ 0'AV$% +"T$' .) :W 63M5I ^T 6S :# $)* [) 010 89 $'- $'3/5 2'3 <AC0 0#3 $'A 6) $_ &'L3 <1& F$% $',$' 0'# XYZ [) 010 <3/5 $)* 0'` 0_ 010 89 $'- 81$ :;$ [-3 0_ +'4 6)[ <AC0I X10 89 $'- 81$ :;$ <AC0 QR :B$% "9$% "a3 $'K+ 6) bcd .) bedI !"A-0 2'3 <3 .)# 8)$ 010 2345 89 $'- bcd .) bed 0'@$% +, 6)[ f5g$ 3 [9+ QN +'5H+ $%W f5,$ +"h$% 0'5$% 0'# +K+ 0L [h3 89 $'- 81$ :;$ $'A 6) :5$% 6AC$%D +E 0'F0 .) +N0 <9I 14.1.1 Dung l"ợng nhớ. iN 6AC$% 010 8>+ [) [9+ 0'>& $'- 81$ :;$ 0_ +'4 6A5 <AC0 %h3 6) :5$% 6AC$% 0?, 0'>&D $_ 0_ <V$ .j 0_ +'4 6) 23k6]k8>+ lm8>+nD [Pk%,k83+ ld8>+n .I.o p3/5 $)* &'L3 &'q$ 83J+ 3 :5$% 6AC$% 6A5 +"W 0?, 'M +'N$% [1* +>$'I !"#$% 2'3 :5$% 6AC$% $'- 0?, [9+ rX $'- 65]$ <AC0 +>$' +'g# 8>+D 0s$ :5$% 6AC$% $'- 0?, [9+ 'M +'N$% [1* +>$' 65]$ <AC0 0'# +>$' 8*+gI X't$% '7$D +"P$ +7& 0'> 2u +'5H+ 0_ [9+ 8)3 81# $_3 "v$% 0'>& wxd <a +"y $P$ &'E :B$% +'T [=0 :U $_ 2']$% $_3 "v$% wxd $%'z, 6) wx [Pk%,k83+ +'T $_ .;$ <AC0 '345 6) 8)3 81# $_3 ./ 0'>& rX $'-I !5* $'3P$D $J5 [9+ f5L$% 01# $_3 "v$% [9+ [1* +>$' 3 89 $'- wxd .T $_ <,$% $_3 ./ 'M +'N$% [1* +>$' $P$ $_ <AC0 '345 wxd 0_ $%'z, 6) wx [Pk%,k8*+gI 14.1.2 Tổ chức bộ nhớ. X10 0'>& <AC0 +E 0'F0 .)# [9+ QN $%{$ $'- 8P$ +"#$% [70' +>0' 'C& rXI d|3 $%{$ $'- 0_ 0'F, 89 8>+D } 8>+D ~ 8>+ +'H[ 0'> <J$ wx 8>+ &'B +'590 .)# 010' $_ <AC0 +'3J+ 2J 8P$ +"#$% $'A +'J $)# iN 8>+ [) [|3 $%{$ $'- 8P$ +"#$% 0'>& $'- 0_ +'4 0'F, <AC0 65]$ 8v$% QN 0'q$ :W 63M5 +"P$ 0'>&I ^H* 0_ 8,# $'3P5 $%{$ $'- 8P$ +"#$% [9+ 0'>& $'- N_ &'B +'590 .)# QN 0'q$ <j, 0'`D QN $%{$ $'- 8P$ +"#$% [9+ rX $'- 65]$ 8v$% 2 65u +'ừ, 3 QN 0'q$ <j, 0'`I D# .H*D +E$% QN 8>+ [) rX $'- 0_ +'4 6A5 +"W 6) 8v$% QN $%{$ $'- $'q$ 3 8>+ :W 63M5 +"P$ [|3 $%{$ $'-I X_ +'4 +_[ +ắ+ 673 $'A Q,5: wI d9+ 0'>& $'- 0_ +'4 0'F, 2 x $%{$ $'-D 3 x 6) QN 0'q$ <j, 0'`I 2I d|3 $%{$ $'- 0'F, * 8>+ 3 * 6) QN 0'q$ :W 63M5 +"P$ 0'>&I 3I !#)$ 89 0'>& 0'F, l2 x *n8>+ 3 x 6) QN 0'q$ <j, 0'` .) * 6) QN 0'q$ :W 63M5 +"P$ 0'>&I 14.1.3 Tốc độ. d9+ +"#$% $'W$% <=0 +>$' f5,$ +"h$% $'K+ 0?, 0'>& $'- 6) +N0 <9 +"5* 0H& :W 63M5 0?, $_I p4 +"5* 0H& :W 63M5 +'T <j, 0'` &'L3 0_ y 010 0'q$ <j, 0'`,D 0'q$ <h0 bEeD <AC0 +>0' 0O0 .) Q,5 [9+ 2'#L$% +'G3 %3,$ +'T :W 63M5 Qẽ x5K+ '3M$ y 010 0'q$ :W 63M5I m'#L$% +'G3 %3,$ $)* 0)$% $%ắ$ 0)$% +N+ .) +K+ $'3P$ 6) 0'>& $'- 0)$% <ắ+I !N0 <9 0?, 0'>& $'- +'AG$% <AC0 0#3 $'A 6) +'G3 %3,$ +"5* 0H& 0?, $_I !'G3 %3,$ +"5* 0H& 0?, 010 0'>& $'- +',* <E3 +ừ .)3 $,k$]k%3q* <J$ ')$% +"{[ $,k$]k%3q* &'B +'590 .)# 0]$% $%'M QR :B$% +"#$% f51 +"T$' +'3J+ 2J .) QL$ x5K+ rXI XL 8, <=0 +>$' f5,$ +"h$% 0?, 89 $'- 6) :5$% 6AC$% $'-D +E 0'F0 89 $'- .) +'G3 %3,$ +"5* 0H& Qẽ <AC0 QR :B$% $'3/5 +"#$% 0'AV$% +"T$'I BL$% w}Iw $'A [9+ +',[ 0'3J5 <4 +>$' +#1$ 010 <=0 +>$' 0?, 89 $'-I X10 .> :B w}Iw .) w}I2 QÏ [3$' '#7 $'W$% 2'13 $3M[ .õ, +"T$' 8)*I B¶ng 14.1: D5$% 6AC$% 89 $'- 3 QN 0'q$ <j,0 0'` 0?, rXI x w0 ww w2 w3 w} w5 wx w7 w~ w9 20 2w 22 23 2} 2 x wm 2m }m ~m wx m 32 m x} m w2 ~m 25 xm 5w 2m w d 2 d } d ~ d wx d VÝ dô 14.1: d9+ 0'>& $'- 0_ w2 0'q$ <j, 0'` .) } 0'q$ :W 63M5I Ha* +T[ +E 0'F0 89 $'- .) :5$% 6AC$% $'- 0?, $_I Lêi gi¶i: ,n X'>& $'- $)* 0_ }09x $%{$ $'- l2 w2 = }09xn .) [|3 $%{$ $'- 0'F, } 8>+ :W 63M5 $P$ +E 0'F0 $'- 0?, $_ 6) }09x ´ } .) +'AG$% <AC0 8345 :3Ô$ 6) }m ´ }I 8n D5$% 6AC$% $'- 0?, 0'>& $'- 6) wxm .T 0_ } m $%{$ $'- .) [|3 $%{$ $'- 0_ } 8>+ :W 63M5I VÝ dô 14.2: d9+ 0'>& $'- 5w22 0_ ~ 0'q$ :W 63M5I Ha* +T[ ,n +E 0'F0 0?, $_ .) 8n QN 0'q$ <j, 0'` 0?, 0'>& $)*I Lêi gi¶i: ,n d9+ 0'>& 0_ ~ 0'q$ :W 63M5 0_ $%'z, 6) [|3 $%{$ $'- 0_ ~ 8>+ :W 63M5I iN $%{$ $'- +"P$ 0'>& $)* 8v$% :5$% 6AC$% $'- 0'3, 0'# QN 0'q$ :W 63M5 = 5w22/~ = x}I D# .H* +E 0'F0 $'- 0?, 0'>& 6) x}2 ´ ~I 8n iN <AG$% <j, 0'` 0?, 0'>& QÏ 6) wx .T w wx = x}2I 14.1.4 Bé nhí ROM. B9 $'- bcd 6) 89 $'- 0'` <h0 lbg,: k #$6* dg[#"*nI pq* 6) [9+ 2345 89 $'- [) 2']$% [K+ 010 $93 :5$% 0?, $_ 2'3 +¾+ $%5å$I ^-3 6S :# $)* [) 89 $'- bcd 0s$ <AC0 %h3 6) 89 $'- 2']$% 8,* 'V3D 0_ $'3/5 6#73 89 $'- bcd 2'10 $',5 $'A: YbcdD EYbcdD EEYbcdD EYbcd $',$' lf6,Q'n .) bcd 0'gI 14.1.4.1 Bé nhí PROM. B9 $'- Ybcd 6) 89 $'- bcd 0_ +'4 6H& +"T$' <AC0I pq* 6) 6#73 89 $'- [) $%AG3 :U$% 0_ +'4 <N+ %'3 +']$% +3$ .)#I ',* $_3 010' 2'10D Ybcd 6) 89 $'- $%AG3 :U$% 0_ +'4 6H& +"T$' <AC0I pN3 3 [|3 8>+ 0?, Ybcd 0_ [9+ 0(5 0'TI B9 $'- Ybcd <AC0 6H& +"T$' 8v$% 010' 6)[ <F+ $'W$% 0(5 +"TI NJ5 +']$% +3$ <AC0 <N+ .)# +"#$% Ybcd [) Q,5 +'T &'L3 8\ .T 010 0(5 +"T 0?, $_ 8P$ +"#$% 8j <F+ .z$' .3Ô$ 3 6S :# $)* [) Ybcd [) <AC0 %h3 6) 89 $'- bcd 6H& +"T$' [9+ 6($I ^3M0 6H& +"T$' bcd 0ò$% <AC0 %h3 6) <N+ bcd .) $_ <s3 '\3 &'L3 0_ [9+ +'3J+ 8j <=0 83M+ %h3 6) 89 <N+ bcd ',* 0s$ %h3 6) +'3J+ 8j 6H& +"T$' bcdI 14.1.4.2 Bé nhí EPROM vµ UV - EPROM. B9 $'- EYbcd <AC0 &'1+ [3$' ", <4 0'# &'Ð& +'O0 '3M$ +',* <E3 $93 :5$% 0?, Ybcd Q,5 2'3 $_ <a <AC0 <N+I !"#$% 89 $'- EYbcd +, 0_ +'4 6H& +"T$' 0'>& $'- .) x#1 $_ ')$% $%'T$ 6($I p3/5 $)* 6) <=0 83M+ 0($ +'3J+ +"#$% f51 +"T$' &'1+ +"34$ [;5 +'R 0?, [9+ :O 1$ :O, +"P$ 89 .3 xR 6SI d9+ EYb QR :B$% "9$% "a3 <AC0 %h3 6) Z^ k EYbcd lZ^ 6) 0'W .3J+ +¾+ 0?, +3, 0O0 +>[ Z6+", k ^3#6g+nI ^K$ </ +å$ +73 :5* $'K+ 0?, Z^ k EYbcd 6) +'G3 %3,$ x#1 0?, $_ f51 6q5 l20 &'@+nI !K+ 0L 010 0'>& $'- Z^ k EYbcd 0_ [9+ 0R, QE <AC0 :U$% <4 0'3J5 +3, 8F0 x7 0O0 +>[ x#1 010 $93 :5$% 0?, $_I ^-3 6S :# $)* [) EYbcd 0ò$% 0s$ <AC0 0#3 $'A 6) 89 $'- EYbcd <AC0 x#1 8v$% +3, 0O0 +>[ ',* <V$ %3L$ <AC0 %h3 6) Z^ – EYbcdI HT$' w}Iw +"T$' 8)* 010 0'q$ 0?, [9+ 0'>& Z^ k EYbcdI p4 6H& +"T$' 0'# [9+ Z^ k EYbcd 0($ +'O0 '3M$ 010 8A-0I wI X#1 010 $93 :5$% 0?, $_D <4 x#1 [9+ 0'>& +'T &'L3 +'1# $_ ", 2'\3 <4 0¾[ +"P$ 8L$% [70' 'M +'N$% .) <=+ $_ .)# +'3J+ 8j x#1 EYbcd <4 0'3J5 x7 +3, 0O0 +>[ 2'#L$% w5 k 20 &'@+I 2I LH& +"T$' 0'# 0'>&I p4 6H& +"T$' 0'# [9+ 0'>& Z^ k EYbcd +'T <=+ $_ .)# +'3J+ 8j <N+ l+'3J+ 8j 6H& +"T$' nI p4 <N+ 0'AV$% +"T$' .) :W 63M5 .)# EYbcd +'T +'3J+ 8j <N+ bcd QR :B$% <3M$ 1& w2I5^ '#=0 0,# 'V$ &'B +'590 .)# 6#73 EYbcdI p3M$ 1& $)* <AC0 %h3 6) ^&& +"#$% 8L$% :W 63M5 0?, Z^ k EYbcdI 3I L¾& 0'>& $'- +"y 673 <4 0¾[ +"P$ 'M +'N$%I !õ 010 8A-0 +"P$ <q* +, +'K* 0ò$% $'A 010 +'3J+ 8j <N+ EYbcd +'T 0ò$% 0_ 010 +'3J+ 8j x#1 EYbcd 2'10 $',5I ^) +K+ 0L 010 2345 89 $'- Z^ – EYbcd </5 0_ [9+ $'AC0 <34[ 0'>$' 6) 2']$% +'4 <AC0 6H& +"T$' +"O0 +3J& +"P$ 8L$% [70' 0?, 'M +'N$%I D# .H*D 89 $'- EYbcd <a <AC0 ", <G3 <4 %3L3 f5*J+ .K$ </ $)*I Ha* <4 S <J$ 010 2S '3M5 [a QN 0?, 010 rX +"#$% 8L$% w}I2I .> :BD [a QN 89 &'H$ 27w2~ k 25 :)$' 0'# Z^ k EYbcd 0_ :5$% 6AC$ .) +'G3 %3,$ +"5* 0H& 6) 250$QI D5$% 6AC$% 0?, 0'>& $'\ <AC0 2S '3M5 +"P$ [a QN 89 &'H$ l&,"+ $5[8g"n .) +'G3 %3,$ +"5* 0H& <AC0 8\ <3 [9+ QN 0I !"#$% 010 [a QN 89 &'H$ +'T 0'W X 6) 09$% $%'M XdciD 0s$ 27xx 65]$ 0'` 010 0'>& $'- EYbcdI p4 83J+ +'P[ 0'3 +3J+ +, .)# [B0 QE +,* 010 0'>& $'- 0?, 010 'a$% 0't$% '7$ JedEXc lj,[g0#I0#[n ',* JDb lj:"I0#[n +'g# <AG$% [7$% 3$+g"$g+I B¶ng 14.2: d9+ QN 0'>& $'- Z^ k EYbcdI HTNH w}Iw H×nh 14.1: BN +"> 010 0'q$ 0?, 'h 010 0'>& $'- bcd 27xxI VÝ dô 14.3: pN3 3 bcd 0_ [a 89 &'H$ 6) 27w2~ 0_ :5$% 6AC$% $'- 6) w2~2 8>+I !", 8L$% +, +'K* +E 0'F0 0?, $_ 6) wx2 ´ ~ l+K+ 0L [h3 bcd </5 0_ ~ 0'q$ :W 63M5n <3/5 $)* $_3 6P$ "v$% $_ 0_ ~ 0'q$ :W 63M5 .) QN 0'q$ <j, 0'` <AC0 +T[ +'K* 6) w} .T 2 w} = wx2I 14.1.4.3 Bé nhí PROM cã thÓ xo¸ ®"îc b»ng ®iÖn EEPROM. B9 $'- EEYbcd 0_ [9+ QN A5 <34[ Q# 3 EYbcd 6) :# .T <AC0 x#1 8v$% <3M$ $P$ f51 +"T$' x#1 "K+ $',$'D $',$' "K+ $'3/5 Q# 3 +'G3 %3,$ x#1 20 &'@+ 0?, ZEYbcdI N%#)3 ", +"#$% EEYbcd +, &'L3 x#1 +#)$ 89 $93 :5$% 0?, bcdI !5* $'3P$D A5 <34[ 0'>$' 0?, EEYbcd 6) +, 0_ +'4 6H& +"T$' .) x#1 2'3 0'>& $'- .;$ y +"P$ %31 0¾[ 0?, 8L$% [70' 'M +'N$% [) 2']$% &'L3 6K* ", $'A <N3 3 Z^ – EYbcdI H,* $_3 010' 2'10 6) EYbcd 2']$% 0($ +'3J+ 8j 6H& +"T$' .) +'3J+ 8j x#1 $%#)3 $'A <N3 3 Z^ k EYbcdI p4 '#)$ +#)$ +7# +'5H$ 6C3 0'# EYbcd $') +'3J+ 2J &'L3 2J+ 'C& .)# 8L$% [70' 0?, 'M +'N$% 0L [70' <3M$ <4 6H& +"T$' EEYbcd QR :B$% <3M$ 1& ^&& = 5^ $'A$% 0'@$% "K+ <¾+I $'T$ 0'5$%D %31 +')$' 0'# w 8>+ 0?, EEYbcd <¾+ 'V$ "K+ $'3/5 Q# 3 Z^ k EYbcdI B¶ng 14.3: d9+ QN 0'>& EEYbcd .) 0'>& $'- F6,Q' l$',$'nI X5N3 +",$% wx0 . Ch"ơng 14 Phối phép 8031/51 với bộ nhớ ngoài 14.1 Bộ nhớ bán dẫn. !"#$% &'($ $)* +, $'-. $P$ $_ <AC0 '345 wxd 0_ $%'z, 6) wx [Pk%,k8*+gI 14.1.2 Tổ chức bộ nhớ. X10 0'>& <AC0 +E 0'F0 .)# [9+ QN $%{$ $'-