📄 start_mx.lst
字号:
AX51 MACRO ASSEMBLER START_MX 09/22/06 14:21:05 PAGE 1
MACRO ASSEMBLER AX51 V2.13
OBJECT MODULE PLACED IN START_MX.OBJ
ASSEMBLER INVOKED BY: D:\program\keil\C51\BIN\AX51.EXE START_MX.A51 MOD_MX51 SET(LARGE) DEBUG EP
LOC OBJ LINE SOURCE
1 $mod_mx51
2 ;------------------------------------------------------------------------------
3 ; This file is part of the PK51 Professional Developers Kit
4 ; Startup Code for the Philips 80C51MX architecture
5 ; Copyright (c) 2000-2002 Keil Elektronik GmbH and Keil Software, Inc.
6 ; Version 1.03
7 ;------------------------------------------------------------------------------
8 ; START_MX.A51: This code is executed after processor reset.
9 ; You may add this file to a uVision2 project.
10 ;
11 ; To translate this file manually use AX51 with the following invocation:
12 ;
13 ; AX51 START_MX.A51
14 ;
15 ; To link the modified START_MX.OBJ file to your application use the
16 ; following LX51 invocation:
17 ;
18 ; LX51 START_MX.OBJ, <your object file list> <controls>
19 ;
20 ;------------------------------------------------------------------------------
21 ;
22 ; Setup 80C51MX Configuration Register (MXCON)
23 ;
24 ; Extended Call Return Mode (intermixed subroutine call with ECALL/LCALL/ACALL)
25 ; ECRM Val Description
26 ; --- --- -----------
0000 27 ECRM EQU 0 ; 0 = classic CALL/RET instructions with 2-byte stack frame
28 ; ; 1 = CALL/RET save and restore the full 3-byte program counter
29 ; NOTE: ECRM is only available on some devices, check your chip specification
30 ;
31 ; Extended Addressing Mode (enable upper address multiplex on Port 2)
32 ; EAM Val Description
33 ; --- --- -----------
0000 34 EAM EQU 0 ; 0 = do not change configuration state of the CPU
35 ; ; 1 = enable extended addressing mode (multiplex A16..A22 on Port 2)
36 ;
37 ; Extended Stack Memory Mode (16-bit Stack Pointer)
38 ; ESMM Val Description
39 ; ---- --- -----------
0000 40 ESMM EQU 0 ; 0 = classic 8051 stack pointer (8-bit) addressing IDATA space
41 ; ; 1 = extended 16-bit stack pointer addressing EDATA space
42 ;
43 ; Extended Interrupt Frame
44 ; EIFM Val Description
45 ; -- --- -----------
0000 46 EIFM EQU 0 ; 0 = classic 8051 interrupt frame (16-bit address pushed)
47 ; ; 1 = extended 24-bit interrupt frame (3 bytes pushed on interrupt)
48 ;
49 ;
50 ;
51 ; Setup Additional Features (AUXR, AUXR1)
52 ;
53 ; XDATA access (External XDATA space)
54 ; EXTRAM Val Description
55 ; --- --- -----------
0000 56 EXTRAM EQU 0; 0 = access on-chip XDATA RAM
57 ; ; 1 = disable on-chip XDATA and access off-chip XDATA space
58 ;
AX51 MACRO ASSEMBLER START_MX 09/22/06 14:21:05 PAGE 2
59 ; ALE (Address Latch Enable) Output Signal
60 ; AO Val Description
61 ; -- --- -----------
0000 62 AO EQU 0 ; 0 = ALE signal is generate at a constant rate
63 ; ; 1 = ALE signal is active only during a MOVX or MOVC instruction
64 ;
65 ; Low Volatage (Vcc) configuration
66 ; LPEP Val Description
67 ; ---- --- -----------
0000 68 LPEP EQU 0 ; 0 = chip supply volatage (Vcc) is above 4V
69 ; ; 1 = chip supply volatage (Vcc) is below 4V
70 ;------------------------------------------------------------------------------
71 ;
72 ; CPU Stack Size Definition
73 ;
74 ; The following EQU statement defines the stack space available in extended
75 ; stack mode (ESMM set to 1) for the application program. It should be noted
76 ; that the stack space must be adjusted according the actual requirements of
77 ; the application.
78 ;
0100 79 STACKSIZE EQU 100H ; set to 100H Bytes.
80 ;
81 ;------------------------------------------------------------------------------
82 ;
83 ; User-defined Power-On Initialization of Memory
84 ;
85 ; With the following EQU statements the initialization of memory
86 ; at processor reset can be defined:
87 ;
88 ; ; the absolute start-address of IDATA memory is always 0
00FF 89 IDATALEN EQU 0FFH ; the length of IDATA memory in bytes.
90 ;
0000 91 XDATASTART EQU 0H ; the absolute start-address of XDATA memory
0000 92 XDATALEN EQU 0H ; the length of XDATA memory in bytes.
93 ;
0000 94 PDATASTART EQU 0H ; the absolute start-address of PDATA memory
0000 95 PDATALEN EQU 0H ; the length of PDATA memory in bytes.
96 ;
97 ; Notes: The IDATA space overlaps physically the DATA and BIT areas of the
98 ; 80C51MX CPU.
99 ;------------------------------------------------------------------------------
100 ;
101 ; Reentrant Stack Initilization
102 ;
103 ; The following EQU statements define the stack pointer for reentrant
104 ; functions and initialized it:
105 ;
106 ; Stack Space for reentrant functions in the SMALL model.
0000 107 IBPSTACK EQU 0 ; set to 1 if small reentrant is used.
0100 108 IBPSTACKTOP EQU 0FFH+1 ; set top of stack to highest location+1.
109 ;
110 ; Stack Space for reentrant functions in the LARGE model.
0000 111 XBPSTACK EQU 0 ; set to 1 if large reentrant is used.
00010000 112 XBPSTACKTOP EQU 0FFFFH+1; set top of stack to highest location+1.
113 ;
114 ; Stack Space for reentrant functions in the COMPACT model.
0000 115 PBPSTACK EQU 0 ; set to 1 if compact reentrant is used.
00010000 116 PBPSTACKTOP EQU 0FFFFH+1; set top of stack to highest location+1.
117 ;
118 ;------------------------------------------------------------------------------
119 ;
120 ; Page Definition for Using the Compact Model with 64 KByte xdata RAM
121 ;
122 ; The following EQU statements define the xdata page used for pdata
123 ; variables. The EQU PPAGE must conform with the PPAGE control used
124 ; in the linker invocation.
AX51 MACRO ASSEMBLER START_MX 09/22/06 14:21:05 PAGE 3
125 ;
0000 126 PPAGEENABLE EQU 0 ; set to 1 if pdata object are used.
0000 127 PPAGE EQU 0 ; define PPAGE number.
128 ;
129 ;------------------------------------------------------------------------------
130
131 ; Define CPU Symbols
0081 132 sfr SP = 0x81;
01FB 133 sfr SPE = 0x1FB;
008E 134 sfr AUXR = 0x8E;
00A2 135 sfr AUXR1 = 0xA2;
01FF 136 sfr MXCON = 0x1FF;
137
138 NAME ?C_STARTUP
139
------ 140 ?C_C51STARTUP SEGMENT CODE
141
142 IF ESMM == 1
?STACK SEGMENT EDATA
RSEG ?STACK
DS STACKSIZE ; Stack Space 100H Bytes
ELSE
149
------ 150 ?STACK SEGMENT IDATA
------ 151 RSEG ?STACK
000000 152 DS 1
153
154 ENDIF
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -