Multiple memory regions

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Multiple memory regions

678 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SolomonViveros on Thu May 05 13:46:14 MST 2011
So after following the directions outlined by the usb bootloader I can successfully create a custom linkscript...what I'd like to do now is create multiple memory regions and have folders within my project compile to what region I decide. Do I edit my myprog_mem.ld file with something as follows?

  MFlash512 (rx) : ORIGIN = 0x0, LENGTH = 0x40000
  MFlashRegion2 (rx) : ORIGIN = 0x40000 , LENGTH = 0x20000
  MFlashRegion3 (rx) : ORIGIN = 0x60000 , LENGTH = 0x20000
  RamLoc32 (rwx) : ORIGIN = 0x10000000, LENGTH = 0x8000 /* 32k */
  RamAHB32 (rwx) : ORIGIN = 0x2007c000, LENGTH = 0x8000 /* 32k */

}
  /* Define a symbol for the top of each memory region */
  __top_MFlash512 = 0x0 + 0x40000;
  __top_MFlashRegion2 = 0x40000 + 0x20000;
  __top_MFlashRegion3 = 0x60000 + 0x20000;
  __top_RamLoc32 = 0x10000000 + 0x8000;
  __top_RamAHB32 = 0x2007c000 + 0x8000;


If I group some *.c files in a folder -- is it possible to assign that folder one of the specific flash regions? If so, how?
0 Kudos
Reply
2 Replies

665 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SolomonViveros on Thu May 05 17:16:37 MST 2011
In effort to answer my own question but not without passing on the trail to the solution, I expect the following to be where the answer resides:

http://support.code-red-tech.com/CodeRedWiki/EnhancedManagedLinkScripts
0 Kudos
Reply

665 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by SolomonViveros on Thu May 05 15:23:53 MST 2011
Similar question with a solution would appear to be the following:
http://knowledgebase.nxp.com/showthread.php?t=1775&highlight=text+segment
0 Kudos
Reply