Copy and execution of a routine at runtime for cortex-m0 architecture

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

Copy and execution of a routine at runtime for cortex-m0 architecture

561 Views
angelocalabrese
Contributor I

I'm developing a bootloader. I need to receive the flash erasing and writing routines from an external channel (via CAN). So I need to copy and then perform these routines in RAM. The prototypes of these routines are as follows:
uint16_t FLASH_Program (uint32_t wNVMTargetAddress, uint8_t * pData, uint16_t sizeBytes);
uint16_t FLASH_EraseSector (uint32_t wNVMTargetAddress);
How can I do it?

Tags (1)
0 Kudos
2 Replies

451 Views
bobpaddock
Senior Contributor III

I posted some of the related Flash code in this thread a while ago:

https://community.nxp.com/message/577798?commentID=577798#comment-577798 

The 'Copy' code is in the attached startup and linker files.

Real Soon Now I'm going to write a book with all of this stuff in it,

that should have been in Freescale/NXP documentation in the first place...

0 Kudos

450 Views
jingpan
NXP TechSupport
NXP TechSupport
0 Kudos