8051 Architectural Specification and Functional Description
SYMBOLICBYTE
ADDRESS BIT ADDRESS ADDRESS
~( | A. |
| \~ |
| ||
|
|
| ||||
|
|
| 2481 |
|
| |
ACC |
| AB | ~I: (FOH)(EOH) |
| ||
'F231 |
| 224 I208 | (DOH) |
| ||
psw I |
| 208 I184 |
|
| ||
| 215 |
|
|
| ||
IPC 1 |
| (B8H) |
| |||
P3 I191 |
| 184 | 1 | (BOH) |
| |
| 176 |
| ||||
IEC | 183 |
| 176 I168 | (ASH) |
| |
| 1 |
| 168 |
|
|
|
P2 | I175 |
| 160 I160 | (AOH) | SFR's | |
| 167 |
|
| |||
|
|
|
| 153 |
| CONTAINING |
SBUF |
|
|
| (99H) | DIRECT | |
|
|
|
| BITS | ||
SCON I |
|
| 152 | (98H) | ADDRESSABLE | |
P1 | I159 |
| 152 I144 | (9OH) |
| |
| 151 |
| 144 |
|
|
|
TH1 |
|
|
| 141 | (8DH) |
|
THO |
|
|
| 140 | (8CH) |
|
Tl1 |
|
|
| 139 | (8BH) |
|
TlO |
|
|
| 138 | (BAH) |
|
TMOD |
|
|
| 137 | (89H) |
|
TCON |
|
|
| 136 | (88H) |
|
:~~143136 ~: :::: |
| |||||
SP |
|
|
| 129 | (81H) |
|
PO |
|
|
| 128 | (SOH) |
|
| 135 |
| 128 |
|
|
|
Figure 2.14. Mapping Of Special Function Registers
address a destination operand. Since operations in the 8051 require 0 (NOP only), I, 2, 3 or 4 operands, these five addressing methods are used in combinations to provide the .8051 with its 21 addressing modes.
Most instructions have a "destination, source'" field that specifies the data type, addressing methods and operands involved. For operations other than moves, the destina- tion operand is also a source operand. For example, in
Most operations involve operands that are located in Internal Data Memory. The selection of the Program Memory space or External Data Memory space for a second operand is determined by the operation mnemonic unless it is an immediate operand. The subset of the Internal Data Memory being addressed is determined by the addressing method and address value. For example, the Special Function Registers can be accessed only thorugh Direct Addressing with an address of
Register Addressing permits access to the eight registers
13
•Register Addressing
--A, B, C (bit), AB (two bytes),
DPTR (double byte)
•Direct Addressing
Lower 128 bytes of Internal Data RAM Special Function Registers
128 bits in subset of Internal Data RAM address space
128 bits in subset of Special Function Register address space
•
Internal Data RAM [@R1, @RO, @SP (PUSH and POP only))
Least Significant Nibbles in Internal Data RAM (@R1, @RO)
External Data Memory (@R1, @RO, @DPTR)
•Immediate Addressing
•Base - Register- plus
Program Memory (@ DPTR+A, @PC+A)
Figure 2.15. Operand Addressing Methods
Direct Addressing provides the only means of accessing the
Immediate Addressing allows constants which are part