Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Скачиваний:
59
Добавлен:
14.04.2015
Размер:
2.03 Mб
Скачать

32

Chapter 2. Architecture Overview

 

 

Philips 80C51MX

The Philips 80C51MX provides a unified 16 MB address space. New instructions can access up to 16MB memory whereby CODE and XDATA space are mapped into one single address space. The stack pointer can be configured as 16-Bit stack pointer that addresses the on-chip RAM area in the EDATA memory class. The following table shows the memory classes used for

2 programming the 80C51MX architecture. These memory classes are available when you are using the AX51 macro assembler and the LX51 linker/locater.

Memory Class

Address Range

Description

DATA

7F:0000 7F:007F

Direct addressable on-chip RAM.

BIT

7F:0020 7F:002F

Bit-addressable RAM; accessed bit instructions.

IDATA

7F:0000 7F:00FF

Indirect addressable on-chip RAM; can be

 

 

accessed with @R0 or @R1.

EDATA

7F:0000 7F:FFFF

Complete on-chip RAM; can be used as stack

 

 

space or can be accessed with @PR0 or

 

 

@PR1.

XDATA

00:0000 00:FFFF

64 KB RAM (read/write access). Accessed with

 

 

MOVX instruction.

HDATA

00:0000 7F:FFFF

8 MB RAM (read/write access). Accessed with

 

 

MOVX instruction and extended DPTR.

CODE

80:0000 80:FFFF

Classic 8051 compatible 64 KB ROM (only read

 

 

access possible). Used for executable code or

 

 

constants.

ECODE

80:0000 80:FFFF

8 MB ROM (only read access possible).

HCONST

80:0000 80:FFFF

8 MB ROM. Same as ECODE, this class is

 

 

used by the CX51 Compiler for constants.

BANK 0

80:0000 0xBF:FFFF

Used by the CX51 Compiler to expand the

… BANK 63

B0:0000 B63:FFFF

program memory to more than 64KB. Refer to

 

 

“Philips 80C51MX” on page 277 for more

 

 

information.

 

 

 

NOTES

Colons are used to improve the readability only. The addresses are entered in the tools as numbers without colon.

The memory prefixes D: I: X: C: B0: .. B31: cannot be used at Ax51 assembler level. The memory prefix is only listed for better understanding. The Lx51 linker/locater and several Debugging tools, for example the µVision2 Debugger, are using memory prefixes to identify the memory class of the address.

Keil Software — A51/AX51/A251 Macro Assembler and Utilities

33

 

 

80C51MX Memory Layout

The Philips 80C51MX memory layout, shown in the following figure, provides a universal memory map that includes all memory types in a single 16MB address region. The memory layout of the Philips 80C51MX is shown below:

 

 

 

DATA

 

 

 

2

FF:FFFF

 

7F:FFFF

FF

 

 

 

 

 

 

 

 

98

 

 

 

 

 

 

 

 

 

 

 

90

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

SFR

 

 

 

 

 

 

SPACE

 

 

 

 

 

 

 

DATA

 

 

 

 

 

 

 

 

 

 

88

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

ECODE

 

 

80

8MB

 

 

 

 

 

DATA

 

 

 

80

DA

 

 

 

TA

 

 

7F:

 

 

 

007F

 

 

EDATA

 

 

 

64KB

 

 

CODE

7F:00FF

 

 

(= Bank 0)

 

 

 

 

 

64KB

 

 

 

80:0000

 

 

 

7F:FFFF

IDATA

 

 

 

 

 

EDATA

256 Bytes

 

 

 

DATA

 

64KB

 

 

 

128 Bytes

 

 

 

 

7F:0000

 

 

 

 

7F:0080

 

 

 

 

 

2F

HDATA

 

 

8051

8MB

 

 

Bitspace

 

DATA

 

20

 

 

1F

00:FFFF

128 Bytes

 

 

 

 

4

 

 

 

XDATA

 

 

Register

 

 

Banks

64KB

 

 

 

 

 

00:0000

7F:0000

 

0

The 80C51MX offers new CPU instructions that provide a new addressing mode, called Universal Pointer addressing. Two Universal Pointer registers PR0 and PR1 are available. PR0 is composed of registers R1, R2, and R3. PR1 is composed of registers R5, R6, and R7. These new Universal Pointer registers hold a 24-bit address that is used together with the EMOV instruction to address the complete 16MB memory.

