cancel
Showing results for 
Search instead for 
Did you mean: 

Dual Bank Linker script for STM32G474CB

SMisi
Associate II

Hello

I have a project with STM32G474CB in CubeMX and it generates the linker script with following: 

 

MEMORY
{
  RAM    (xrw)    : ORIGIN = 0x20000000,   LENGTH = 128K
  FLASH    (rx)    : ORIGIN = 0x8000000,   LENGTH = 128K
}

 

But, as I understand, this is only the case when the device is switched into single-bank mode (which is not the default from the manufacturer!). The default would be two 64K flash chunks with second being at offset 0x08040000, am I correct?

Thanks.

1 REPLY 1
Ghofrane GSOURI
ST Employee

Hello @SMisi 

On this, the RM0440 clearly states they're consecutive in single bank mode.

Your question is answered nicely by ST here:

https://community.st.com/s/question/0D50X0000BrDcCsSQK/flash-layout-of-stm32g4xx-cat-3-with-less-than-512-kbyte-missing-in-rm0440

The STM32CubeMX generated script is correct for single bank mode.

THX

Ghofrane

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.