i~o
87C51GBHARDWARE DESCRIPTION
PO.O-PO.7 P2.O-P2.7
...- .
“%. --------
....
-.J~l]JIJ\-J[m;.------------------,
1
1
,
I
*
1
*
I
I
I
I
,
I
1
I
I
1
s
I
*
,
I
#
1
,
I
I
1
1
1
I
I
8
1
#
I
,
1
1
1
I
w’” ‘ “E’ ‘
Ill ‘c ~
Zr#-’ I ‘“”
PSA.1
3MALP0RTS
I
11’
INCSEM3NT2S
I
I
*
,—
I
I
~ ~ rE-w-=J=/fRj -A’”
A
A
Pt,O-P!.7
c-c
P5.O-PS7
P4.O-P4.7 P3.O-PS.7
H
N
0
7
*
270S97-1
-,----- . .--,?.-- =,--,. m:--—-
rlgure 1.ufva IUD DnJGKumgram
whichare generallyreferred to as the Lower 128,the
Whenaninstructionaccessesan internal locationabove
Upper 128,and SFR space.TheUpper 128bytesoccu-
address7FH, the CPU knowswhether the accessis to
pya
paralleladdressspacetotheSpecialFunctionReg-
theupper128bytesofdataRAMorto SFRspaceby
iaters.That means they have the same addresaesjbut
the addressingmodeused in the instruction. Instmc-
theyare physicallyseparatefrom
SFRspace.
tions
that use direct addressingaccessSFRspace.For
example,
The Lower 128 bytes of RAM are present in all
MCS-51devices.All of the bytesin the Lower128can
MOVOAOH,data
be accessedbyeither director indirectaddressing.The
lowest32byteaare groupedinto4 banksof 8 registers.
acceaaesthe SFRat locationOAOH(whichis P2). In-
Program instructions call out these regiaters as RO
stmctionsthat w indirectaddressingaeeessthe upper
through R7. Two bits in the Program Status Word
128bytesof data RAM. For example,
(PSW)selectwhichregisterbankis in use.This allows
moreMlcient use of cede space,sinceregisterinstmc-
NOV@RO,data
tions are shorter than instructionsthat use direct ad-
dressing.
6-4