programming flash using .elf file

cancel
Showing results for 
Search instead for 
Did you mean: 

programming flash using .elf file

374 Views
Contributor II

Hello Everyone,

 

I am using MK60FX512 controller, CW10.6 & MQX4.1.

Also I am using FlexEEPROM (did the partition).

If I programmed the flash with .elf file through flash programmer, flash is programmed successfully but application code doesn't execute.

and if I programmed flash with another .elf file (the code without EEPROM),application code runs successfully.

 

Please help me to resolve this problem.

 

 

Thanks.

Labels (1)
0 Kudos
6 Replies

6 Views
Contributor II

Hello Everyone,

As per my previous (above) post I have checked that through debug in MQX4.1 FlexNVM is partitioned for EEPROM backup & D-flash but the same .s19 file if I programmed through flash programmer, through flash programmer FlexNVM is not partitioned for EEPROM backup & D-flash. Controller is getting reset everytime.

I have tested with processor expert and through debug & flash programmer able to partition device for flexEEPROM backup & D-flash.

Please help me to solve this.

Thanks.

0 Kudos

6 Views
NXP Employee
NXP Employee

Hi T tech,

Please take a look to the following post, it believe it is related to your question:

Re: Partitioning of Kinetis K50 with PE Multilink Universal

Hope it helps!

Best Regards,

Carlos Mendoza

Technical Support Engineer

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

0 Kudos

6 Views
Contributor II

Hi Carlos,

Please let me know should I use interrupt disable / enable routines or there is any other way to partition FlexNVM through flash programmer.

Thanks.

0 Kudos

6 Views
NXP Employee
NXP Employee

Hello T tech,

Yes, you should use those functions to mask any possible core accesses to vector table or interrupt service function in flash, we recommend to keep to a minimum the code between these calls.

Another way for partitioning the Flash is to use the CodeWarrior debugger which includes a command to partition the flash.

Hope it helps!

Best Regards,

Carlos Mendoza

Technical Support Engineer

-------------------------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-------------------------------------------------------------------------------------------------------------------------------------

6 Views
Contributor II

Hi Carlos,

Thanks for the reply..

0 Kudos

6 Views
Contributor II

Hi Carlos,

Thanks for your reply.

As per the post Re: Partitioning of Kinetis K50 with PE Multilink Universal

it is said its not possible to do partitioning using flash programmer we have to do it in application code.

I have already done it in my application code,but once it runs the partitioning code due to OS interrupts controller is reset because of this reason I am not able to do partitioning through application code, then I used disable interrupt routine as below and my code worked properly through flash programmer also.

__disable_interrupt();

error = Cpu_SetFlexNVMPartition();

Cpu_SetFlexRAMFunction(FlexRAM_AS_EEPROM);

__enable_interrupt();

I am not sure that should I use enable/disable interrupt since it disables the OS interrupt.

Please let me know is it ok to use enable/disable interrupt routines

Thanks.

0 Kudos