Content originally posted in LPCWare by CodeRedSupport on Thu Nov 25 16:39:38 MST 2010
The problem is the data in your .noinit section located at address 0x10000004. This is a RAM address, yet the section attributes in the ELF file suggest to our loader it's writable. Based on the chip attributes, we know there's no flash there, so we emit an error. If it's really a noinit section, then perhaps you need to redefine the section attributes (e.g. .bss). I don't have your source to know where this section originates. Otherwise, you'll need to treat the .noinit section like the .data section . Any initialized values in .data are copied from flash to RAM at a runtime. See the ResetISR code in the Code Red startup.
Note the reason it seems to work under debug, is the debug environment has intervened and issued a RAM write command for the .noinit contents. A flashed application has to resolve all initialization details, without such intervention.