MP M1 Primary Memory Notes
MP M1 Primary Memory Notes
7 Me mo ry - - - - - - -- - - - - - -- ~ o u
- - - - - -- ~ - -- - -- - - - - - -- - - ds a faci lity for sto ring the unproces_~:loc a t i
• Any s~·ste m whi ch proc esse s dig ital dat a nee The c
process ed and complet ely process ed dat a.
sto re all the abo ve mentioned dr.An d 1
• A sub sys tem of s uch digi tal processi ng sys tem whi ch can
The n
as m em ory . larg e
• Ear lier the rnem ory used to be of magn etic type.
1.10 Expanding the Memo~ Size .
~ . • vailable ,nemory chip is n ot. s uffi cient. Jfr-n, ,.
1
In ma ny applica tions the ca pae1ty of th~ smg e_ a . lied ex ans ion of rne m ory. '"'
1
to increase it by us ing more than on e chips. Th.1s s ca P
The memory expans ion can be of foJlowing two types:
1. Expansion of word size. (increase in N).
2. Expanding the word capacity (increa se in M ).
1.10.1 : A 16 x 4 size memory is available. Expand its word size so as to obtain a 16 x 8 memory•
n.
:p 1 : Decide number of memory chips
If the required word size is denoted by "n" and the available word size is denoted by ~ , lh~-
oumber of I Cs required is an integer given by,
Number of I Cs, X > n/N.
Here n = 8 and N = 4 hence X = 2. We have to use 2 ICs, each with a capacity 16 x 4.
• 2 : Connections
Since the number of locations does not change (16), the number of address lines will not change ;·
be equal to 4, and they will be common to both the memory !Cs.
As the word size is to be expanded, we will use the data lines of IC-2 as the MSB lines ( D 7• D,.., f;
whereas the data lines of IC-I will be used as LSB lines (D3 , D 2, D 1, D0 ).
11 ,Cla ssif icat ion and Cha ract eris tics of Mem orie s
t ..,,
eters used as
The mem ory devices can be classified, on the basis of vario us param eters. The param
is of classificati on a re a s follows :
(1) Principle of op era ti on (2) Phys ical chara cteris tics
(3 ) Mode of acces s (4) Technology used for fabrication
\
e',12 · Clas sific atio n Bas ed on Prin cipl e of Ope ratio n
1.12.1.
The class ificat ion of mem ories based on the principle of opera tion is show n in Fig.
- • A
1.15 Random Access Memory (RAM)
• \\ ·c know that RA..\1 is a memory that can be read as well as written .
• R..A..\f is a volatile memory so it loses the stored data when power is turned off.
Types of RAM
There are two t ypes of RAM :
, 1J Static RAM. (2 ) Dynamic RAM.
1.16 Static RAM (SRAM)
• It is possible to imple ment the static RAM us ing the bipolar as well as MOS technoh~
• It is possible to s tore data as Jong as power is applied to the chip.
Introduction to Microprocessor (UPTU)
1-22 In troduction to Mieroi,. ,,
• Th.is EPROM there is a quartz lid or window ()n the pa ~ e.
, . Pl'OM b}' exposi ng it to the u ltrav1olet ( UV) w.,, ~
• We co n er ase t,11s '- •
light through the quartz wind<>w.
Disadvantages
l. Selective eras ing is not possible to achieve. All the locations get erased.
2. The EPROM has lo be removed from the socket and put in the eraser for eras i:ng.
Volatile Memory
If the informa tion stored in a memory chip is lost when the electrical power is s witched OF'F, lh-
memory is c-nllcd as volatile memory. RAM is a volatile memory.
Non-volatile Memory
• ff the information once stored in memory chip does not change unJess altered delibera tely are -
as non-volatile memory. 1j
• Such memories can hold the information even alter switching off the power s upply . Read
memories (RO Ms) of a.II types are examples of non-volatile memory.
• We know that the information stored in a ROM is of permanent nature. I t can be only read and
written.
• Following advantages make the ROM a n important part of many digital systems :
(1) Low cost
(2) High speed
(3) Flexibility i.o system design.
(4) ROM is a nonvolatile memory.
1.14.1 Appllcatlons of ROM
1 l l l l
Mask programmable PROM M11sk PROM EPROM
ROM programmable
ROM
1
EEPROM
Fig.LI-ti : ROJ\I classifi culion
ROM
♦
A ROM is an array of selectively unid irectional contacts. The contacts can be open or closed sclect1,·el~
to program the required information into a ROM.
A 16-bil ROM array is shown in Fig. 1.14.2. II uses Lwo 2 - 4 addrei,s decoders. 16 locntaon.~ :ind 1-d:u.n
outpui. So t'his is a 16 x 1 ROM.
The mel.bod of addressing is called as two dimens ional. X - Y or coincident select ion. nddn.-ssm"
A unidirectional switch is included at th e junction of every row and colum n.
The lower tv.•o add ress bits (A 1 A 0 ) a re dL>coded by the dernder 0 1_. The output:< uf th, ~ dl-codt'r sr,e u.,,.J
to select one out of the four rows.
The high two address bits ("'1 A) a re dewded by the dt' codt'r Dw Tht:> four oulpu ll' of th1 ~ llc'Cnd rr 1tn•
used to select. one out of th e four column sense nm plifil'rs.
I ,>II
t,')11 ,-h ,11,.ltt" I'\" 1·1111 11111 1,,, wo•ol 11, ., 1 tt111l 0 111 11 , , ' " " 11 ,. , 111 111 , l"M •• 111 . , It \ \ I 1 ,., I"
t.'l\ ,,,
'l'h ,· .,,· I • ,, ,. 111 tlni; h nw, unn , h q1 ..,-,, 11 1µ1111111•, I 111 111 h 1 "' I\ , h 11 ,1,,., ,. 111 ti , f'r tuut
m · 1 , 111 ,1 111 •111 ~h · 111 111 n ll ni<h l l1 •n1 •· 11 , 11 11 11 111 1 " Fl1111h M1 ·m11n
1 » I t,· h 11 1,111 n , llt•d ltowlt•r N111'1lh1•1111 t 11 n,wll tt,II( t 11 ~,'il for ,•r 1 m 1,1 t h, ' ""'' nt•
1 11
• " ,,,, I ' 111'1•· I ll nw,h l\lt •n 1111 1 11r1• htl{lo ~ P l '"' ' l,w llfWl \1 11111,t " ''' ljff' I\ '""' , . ,.. ;,r
, d ·q I
111 1•111. • ,ll pu1 ck vi1:p,- 111·, • llll·nn,i. th n 111µh " '" 1 It•• 1111 , •11r,,. ,,.. ,1r 111111 , 11111n11111..-11•,.. • th ,tar
••u t ,1d, world
Tlw mir n .>l"l>t:1•:t:-tor unit 11 Ct'1•p111 1111' fi n' 1/ m l r-111 ·1,,111 ,, Ir 111 h, 111101• ,t,
C(11l\"t•r1<' r l'l, ,1111I • • d.s lh l· t'l'!<l.llt io fllll p ttl '"' ' " ' a Uil,1• I I 1 )
Th,•n • nn · ti,f;,., ·' , • n <li; h., · w htl'h t hr• I'll ,1,.,, , ~, ,
,r1111< r (
,1,fi,.,I t
,r· • •J!! Ids., knvt• '1rtl
, ddn-
whd1• ot hc-r •l "-l' r. 1,: ,,. ld rt•R.~ Tlwy 111'1 '
t:l l nrnppt.'CI l/0 111 11•·1 , r.1I rnapp,·d 1/()
:-.1.. 111 nry mupp<.•il 1 ·11
UO mapped VO (Peripheral Mapped UO)
In 1hi;. type of 1/0. thl' mic ropnx·C's:•or unit lll<L'i< l'l)!hl n rl1l n, luw , 111 1d1•n 11 rv II m1ou• "' ttU ' pu
d, •1· i ..·1•.
lt 1i; nn R bit numbcrin~ 11y1Ht•111 for l/ Os 11/ll"d i11 ronjunr1wn w 11!i 1h,• mput 1ml ,natf•"I 111•tn,("\
11 1.s nll'o rnllcd as 1/0 i"pncc II i:; di lforcnl frum nwmor,v i< prw ,• , , ., \Ii h11 numho•nn11 • .,_,,
Th i' l'1ght ndclres." lim•,a hnv .., 'J. = 256 cuml11 nnti11n1, of 111lil n ·--••, n111•, th,• nu,, ..,,,.. , ... n~ ,
0
1dl'nt1(v 256 1/ 0 devices with 11ddrc1111 rnnge:; rnn1t1n)I: from llO I I to FFII
> Mappt>d 1/0 11/0 Port Addn•ss ing]
In 1h1s case the 1/0 devir1• is trl'nled u,; 1/0 1k•v1c,• only
Each 1/0 dev ice uses ciJ,:hl hits nf 11dtlr1'!III lin,·• nml no111 rnl "111 n , l• lt1R Input 1u • pu\ .,..
fTTW tJ nput uu tpu l writt- l
Tlw acldresh bus tJf 80Hf, rni,·rup ro1:1•RS11r ,,. of 16 lHt.,, . hut h,r l '( I d, , 1u ,,111 - I I I U;Oal 'I.
t 1, 1rnpll'llll'lll I hu, t ho• Ii ltit odd rt'& 1R 1r11n1<l1•rn'(I 0 11 l,mh otl,lr• ,, 11r"\I I" •• \ 1, \ I I \ \
Th,• 1:un1e11l.!l 11v1.u lohl1• an• 1m nw . ~o 1111•• 1·.111 " " ' ,111~ 11111· i;rnup I I ' \ 11 \ \ ' \.
()f IJ1 c two ,::ruu pi,
I ..<·I u s r ons id1•r II n ••x11111pl1• , f 111 Id r,.,... 111 Iii J ti, ,. 11 • • • :,n 11
"li u.- ~un t,·11 Ls t r1111,., l,•rr1•d 1111 ,\u 1,, A" " , 11 I• 11 ft1 l lt•"
A, , \, \,
A 1•, i\11 A1 .I\ I.' A 11 A ,, \ \, \ \ \
'
II l) I)
u 0 (I 0 (I
:,0 11 '\JI II
~ on 10 M,croprocesSOf (UPTU) lntr0tlucll1111 to Mlcroprocossor
A PROM can be progrnmm.-<l nnly one,• nficr 11.S li1hr11·nt i,111 Al\,•r prnt,: rn 111111i11i,: I lw runt ,•nt~ will
1.iccomc pcnnnoenlly li:,.ed in th!' ROM.
t,~ The PROM!' Art' mnnufoct urt:>d without any Jnta ,:t,,n•d 1111111 1lw111 11!11•_1 11n· hln ull I
_.bte and programmable RO M
A,: till' nnme ,:ugi:,:,st.~. thr;1e HOM,: con ht, ,·rns,-<I fmd prui;rrnmnwtl ui:nm 11ml ai,:11i11.
Thr commonly Ul'ed techniqu1'1' fnr 1•rnsi11i,: nr,• ns li•llnws :
1 11 Era,:;ing ll!;int,: ultr1wwl,· t rndinlion .
121 Em:-inJ! usinJ! olrc tri ciLy.
The rrnsable pmgrammnblc ROl\'t us inµ ultrtwillh•t ,•rnsi ni: is rnll,•d 11:: l~l'tlO M .
Ar,d th!' ROM that U!1es thP clcrt.ric:il ,·ol~lt,:P for c r11s ini,: ii: known 11,: 1•l1•<·t rk111ly 11lt,1•r11 bl1• HOM
<EAROMl .
)f.
8 '-'<t_ Memories
.M I
l
Vol111tle or
Erasable or
non erasable non vo11111te
Fig. I. LU : C(a>;;!,ifkat iun hast-d 1111 11hysk11l r h11ntrh'rislks
I-
..J RPfre 1-1 hi11g Not rc•q u I n •d RNp11rul
:') Co sl
~
~to rr 1,,, ,...
6 Arcei::s tim e I..<'~:- So the se nrc- fas t Pr
mc•rn11n<'!-
,\tn ri "-• rt, p in ~.
n,r•n111r1t ,
1 . 18 EE PR OM (E 2 PR O M
)
• Th e Ion{! fom, of EE PR OM i!-i
c l,•r t ril'nlly ,•rn'-a hlt · l'HO~ I
• Th ese are ,·e ry s im ilu r lo EPRO
M s nn d u..,,. t lw MOS r1rr1111 ry
• The da ta is s tor ed in thf ' fom1
of r ha rµ, •. Pn•sl• nc· 1· nf drn q.w
o. rr-p n •,,•nt q I .1nrl ,t...
• A ,·olta ge as low as 20 to 2f>
,•o h$ can be us rd fo r t•rn HillK
• It is pos.sible to era se a nd pro or prnJ.rra mmmL'!
gra m n p:1 r11 cu lar me mo ry loc
not ne ce ssa ry to era se 11II Ltw ati on Th , ,., .. ,· ,ll1·1I .u-1,·rtt,
nw mo ry location l-. r ·•
It is howeve r pos:-ibl<' 10 l'n tH
' all Lhc> loc a tio n wi thi
:-pec1al mo de . n abou t 10 m,.. tn 0J)(' r,111 n.:
th• f ~
Th is period is ve ry s ho rl ns
co mp are d to tha t r rq ui rPd for
EPRO M . lht · 11lt r., nn ll" l r,1d1 ll1 : •·"i
i
An oth er :1d,·an tng e of EE PROM
i!'; t h nt it ca n he <'rn s Prl :in d
con n~ t.ed in the ci rcu it. r,·p ro~ r.,m nw ,d \~ h,·11 , h,
Howe \·e r the di:-advantaj!t• of
EE PROM 1)-, vt•ry 1·x1w11 !-- l\'t' .in
d h., ... , ,·n )11\1. 111-n~,, \
.1 9 Fl as h M em or y
~
I
l.oclltlon 12
...
D at a ou tp ul
Lo ca tio n 13
O..ta {
,n pu l
"'
V Lo c,t llO O 14
l.o c,t hO O 15
i' ~
Con1rol sign
al
Fi1,:. U I. J : Se le ct
io n or a lo ca tio n
' lw I' ud dr cs s lrn I.bing th e ad d re
cs ar t' ca lled as ad ss li ne s
11 pr.ll'Uce th r ad
dr es s in pu ts or ad
d re ss in p u t is ap d ress bu s.
n th e P lines, pl ie d to a P to M
th e decoder ou tp de co de r. D ep en dj n g on
ut s will select th th e bi n a r y n u m b
,t pu t li ne s e desi re d m em or er ...
y loca ti on .
i t• d at aavailnhlc m th e se
lected m em or y lo
tl ' nu m be r of dat.a li ca ti on ca n b e ~r ea
ne s is N i.e. eq ua d~ on th e d at a o
lll'<i as ou tp ut d at l to th e n u m b er ut p u t li ne s.
a b us of b it s p er w or d. T h
) U t an d ou tp
e o u tp u t d at a li
ut d at a buse s ar e ne s ::ft
m o:;t of th e m em un id ir ec ti on al . T h at m ea n s th.e
or y ch ip s th e sam d at a flows on ly
·h II clatn bu s is ca e se t o f d ata li oe s is u se in o n e di re ct io n.
lled as bi -d ir ec ti d fo r d at a in p u t
" n U l Fig. I.SA . on al d at a bu s an as w el l as d at a ou
d it is re p rese n te tP-
d w it h ar ro w s on
bo th ; ;;:,
>t
1n 1rod ucil on to 1,11(, (C,l) <OCC'll,l
1- 17
••,croprOC0"50<
-
(UP TU)
- d (RO I · pu t uf the ovi •ral l
on to.. . - l now net O.K rea . :".
\ odlJCI'
- lhl' reo d (RO > inp ul of bot.h ICs t.og e lhe r. It wil . lhA ·hip f!elecl 1( Sl mp ul.
\ . OR wo 11 11>< u c
eon nod s .r thin i: ;,. tru e for lhe wri t.o (W lU inp ut,
rn,--.11lory. ~ am
=ti ons MC tul sh ow n in Fig. P. 1. 10 . 1.
Tht• COiln ~~
, A3 A:i 03
. 0,
.,
i A2 A.i.
Chi p •2
02
I"
... I A, A, o,
I - Ao Ao Do
cs RD WR 16 >< 4
8 • btt dat a
,,.., cs (Inp ut or Out put)
RD
WR
•
}~
- A:i 03
02
~
A.i.
Chi p •1
A, o, o,
Ao Do
16 >< 4
u.-.lng two 16 x 4 me mo ry chi
ps
FiR, P. 1.10. 1 : A 16 x 8 me mo ry
pa cit y
- ..1 0.2 Ex pand ing Wo rd ca
ng ed.
n<l, '-'
me ans inc rea sin g the val ue ofM , kee pin g the word size (N) un cha
Expanding word s ize ry the n we ho,
16 x 4 chi ps are ava ilab le and we wa nt to hav e a 32 x 4 me mo
For example if
per for m the word capaci ty exp an:
sion .
the wo rd cap aci ty exp ans ion .
The following exa mple illu str ates
ry using 16 x 4 me mo ry chips.
x. 1.10.2 : Obtain a 32 x 4 memo
on. ~oln
ir .... •
ltep l : Nu mb er of me mo ry
ch ips
nu mb er of
ry of cap aci ty m wo rds usi ng me mo ry chi ps wit h M words each, the
To obtain a me mo
required is giv en by,
X 2: m/M
Wnle (W 1
........3_.._ _.._
2 O i Loca hon a
_... __- r ,- --~ ---o
Location 1
A3
410
Address Az 16
,nput s line
'---+ ---11 --0 cs
A, deco der
Mem ory c hip
Road (R\
Ao
Location 14
3 2 1 O LOCdloon 15
........ ......................
Oulp ul :
Bullers !
"··· ········ ... , ................,
D3 Dz o, Do (Data oulpul l,ne._q)
,,-
~ - 1.9.1
The re are 16 location s each one capable ol'
stor ing a 4-bi t wor d.
I ;10 lttlwd u, 11r,11 10 _.
tn1rod uc1ton 10 M1c1oprocossor (Uf' 1U) 1
'
Meru oriu
I
T t,n,t l
llond only
l
(:orth U)I Adt-1t fl r.1.1Jtf. ,
R t t.' ltf
n,,-,,no rlt Hl rnornr-,t1,, •
11h1fnOr h •$ wrllo m o tnort(t~
trlWM or n AMI I llOMJ ICAM)
I
l I
Stull Ch111g il l'.oupl od j l l l
ll>glSIOI S dw1e ..s (C:CD) ROM PHO M [PROM ~ AROM
' J,' li:. I. 12. 1 : Ml'n tnr) d o..._,mr nt lnn lm,t•cl on prln dplt-
of OIJi'r n l lon
1 . 12. 1 Seq uen tial Mem ori es
'
• Th t• rl.'n1l1·11J,!lwn1111
· · µ frr1111 · ·
i<ur h 1111•1111ir1l.':- 11< 11 :<l!Qll tlll1·111 I proc1
• • •11·:< l ll'nr<• tlw t111w rt·q u1rt·<I Ir,
rnt'mory lur ntion 1for renclint-t or writ 1nt-tl 11; clifTcrcn
t for d11Tc rc11t local 101111
• The• seq uf•ntiul memorie:< 11rt- 1"1111h1•r clni<silied into
two ty pes
(II Shill rci-ri:<ters
(2) Chu rge cuu pk•d dt'vices (CC' D l
1 . 12.2 Ran dom Acc ess Me mor y (RW M
or RAM )
• lu1111 lom ncc·r:;:; mcm on · 11< nlsn .-nllNI 11s rc•nd wr il<•
nw mory <RWM !.
• Thi' mcm n!)· locnliun~ in th1:< typl' of nll'm ory
are ort-tnnizccl in i< uch n wny Lb_a l lhl• a ct
requirerl for occcssinK uny lncnt.ion ii- t he :,;11111 ..
1•. This 1s I he• odvn nl.l.11(e of u;;11·1Jit RAM
scqucnt111l memorit':< .
• RAM s also ca n be further class ilicd into two l,y
pc>R n11nw l.v the s tntic R/\M nnd clyn um ic
RAM s con be fubricutl'd usin g l'ith cr bipo l:ir tc.> chn HAM
• olot-t.v 11r unip olnr ll•ch nnlo gy
, 1.12 .J Rea d Onl y Mem orie s ( ROM )
• Thes e mt'mori1 •1< a re <lesi i;ined only for ruml ing th
e infor11111t ion whk h iR nlre ady s tore d 011 tl: -
user cann ot writ e any new mfor mation on t hem .
• Thes e are simil ur to t he prl'• rcco rder cns11 t'ttc1,.
• A man ufactun> r or i.ome onr cl:<c can writ e
ROMs, but the writ ing proc ess is muc h mort ' com
as com pare d lo I.hat of a RAM .
• ROM is used to store fixed infom 1atio ns such us
look up t able s . instr ucti ons . fixed dntn etc.
• It is possi ble to orgn nize ROM :; in such a way
that read ing time requ ired for any locnt1nn • :i
sam e.
• The ROMs a re fu rthe r class ified in to th ree cala1
tories as followii :
( 1) Read - Only ml'mory.
r2) Prog ramm a ble Read OnJy Mem ory (PR OM)
.
(3) Eras able and Prog ram mab le ROM ( !!:PROM).
~ead - only mem ory