cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L011 bootloader cannot read SRAM

Robin_Iddon
Associate

I have an STM32L011 on a board I am developing.

I can enter the bootloader no problem, as per AN2606/AN3155.  I am using USART2, 57600 baud.

I can program FLASH/erase FLASH/read FLASH - all works as expected.

I note that the bootloader reserves 2048bytes of SRAM, I assume it's the addresses 0x2000_0000 .. 0x2000_07FF.

When I try to use the memory read command to read from anywhere in SRAM (whether the bootloader reserved area or any other address) I get a NACK just after the address+xor-check-byte.

I believe the protocol is correctly implemented because the same thing works reading from FLASH addresses (e.g. 0x0800_0000).

Is there a known issue here (I have seen other posts on this forum with similar problems on other STM32 parts - but these are either unresolved or they are trying to read from the reserved SRAM which is expected to be NACK'd).

 

1 ACCEPTED SOLUTION

Accepted Solutions
STOne-32
ST Employee

Dear @Robin_Iddon ,

Your observation is correct and is mentioned in AN2606 here 

https://www.st.com/resource/en/application_note/an2606-stm32-microcontroller-system-memory-boot-mode-stmicroelectronics.pdf#page289

IMG_9232.jpeg

IMG_9231.jpeg

 so All RAM zone will be Nacked by any Write /Read or Go command on STM32L011 devices.

Hope it helps you 

STOne-32

View solution in original post

2 REPLIES 2
STOne-32
ST Employee

Dear @Robin_Iddon ,

Your observation is correct and is mentioned in AN2606 here 

https://www.st.com/resource/en/application_note/an2606-stm32-microcontroller-system-memory-boot-mode-stmicroelectronics.pdf#page289

IMG_9232.jpeg

IMG_9231.jpeg

 so All RAM zone will be Nacked by any Write /Read or Go command on STM32L011 devices.

Hope it helps you 

STOne-32

Robin_Iddon
Associate

Thanks - we use L03x for some of our code development and had lost track of the fact that the L01 has only 2K of SRAM!

It would be nice if that was more clearly stated in the other sections of the manual ... it's easy to lose track of which parts have only 2K and which parts have more SRAM.   For example on page 289 in the L0 SRAM section where it shows 2K are used by bootloader, it could say "see Table 196, L0 section, to determine how much, if any, SRAM is available for user read/write."