Running SDK flash routines from RAM

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

Running SDK flash routines from RAM

1,287 Views
ambarishhundeka
Contributor III

Hello NXP ,

Thank you in advance for your help.

We are using S32K144 in our project.

I have tested the SDK flash driver and successfully erase and write the Flash memory.

I have build the SDK Flash Driver  excluding startup and changed the entry point from reset handler to main in linker file.

converted the elf file to hex file.

created the one more project and place the hex bytes(flash routines) to array(array is located to same segment which I used the code area for Flash driver routines hex file creation) and try to jump to the start of the array. it is throwing an exception.

same thing I followed for toggling the LED project by using timer , it is working fine but not flash drivers.

Instead of calling LED function inside the main, I call the some other function which has input arguments and create the hex file.

I placed the  HEX values to array and jump, then also it through exception.

just need to understand the is there any conditions to run the code from RAM?

please let us know the solution early as early as possible.

Thanks & Regards,

Ambarish.

0 Kudos
2 Replies

1,081 Views
jiri_kral
NXP Employee
NXP Employee

Hi, 

may be it is stupid question - by HEX file you mean the binary (.bin) file? The .hex file is text file. You need to convert ascii character doublets representing HEX value into binary data. 

Can you please share your project and the data file? 

Jiri

0 Kudos

1,080 Views
ambarishhundeka
Contributor III

Hello Jiri,

Sorry . Yes it is bin file.

please find the attachment .

you can find the three folders inside the source code.

1. normal debug test code (flash driver code & blink code)

2. Test code excluding the startup and changed the entry point in linker file(build the only application part).

3. Test app (here placed the bin of application in array and array is located at the RAM segment ).(execute the app from RAM).

Regards,

Ambarish

0 Kudos