2020-12-29 10:37 AM
Hi,
I am trying out the following tutorial: https://support.touchgfx.com/docs/tutorials/tutorial-01, which is very basic.
In the "Running an Example on an STM32 Evaluation Kit" section, when pressing run target, everything compiles, the MCU is loaded, but the external memory is not programmed.
(I still get the Done message...)
Looking at the extflash.bin size, it is over 2GB!
I did not modify the example in any way.
Looking at the Images and Texts, there is nothing extra and it shouldn't use much more than a few MB.
Did anybody successfully run this example?
Setup:
TouchGFX Designer 4.15.0
STM32F746G-Disco
Thanks,
Franck.
Solved! Go to Solution.
2020-12-29 11:19 AM
2020-12-29 11:11 AM
You'd need to look at the .MAP and .LD and try and understand why EXTFLASH spans multiple memory regions.
ie 0x08000000 and 0x90000000
I'd probably look at the .ELF sections, and why objcopy, or whatever isn't pulling the singular QSPI region.
2020-12-29 11:19 AM
2020-12-29 01:24 PM
Thanks to both of you.
The .MAP and .LD file seems good, with the QUADSPI starting at 0x90000000
I thought the extflash.bin would only contain data for the external flash and the programmer would automatically add the 0x90000000 offset.
I could not find how to properly disable the binary file generation (it is not enabled in the CubeIDE project "MCU Post build outputs").
Anyway, it looks like my issue is a CubeProgrammer bug, and the target.elf file from "thisProject\TouchGFX\build\bin" must be used to "manually" program the target.
My CubeProgrammer version is V2.6.0.
But seriously TouchGFX team, 2GB file!!??
Thanks,
Franck.
2020-12-30 02:57 AM
Simply in post build settings turn off generate bin
2020-12-30 03:41 AM
Is there a post-build setting in TouchGFX Designer somewhere? I could not find it.
If you mean the one from the CubeIDE project, it is already off (Project Properties->C/C++ Build->Settings->MCUPost build outputs).
I have updated my environment to TouchGFX Designer 4.16.0, CubeMX 6.1.1and configured CubeMX to use TouchGFX Generator 4.16.0.
The external flash loading now works directly from TouchGFX Designer, nice!
But it still generates the 2GB binary file which takes space and time to compile/write.
Even more, since it looks like the binary file is generated twice during the compilation. I can see that the file size increases to 2GB then goes down to a few KB and then increase again to 2GB...
2020-12-30 04:25 AM
I dont use run target or run simuloator , then build and 2G dont create. I import .project file and build in CubeIDE, then when is bin disabled no file created.
For extract you then can use some script with every sections and join it
arm-none-eabi-objcopy.exe -O binary --only-section=ExtFlashSection STM32F746G_DISCO.elf qspi1.bin
makefile in gcc root dir used by TouchGFX
arm-none-eabi-objcopy.exe -O binary --only-section=*FlashSection STM32F746G_DISCO.elf extflash.bin
and seems this wildcard dont work and generate 2G files
SOLUTION is change makefile and generate ihex file for extflash, and wildcard works.
2020-12-30 07:05 AM
I recheck CubeIDE hex and in this is all sections in one file , then makefile for TouchGFX have split applied ok, but extflash is better change to ihex format too.
Cube project dont handle extflash and intflash properly.