在线时间0 小时
UID120886
注册时间2009-4-8
NXP金币0
该用户从未签到
新手上路

- 积分
- 149
- 最后登录
- 1970-1-1
|
Prm 文件如下
/* This is a linker parameter file for the mc9s08ll36 */
NAMES END /* CodeWarrior will pass all the needed files to the linker by command line. But here you may add your own files too. */
SEGMENTS /* Here all RAM/ROM areas of the device are listed. Used in PLACEMENT below. */
Z_RAM = READ_WRITE 0x0060 TO 0x00FF;
RAM = READ_WRITE 0x0100 TO 0x0FFF;
/* unbanked FLASH ROM */
ROM = READ_ONLY 0xC000 TO 0xFFAB;
ROM1 = READ_ONLY 0x5000 TO 0x7FFF;
ROM2 = READ_ONLY 0xFFC0 TO 0xFFD1;
/* INTVECTS = READ_ONLY 0xFFD2 TO 0xFFFF; Reserved for Interrupt Vectors */
/* banked FLASH ROM */
PPAGE_2 = READ_ONLY 0x02A000 TO 0x02BFFF;
/* PPAGE_1 = READ_ONLY 0x019000 TO 0x01BFFF; PAGE already contained in segment at 0x5000-0x7FFF */
/* PPAGE_3 = READ_ONLY 0x038000 TO 0x03BFFF; PAGE already contained in segment at 0xC000-0xFFFF */
END
PLACEMENT /* Here all predefined and user segments are placed into the SEGMENTS defined above. */
DEFAULT_RAM, /* non-zero page variables */
INTO RAM;
_PRESTART, /* startup code */
STARTUP, /* startup data structures */
ROM_VAR, /* constant variables */
STRINGS, /* string literals */
VIRTUAL_TABLE_SEGMENT, /* C++ virtual table segment */
NON_BANKED, /* runtime routines which must not be banked */
DEFAULT_ROM,
COPY /* copy down information: how to initialize variables */
INTO ROM; /* ,ROM1,ROM2: To use "ROM1,ROM2" as well, pass the option -OnB=b to the compiler */
PAGED_ROM /* routines which can be banked */
INTO PPAGE_2,ROM1,ROM2;
_DATA_ZEROPAGE, /* zero page variables */
MY_ZEROPAGE INTO Z_RAM;
END
STACKSIZE 0x80
VECTOR 0 _Startup /* Reset vector: this is the default entry point for an application. */
main 函数代码如下,目的是希望把main 函数放到 PAGED_ROM中,也就是PPAGE_2 = READ_ONLY 0x02A000 TO 0x02BFFF; 编译链接都没有问题,可是不能运行,求解
void MCU_init(void); /* Device initialization function declaration */
#pragma CODE_SEG PAGED_ROM
void main(void)
{
MCU_init(); /* call Device Initialization */
InitinalLCD();
/* include your code here */
for(;;)
{
/* __RESET_WATCHDOG(); by default, COP is disabled with device init. When enabling, also reset the watchdog. */
} /* loop forever */
/* please make sure that you never leave main */
}
#pragma CODE_SEG DEFAULT
在map文件中也看到了main被分配到了0x2A000位置。可是不能够运行,提示:could not set the breakpoint at 0x2A000
|
|