把代码放到RAM,不使用片内FLASH。RAM分两段分别放程序代码、数据区。
修改为:
RAM2.ini
/******************************************************************************/
/* RAM.INI: RAM Initialization File */
/******************************************************************************/
// <<< Use Configuration Wizard in Context Menu >>> //
/******************************************************************************/
/* This file is part of the uVision/ARM development tools. */
/* Copyright (c) 2005-2007 Keil Software. All rights reserved. */
/* This software may only be used under the terms of a valid, current, */
/* end user licence from KEIL for a compatible version of KEIL software */
/* development tools. Nothing else gives you the right to use this software. */
/******************************************************************************/
FUNC void Setup (void) {
SP = _RDWORD(0x20000000); // Setup Stack Pointer
PC = _RDWORD(0x20000004); // Setup Program Counter
// _WDWORD(0xE000ED08, 0x20000000); // Setup Vector Table Offset Register
}
LOAD ramout\164.axf INCREMENTAL // Download
Setup(); // Setup for Running
g, main
点Load下载,调试成功。