This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Program runs in dbg mode but not on the chip

I am using a LPC2214. The BOOT pins are set to 11 for internal flash boot.

I am using the internal ram for data and the internal flash for code.

I wrote a simple program that just configures the XCLK pin and changes the frequency on that pin.

When I download it to the flash, nothing happens. Even when I reset the chip.

When I enter debug mode and run the program everything works. If I disconnect the JTAG device it still runs. If I hit reset the program then stops running.

When using the debugger am I really running code out of the flash or is it mapped to RAM?

Anyone have any idea on whats happening?

The hex file that is created has the correct instructions.

Is there any way to read the flash after using the Keil LPC2000 IAP 256K algorithm for programming?

I use the following file for debug initialization:

FUNC void Setup (void) {
// <o> Program Entry Point
  PC = 0x00000000;
// <o1.0..1> MEMMAP: Interrupt Vector maps to: <0=> Boot Block
//<1=> On-Chip Flash
//<2=> Static RAM
//<3=> External Memory
_WDWORD(0xE01FC040, 0x00000001);

}
Setup();       // Setup for Running
LOAD IFLASH/SPI INCREMENTAL
PC = 0x00000000
g, main

0