memory layout / ram offset

03 Jan 2016

What is the reason for the offset of 0xC0 at the begin of the physical RAM segment? I have used the mbed lib offline with the LPCXpresso for the LPC1347. After a few modifications this worked, but the projects showed strange runtime behaviour. The reason was the 'managed linker script' that I used, there was this offset for the RAM missing. But it took me a long time to find this hidden stuff, it is not mentioned in the 'memory model' handbook page.

03 Jan 2016

The interrupt vector table is copied to this range to be able to use dynamic interrupt vectors.

03 Jan 2016

Thanks for your quick reply! Is this copy managed in the mbed lib? As I understand there is no action necessary in the startup code.

04 Jan 2016

Yes, it is done here: https://developer.mbed.org/users/mbed_official/code/mbed-dev/file/dfc7461ac1b6/targets/cmsis/TARGET_NXP/TARGET_LPC13XX/cmsis_nvic.c

The first time the NVIC_SetVector code is called it will notice that the interrupt vector table which is in the flash is used is currently used, and it will copy that vector to RAM and use the new RAM vector instead.