cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L031x6 custom bootloader

Harry Tsang
Associate II
Posted on March 27, 2018 at 16:07

Hello!  I manage to write a custom boot loader in STM32L031E6 using I2C interface.  To do so, it requires the MCU to provide at least the following features:

1. Reallocation of vector table

2. API functions for internal flash read/write/erase

For (1), I know the there is a vector register VTOR available in STM32L031E6 to reallocate vector table.  However, I cannot find any information of (2).  Could anyone advise how can I do and anything I have missed out?  Many Thanks!

2 REPLIES 2
Posted on March 27, 2018 at 17:21

Use the HAL functions provided in the libraries and review the examples

stm32l0xx_hal_flash.c

stm32l0xx_hal_flash_ex.c

stm32l0xx_hal_flash_ram.c

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on May 07, 2018 at 07:55

Thanks for your information.  I am finally able to write my own bootloader using the libraries as you mentioned.