Skip to main content
高健一.1
Visitor II
June 1, 2020
Question

STM32CubeMX can't recognize the flash size correctly and the debugger won't start

  • June 1, 2020
  • 12 replies
  • 6754 views

[ The text uses a translation tool. ]

Flash size is the default and no more programs can be loaded.

environment

Windows10 + STM32CubeMX + ST-Link2

************** Console log

     -------------------------------------------------------------------

                      STM32CubeProgrammer v2.4.0                 

     -------------------------------------------------------------------

ST-LINK SN : 53FF6D064882505226101587

ST-LINK FW : V2J36S7

Voltage    : 3.23V

SWD freq   : 4000 KHz

Connect mode: Under Reset

Reset mode : Hardware reset

Device ID  : 0x436

Device name : STM32L15xxD/STM32L162xD

Flash size : 128 KBytes (default)

Device type : MCU

Device CPU : Cortex-M3

Memory Programming ...

Opening and parsing file: ST-LINK_GDB_server_a20796.srec

 File         : ST-LINK_GDB_server_a20796.srec

 Size         : 137888 Bytes

 Address      : 0x08010000

Erasing memory corresponding to segment 0:

Error: Operation exceeds memory limits

Error: failed to erase memory

Encountered Error when opening C:\ST\STM32CubeIDE_1.3.0\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_1.3.0.202002181050\tools\bin\STM32_Programmer_CLI.exe

Error in STM32CubeProgrammer

Debugger connection lost.

Shutting down...

*************

I'm using an STM2L151DTx, so there's plenty of flush

Why is it [Flash size: 128 KBytes (default)]?

The STM32 ST-LINK Utility can be recognized and written normally.

Am I doing something wrong?

This topic has been closed for replies.

12 replies

herca.1
Associate II
August 17, 2021

Hello,

Using 2.8.0 and using STM32L15xx microcontroller

This is the output of Cube Programmer. Verbosity level 3. Is this also fixed for CubeMX IDE, I want to be able to debug my software.

 14:40:51:303 :  Size     : 263956 Bytes

 14:40:51:303 :  Address    : 0x08000000 

 14:40:51:303 : Erasing Segment <0> Address <0x08000000> Size <263956>Bytes

 14:40:51:303 : Erasing memory corresponding to segment 0:

 14:40:51:303 : Memory erase...

 14:40:51:322 : halt ap 0 

 14:40:51:322 : w ap 0 reg 15 PC  (0x20000000)  

 14:40:51:331 : w ap 0 reg 17 MSP (0x20000500)  

 14:40:51:331 : w ap 0 reg 16 xPSR (0x01000000)  

 14:40:51:336 : w ap 0 @0x20000E20 0x00000200 bytes Data 0x00000000

 14:40:51:336 : w ap 0 @0x20000000 0x00000004 bytes Data 0x0000BE00

 14:40:51:362 : w ap 0 @0x20000004 0x000009EC bytes Data 0xF8DFB580

 14:40:51:363 : Error: Operation exceeds memory limits

 14:40:51:381 : Error: failed to erase memory

herca.1
Associate II
September 22, 2021

WHEN WILL YOU FIX THIS ISSUE????????????????????????????????