cancel
Showing results for 
Search instead for 
Did you mean: 

STM32CubeProgrammer v2.8.0 detects the wrong flash size for the STM32L152VDT6X causing the programming to fail

AMT
Associate

The STM32L152VT6X has 384KBytes of flash memory, but the STM32CubeProgrammer detects the flash size as being 128KB. When I try to flash an image of ~170KB it fails with the error "Operation exceeds memory limits". When I flash the same image with the STLINK Utility it flashes successfully.

The first image is from the stlink utility and the second is from STM32CubeProgrammer

0693W00000DnnbRQAR.png0693W00000DnnbGQAR.png

1 ACCEPTED SOLUTION

Accepted Solutions
Houda GHABRI
ST Employee

Hello @AMT​ ,

This issue was fixed in another L1 family (L1 have many device ID) , in next release it will be fixed also for 0x436 device ID .

In meanwhile, to solve the problem I attach the modified STM32_Prog_DB_0x436.xml file with correct value .

Can you please replace the xml file in your database : STM32CubeProgrammer_2_8_0\Data_Base\STM32_Prog_DB_0x436.xml by this one and tell me if it is Ok?

When your question is answered, please close this topic by choosing Select as Best. This will help other users find that answer faster.

Houda

View solution in original post

14 REPLIES 14
TDK
Guru

Known issue:

https://community.st.com/s/question/0D53W000008kLHnSAM/stm32cubemx-cant-recognize-the-flash-size-correctly-and-the-debugger-wont-start

The issue was reported as fixed in v2.8.0 by @Houda GHABRI​ (but it doesn't appear to be fixed).

If you feel a post has answered your question, please click "Accept as Solution".

The issue still exists, I tested with v2.8.0 on Linux. See screenshot.0693W00000DnqVuQAJ.png

Piranha
Chief II

Putting 2 and 2 together is not a simple task. It's only more than a year since the bug was reported and they have tried to fix it only two times!

Houda GHABRI
ST Employee

Hello @AMT​ ,

This issue was fixed in another L1 family (L1 have many device ID) , in next release it will be fixed also for 0x436 device ID .

In meanwhile, to solve the problem I attach the modified STM32_Prog_DB_0x436.xml file with correct value .

Can you please replace the xml file in your database : STM32CubeProgrammer_2_8_0\Data_Base\STM32_Prog_DB_0x436.xml by this one and tell me if it is Ok?

When your question is answered, please close this topic by choosing Select as Best. This will help other users find that answer faster.

Houda

Houda GHABRI
ST Employee

Please find the STM32_Prog_DB_0x436.xml file fixing the issue

Souan.1
Associate II

im on windows , where do you replace this file? , i only have an application file . can you please post screenshots on how to do it?

Going to be in one of the Program Files sub-directories, or wherever you chose for the install directory.

Guess something like:

C:\Program Files (x86)\STMicroelectronics\STM32Cube\STM32CubeProgrammer\Data_Base

Break out the file manager.. Perhaps open a command console with Admin Rights so you can change the files.

Alternatively UNINSTALL the tools, and then reinstall at a different directory within your user space you can access/modify.

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

When will be the next release? When will we be able to debug in CUBE IDE? Do you have a rough estimation?

Hello @Houda GHABRI​ 

i have replaced the xml file as described in your post. Now the Cubeprogrammer recognizes the flash size correctly.

But it's still not possible to erase, program or write OB. Reading out the entire memory works without any problems.