Skip to main content
cb.7
Associate III
March 12, 2021
Question

Problems with creating .bin files

  • March 12, 2021
  • 10 replies
  • 2516 views

Hello,

I am developing an application with:

  • lcd with ILI9341
  • STM32F411RET6
  • SPI external flash memory model SST26VF032B

I have already created the .stldr file for this memory and it works fine.

I edited the STM32F411RETX_FLASH.ld file to add the external flash.

I create the project from CubeMX, enable TouchGFX, create a test screen and do "Generate Code".

Why are the .bin files of the bitmaps and fonts not created to put in the external flash?

This topic has been closed for replies.

10 replies

MM..1
Super User
March 12, 2021

This is generated after linking not after generate code when you ask this.

Alexandre RENOUX
Visitor II
March 15, 2021

Hello cb.7,

"Generate Code' only generates code, it does not compile the code.

To compile and directly flash the board, you need to press "Run Target". But for this you might need to modify the makefile according to your board/project.

So instead, what I recommend is using STM32CubeIDE or IAR to compile and flash with STM32CubeProgrammer.

When your question is answered, please close this topic by choosing Select as Best.

Alexandre

cb.7
cb.7Author
Associate III
March 16, 2021

0693W000008wzotQAA.pngThanks for the reply.

I create a screen with TouchGFX, press "Generate Code", compile with STM32CubeIDE and everything goes well. The problem is that if I launch the debug from STM32CubeIDE it seems that I cannot find the .BIN file to load in the external flash memory ...

Alexandre RENOUX
Visitor II
March 16, 2021

Hello cb.7,

To flash your board, if you are using external memories (external RAM for Framebuffer and/or external Flash for assets), you need an external loader.

Also, CubeIDE does not use the .bin file, it uses the .elf binary file to download the code into your board.

/Alexandre

cb.7
cb.7Author
Associate III
March 16, 2021

0693W000008x0vHQAQ.png 

I have created an external loader called "SST26VF032B_STMF411RET6_SPI2.stldr" and it works correctly with "STM32CubeProgrammer".

If I launch the debugger it gives me an error as you can see from the attached photo.

Am I wrong to place my external charger in the project?

Alexandre RENOUX
Visitor II
March 17, 2021

Hello cb.7,

You are not wrong to use your external loader in CubeIDE which you used in CubeProgrammer. That is the correct procedure.

As why you cannot download into the board is not related to TouchGFX and I'm not an expert in CubeProgrammer/CubeIDE. Maybe try to add these tags to your request.

One thing you could try is download using CubeProgrammer and then debug without downloading with CubeIDE. I believe this option is available.

Also, after the download is successful with CubeProgrammer, is your project working ? Do you see the images stored in SPI flash displayed on your screen ? If not, are you sure your external loader is correct ?

/Alexandre

cb.7
cb.7Author
Associate III
March 17, 2021

With Cube Programmer I can write and verify correctly through my custom external loader ...

I think that the only solution to use custom hardware without starting from the demoboards, is to modify the Makefile, perhaps taking a cue from the NUCLEO-G071RB + X-GFX01M1 demoboard.

Where is the Mekfile to be modified?

Thank you