How does it work when image bigger than programmable flash?

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

How does it work when image bigger than programmable flash?

Jump to solution
847 Views
tonymakkiel
Contributor III

Hi All,

          I am a bit confused. The image 'elf file' is 319,831 bytes. But as per the description for KL43Z48M, it should only have 256KB (262,144 bytes) memory.  But yet the board boots and run. How does that work?

Many Thanks,

Tony

Labels (1)
Tags (1)
0 Kudos
1 Solution
666 Views
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, Tony,

The *.lef file is not an image in binary format which is copied to flash byte by byte, the *.elf contains a lot of debugging information, that is why it is large.

I attach the doc about the format of *.elf file.

Hope it can help you.

BR

XiangJun Rong

View solution in original post

0 Kudos
4 Replies
667 Views
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, Tony,

The *.lef file is not an image in binary format which is copied to flash byte by byte, the *.elf contains a lot of debugging information, that is why it is large.

I attach the doc about the format of *.elf file.

Hope it can help you.

BR

XiangJun Rong

0 Kudos
666 Views
tonymakkiel
Contributor III

Thank you XiangJun Rong,

Is there an api (similar to NVIC_SystemReset) which can be used from the application to reset the board to (ROM) bootloader mode? I know there is a boot pin. But would like to do it from the application, if possible.

0 Kudos
666 Views
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi, Tony,

I think the software reset is the only way you can use in your application code to reset the processor and run from bootloader ROM, in other words, you can call the NVIC_SystemReset() api function to software reset the chip. If you want to use bootloader, you have to set the other register and flash, for example, the BCA block, FOPT register, RCM_MR register.

For detailed inf, pls refer to section 13.3 Functional Description in the reference manual of KL43.

Hope it can help you

BR

XiangJun Rong

0 Kudos
666 Views
tonymakkiel
Contributor III

Hi XiangJun Rong,

             Thank you for the pointer. Before I start putting the board in bootloader mode, with application would like to make sure blhost works with the board. I tried manually putting the board in bootloader mode (inserted usb on J8 with reset button SW1 pressed). I have RS232 connected to TWR_SER board. But for some reason cant get blhost to work.

./Release/blhost -p /dev/ttyUSB0 -d get-property 1

[5a a6]

<stuck here>

What is the default baudrate ROM will be listening?

Many Thanks,

Tony

0 Kudos