Skip to main content
Dhanyakumar Hosamane
Associate II
July 22, 2017
Question

Jumping to ST ROM Bootloader from user flash on STM32L073

  • July 22, 2017
  • 11 replies
  • 3721 views
Posted on July 22, 2017 at 13:03

Hi

STM32L073RZ supports dual bank mechanism. Dual-bank boot capability allowing to boot either from Bank 1 or Bank 2 at startup based on BOOT pins. However, I need to jump to system boot loader from user flash using simple address based mechanism to allow the user to upgrade new code on to flash memory.

Configuration

BOOT0 pin tied to 0

Using BANK 1 flash memory

Issue

On jumping to system memory from BANK 1 Flash, control (PC) returns to BANK1 flash start address as code BANK1 code is not valid. But I wanted to control to stay in system bootloader to upgrade flash memory

Is there any way to jump to system boot loader from BANK1 user flash?

#stm32l073 #stm32lo #dual-bank #system-bootloader #bootloader-rom
This topic has been closed for replies.

11 replies

Tesla DeLorean
Guru
July 22, 2017
Posted on July 22, 2017 at 14:17

>>

Is there any way to jump to system boot loader from BANK1 user flash?

I'd assume it is possible, you might have to review the code in the ROM and determine what it is looking for, and how the memory shadowing is configured.

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
Dhanyakumar Hosamane
Associate II
July 23, 2017
Posted on July 23, 2017 at 05:17

Hi Clive

I appreciate you for the quick response.

ROM bootloader code is written by ST, will I get access ROM boot loader code? if so can you please guide me the procedure to get ROM bootloader code.

As per my understanding so far (after going through AN2606), bootloader looks for code validity on the flash bank (both 1 & 2) and jumps back to flash code if the flash code is valid. because of this dual bank mechanism control immediately switches bank to bank 1 as it has valid code.

I am looking a way to that make system bootloder to continue its execution even if it finds the valid code on the flash bank when BOOT0 pins is tied to low.

Here is the snapshot of dual bank boot mechanism from AN2606 for STM32L073XX

0690X00000603yNQAQ.jpg
Tesla DeLorean
Guru
July 23, 2017
Posted on July 23, 2017 at 15:42

>>

ROM bootloader code is written by ST, will I get access ROM boot loader code?

But it is on every part, you could disassembly/analyze, determine an entry point for functionality.

If updating your own code, consider coding a loader to achieve that.

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..