Skip to main content
Associate
September 1, 2024
Question

I am using TouchGfx on STM32H747I-DISCO board. My final binay size is 2.13 GB

  • September 1, 2024
  • 3 replies
  • 1193 views

Default Image Configuation setting is :

shiv50084_0-1725195872774.png

Framework Features:

shiv50084_1-1725196429404.png

Size of .bin file 

shiv50084_2-1725196553300.png

Touch Gfx setting in IOC file:

shiv50084_3-1725196672067.png

 

I also followed the link:

https://community.st.com/t5/stm32-mcus-products/generated-binary-file-size-is-too-large-2-3gb/td-p/300719

 

But still size is 2.13 GB.

 

Can you please help me to reduce the size of binary?

@UtkrantiYantra 

 

 

3 replies

Tesla DeLorean
Guru
September 1, 2024

Don't use a .BIN to describe two regions with large separation within the ARM's 4GB address space.

Use a .HEX, or divide into two or more .BINs describing the 0x08000000 and 0x90000000 regions separately.

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
shiv50084Author
Associate
September 1, 2024

@Tesla DeLorean 

I am using this command 

arm-none-eabi-objcopy.exe -O binary --only-section=ExtFlashSection "${BuildArtifactFileBaseName}.elf" ExtFlash.bin;arm-none-eabi-objcopy.exe -O binary --remove-section=ExtFlashSection "${BuildArtifactFileBaseName}.elf" STM32F746.bin

 

From mentioned link in query.

 

I need bin file for FPU. How can I create different  file from hex?

Tesla DeLorean
Guru
September 1, 2024

I don't expect the functionality of objcopy has changed. Review the command documentation and man page.

Check you're using the same/correct naming for the sections in the .ELF file. Check the .LD and what's described in the .MAP file

Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
MM..1
Chief III
September 1, 2024

In project settings uncheck bin file create.... you have hex ok.

GaetanGodart
Technical Moderator
September 2, 2024

Hello @shiv50084 ,

 

We made a video about reducing flash size : How to TouchGFX: Save flash memory 

You could also check your compiler setting to reduce size (-Os for size optimization in GCC).

 

I hope this helps. :smiling_face_with_smiling_eyes:
If this comment or another one solved your problem, I invite you to select it as "best answer".

 

Regards,