Best way to create a custom memory layout?

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by amrbekhit on Wed Nov 02 15:06:41 MST 2011
Hello all,

I'm porting an existing LPC1752 project from Keil to LPCXpresso 4.1. The is less straightforward than usual because I have a custom memory layout:

///Flash Memory
///0xF0000xFFFF0x1000Flash Settings
///0x100000000x10003FDF0x3FE0Application RAM
///0x10003FE00x10003FFF0x0020IAP RAM

It's very easy to implement this memory layout in Keil since the Target dialog box allows you to specify the RO and RW memory ranges directly without having to dive into linker scripts or anything like that. For this project, my ROM starts at 0x2000 and is 0xD000 bytes in size, and my RAM starts at 0x10000000 and is 0x3FE0 bytes in size.

My question is what is the best way to implement this memory layout in LPCXpresso? Reserving the RAM needed for the IAP routines is easy, since there is an FAQ on the subject on the wiki. My main issue is with the ROM layout as I couldn't find any example on the wiki on how to reserve areas of flash. According to the Enhanced Managed Linker Script page on the Wiki, the enhancements are designed to reduce the occurrences where one needs to turn off the feature and take direct control over the linker scripts. Is it possible for me to configure my flash layout without having to manually create my own linker script?