Bootloader puzzle...

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

Bootloader puzzle...

449 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by DT1 on Fri Jan 17 13:58:11 MST 2014
Hi,

I'm currently developping an application on the LPC4357. I need to implement a bootloader and to be honest I'm not sure where to start for a NXP MCU. I have limited experiences with bootloader in general.

The ideal scenario for me would be this:

- The user puts the new firmware on the embedded file system using USB Mass Storage.
- On reset, the bootloader verify the embedded file system; if a firmware application file is present, it copies it into internal Flash at the firmware application address.
- Upon copy completion, the bootloader jumps to the application memory address and the application starts
- The application deletes the firmware application  file present on the file system.

I've searched around and couldn't find any examples that would guide me a little to achieve that (from the bootloading point of view, not the file system or USB one).

Anybody has a suggestion for the addressing, examples, comments on how it would be best to implement that ?

Thanks!
Labels (1)
0 Kudos
3 Replies

364 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by MarcVonWindscooting on Mon Feb 10 10:39:15 MST 2014
Hi DT1,

I'm a beginner with LPC43xx, too.
As far as I can see, the appnote applies to the LPC43xx. Because the M0 isn't running if you don't start it. The 'M4 bootloader' can write both his own FLASH area and the FLASH intended for the M0's use. It seems, we're relatively free in choosing the locations of the code for the two processors - even if a (bad) choice would lead to a poor performance.

I appreciate your reluctance to put the M0 code somehow into the M4's. I read something like: "Building an application for the LPC43xx is in fact two projects...". I disagree with that. I want to share (slow) code between the two if I like to. However, I haven't managed to create a suitable development environment, yet. Still struggling. It's much more difficult compared to single cores or even 2 identical cores.
0 Kudos

364 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by DT1 on Mon Jan 20 09:11:24 MST 2014
Thanks, that helps a lot. It's indeed a great starting place. This will work well with the LPC435x right? (2 cores, etc.)

If I want the same secondary bootloader (running on the M4) to IAP my M4 application and my M0 application, it is possible to read/write to those two Flash from the M4 right? OR do I need 2 different bootloaders?

I've seen examples of the M0 being programmed from a generated .c file that is built in the M4 application, but that's not viable in my project. That's why I wonder if the M4 secondary bootloader can IAP the application code of the M0.

Thanks!
0 Kudos

364 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by mc on Fri Jan 17 16:02:36 MST 2014
Hi DT1,
Please see application link below for LPC175x_176x. You will have an idea after reading  application note available at below link.

http://www.lpcware.com/content/nxpfile/an10866-lpc1700-secondary-usb-bootloader
0 Kudos