34 Chapter 2. Architecture Overview

 

Intel/Atmel WM 251

 

Also the 251 architecture is a superset of the classic 8051 architecture. The 251

 

is the most advanced variant and provides the following key features:

 

Completely code compatible with the standard 8051 microcontroller.

2

Powerful 8/16/32-bit instructions and flexible 8/16/32-bit registers.

16MB linear address space and CPU support for 16-bit and 32-bit pointers.

True stack-oriented instructions with 16-bit stack pointer.

The following table shows the memory classes used for programming a 251 microcontroller. These memory classes are available when you are using the A251 macro assembler and the L251 linker/locater.

Memory

Address Range

Description

Class

 

 

DATA

00:0000 - 00:007F

Direct addressable on-chip RAM.

BIT

00:0020 - 00:002F

8051 compatible bit-addressable RAM; can be accessed

 

 

with short 8-bit addresses.

IDATA

00:0000 - 00:00FF

Indirect addressable on-chip RAM; can be accessed with

 

 

@R0 or @R1.

EDATA

00:0000 00:FFFF

Extended direct addressable memory area; can be

 

 

accessed with direct 16-bit addresses available on the 251.

ECONST

00:0000 00:FFFF

Same as EDATA - but allows the definition of ROM

 

 

constants.

EBIT

00:0020 - 00:007F

Extended bit-addressable RAM; can be accessed with the

 

 

extended bit addressing mode available on the 251.

XDATA

01:0000 01:FFFF

8051 compatible DATA space. Can be mapped on the 251

 

(default space)

to any 64 KB memory segment. Accessed with MOVX

 

 

instruction.

HDATA

00:0000 FF:FFFF

Full 16 MB address space of the 251. Accessed with MOV

 

 

@DRK instructions. This space is used for RAM areas.

HCONST

00:0000 FF:FFFF

Same as HDATA - but allows the definition of ROM

 

 

constants.

ECODE

00:0000 FF:FFFF

Full 16 MB address space of the 251; executable code

 

 

accessed with ECALL or EJMP instructions.

CODE

FF:0000 - FF:FFFF

8051 compatible CODE space; used for executable code or

 

(default space)

RAM constants. Can be located with L251 to any 64 KB

 

 

segment

CONST

FF:0000 - FF:FFFF

Same as CODE - but can be used for ROM constants only.

 

(default space)

 

 

 

 

Colons are used to improve the readability only.

The addresses are entered in the tools as numbers without colon.

Keil Software — A51/AX51/A251 Macro Assembler and Utilities

35

 

 

251 Memory Layout

The following figure shows the memory layout of the 251 architecture.

HDATA ECODE HCONST 16 MB

FF:FFFF

00:FFFF

DATA

 

 

 

FF

 

 

 

F8

2

CODE

 

98

default page

 

 

 

 

FF:0000

 

SFR

 

 

 

 

 

 

SPACE

90

Reset Vector

 

 

 

 

 

 

88

 

 

DATA

 

 

 

80

80

 

 

 

 

 

00:

 

 

 

007F

 

 

EDATA

 

EBIT

 

64 KB

00:0100

 

251

 

 

 

 

 

 

 

 

bitaddr.

02:0000

 

 

 

 

 

IDATA

 

XDATA

 

256 Bytes

 

 

DATA

 

(default,

 

 

 

128 BYTE

 

SEGMENT

 

 

 

 

 

mapable)

 

00:0080

 

 

 

 

 

 

 

2F

01:0000

 

 

8051

 

 

 

 

 

 

Bitspace

 

 

DATA

20

 

 

1F

EDATA

 

128 Bytes

 

 

 

 

 

64 KB

 

 

4 Register

 

 

 

 

 

 

Banks

00:0000

 

00:0000

0

The 251 completely supports all aspects of the classic 8051 memory layout and instruction set. Existing 8051 programs can be directly execute on the 251. The four 8051 memory spaces (DATA, IDATA, CODE and XDATA) are mapped into specific regions of the 16 MB address space.

Соседние файлы в папке HLP