cancel
Showing results for 
Search instead for 
Did you mean: 

OTP and option bytes flash banks

Jules Patru
Associate
Posted on February 15, 2018 at 08:33

Hello

I am developing some project using STM32L4xx microcontroller.

In technical reference manual, the chapter describing how the Flash memory behaves explains that these micro have two Flash banks. It also says that RWW operations are allowed. Thus I can use our own bootloader that sits in Bank1 to erase/write data in Flash Bank2.

In TRM §3.3.1, I can also read that Option bytes are splitted between Bank1 and Bank2 and that OTP memory is in Bank1.

Does this mean that my bootloader that sits in Bank1 can NOT write something in OTP memory?

Could you please clarify this please?

Thanks !

1 REPLY 1
Doug Kehn
Senior
Posted on February 15, 2018 at 15:26

If my understanding is correct, OTP memory can be written by code executing from Bank1. However, the MCU will stall while the OTP operation is in progress.