斑竹,给您看看我的操作;我的片选/CS1。外扩地址范围20_0000到24_FFFF。
SEGMENTS
。。。。。。
extern_ram = READ_WRITE 0x200000'G TO 0x24FFFF'G ;
END
PLACEMENT
。。。。。。
MY_RAM INTO exter_ram ;
END
main.c
#pragma DATA_SEG __GPAGE_SEG MY_RAM
unsigned char buffer[100]; /* this variable will be allocated in segment GLOBAL_RAM through the GPAGE register */
#pragma DATA_SEG DEFAULT
这样操作有问题吗? |