Bootloader and OTA upgrade

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

Bootloader and OTA upgrade

3,199 Views
davidrozenski
Contributor I

Let me explain our application :

We have designed our own board based on RT1052 with external QSPI Flash, we want to have 2 applications in a flash the first one that will call Bootloader which will run in the bottom part of flash 0x60000000 and started as a XIP application by RomCode, this Bootloader will look if some NEW upgrade is ready for the main Application located in the upper side of flash let say 0x60010000, and doing some upgrade if necessary and jump after to this main application.
What we have done now:

- The core of the Bootloader running as XIP located in 0x60000000, with the correct LUT and so and just flashing a led.

What we failed now is the jumping part from this Bootloader application to the main application in upper side.

Our question are :

1) when compiling the Main Application we put Flash Starting adress at 0x60010000 which is our final flash target, we also put XIP_EXTERNAL_FLASH=1 and XIP_BOOT_HEADER_ENABLE=0 these are correct ? 

2) How in our bootloader application we can know the jumping address of our main Application ? is 0x6001000 ?

3) Entering in our Main application (coming from bootloader) do we have to relocate SCB->VTOR if yes where we can get the value of the relocation ?

Is there any simplest way to achieve what we want to do ?

Best Rgds

David

Labels (1)
Tags (1)
0 Kudos
4 Replies

2,449 Views
greg_nowak
Contributor III

Has this question ever been answered?

I'm trying to do the exact same thing and I'm not sure I understand WHY the RT-1050 doesn't support a Flash resident bootloader launching an application that is also in flash.

I have the same situation where I'd like to run an RT-1050 with a bootloader (XiP, encrypted, in external QSPI flash) and have that bootloader launch an application at some known address, also XiP, encrypted, in the same external QSPI flash.

0 Kudos

2,449 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hello David,

    RT1050 doesn't support the function you want.

    But RT1060 can meet your requirement.

    So please evaluate RT1060!

Have a nice day!

BR,

Weidong Sun

0 Kudos

2,449 Views
anton_glukhov
Contributor III

Hello weidong.sun,

could you clarify if it's possible for rt1011 or rt1015 MCUs? If not, then could you, please, advice how to update the application code in production? We would like to use USB MSD with ram disk to update the app on the QSPI flash. Is it somehow possible to have 2 banks (just different addresses in SPI flash, i.e. 0x60000000 and 0x60010000) of the app and choose the one during the bootup?

I found utasker, which seems to work as XIP, but it has to load the application into RAM. The problem is, we would like to run the application also as XIP(because of the size of application is bigger than RAM). What other options NXP suggests? Is it possible to have any bootloader, that can somehow run the application from XIP?

Thank you!

Best regards,

Anton

0 Kudos

2,450 Views
kingchen-2019
Contributor I

Hi Weidong,

It means that it is easy switch two application software by RT1060 flash remapping function without user bootloader.

Is that right?

Referring to https://www.nxp.com/docs/en/application-note/AN12255.pdf, are there no need user bootloader switch two application by OTA?

Note: user bootloader are the same with IAP bootloader.

Thanks,

KingChen

0 Kudos