cancel
Showing results for 
Search instead for 
Did you mean: 

Trouble generating linker

JonConesa
Associate II

Hi,

I’m encountering an issue with linker file generation in STM32CubeMX for the STM32H56VGTX MCU. When I generate the code using CubeMX, it produces linker files configured for the STM32H563xx family, which has 2048 kBytes of Flash memory. However, the STM32H56VGTX has only 1024 kBytes of Flash memory.

I’ve attached the linker files in .txt format that CubeMX generates for reference.

 

Does anyone know why this happens? I understand that I can manually adjust the linker file to resolve the issue, but I’d prefer to fix the problem with the automatic generation to avoid potential issues and errors in the future.

 

Thank you in advance.

1 ACCEPTED SOLUTION

Accepted Solutions

Hello,

Ok thank you for this remark.

I'm escalating internally this behavior and get back to you as soon as I have an answer.

Internal Ticket 189406 not accessible by the community users.

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

View solution in original post

3 REPLIES 3
SofLit
ST Employee

Hello,

I was not able to reproduce the issue. This is a part of linker file content generated with CubeMx V6.12.0 for STM32H563VGTx:

/* Memories definition */
MEMORY
{
  RAM    (xrw)    : ORIGIN = 0x20000000,   LENGTH = 640K
  FLASH    (rx)    : ORIGIN = 0x08000000,   LENGTH = 1024K
}

The Flash is 1M and not 2M.

Attached the ioc file used to generate the linker file. Could you please check again? what CubeMx version are you using?

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

 

Hi,

I’ve found how to replicate the issue. If I generate the linker file directly from your .ioc file, everything works fine. However, when I switch the Toolchain/IDE to Makefile, the linker file generation is incorrect, producing a generic one.

What can I do to fix this? 

Screenshot 2024-08-26 at 11.19.21.png

Hello,

Ok thank you for this remark.

I'm escalating internally this behavior and get back to you as soon as I have an answer.

Internal Ticket 189406 not accessible by the community users.

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.