cancel
Showing results for 
Search instead for 
Did you mean: 

How to use STM32CubeIDE to load hex file on target?

SWenn.1
Senior III

I am using an STLINK V3 and STM32CubeIDE V 1.6.0....I would like to load a hex file instead of the debugger .elf file onto the target. I have followed the online steps and created the hex file....

Can someone tell me the steps needed to point STM32Cube to the hex file so I can load it?

Also what is the difference between a .bin and a .hex? In TI land I am used to the .hex files

Thank you

Steve

4 REPLIES 4
TDK
Guru

Using STM32CubeProgrammer instead would make it straightforward. Connect to the board, load the HEX file, and hit download.

BIN is raw data that gets stored, nothing else. No memory addresses, no offsets.

Intel HEX format includes metadata like where to put things and has some error checksum functionality. It's plaintext, you can open it in notepad.

If you feel a post has answered your question, please click "Accept as Solution".
SWenn.1
Senior III

Thank you for the response....I understand that CubeProgrammer would work but it seems that CubeIDE is a wrapper application and should contain somewhere within to open CubeProgrammer....Do I have to download a completely separate program (that seems silly) or when I downloaded CubeProgrammer did it create a bin executable somewhere?

TDK
Guru

STM32CubeIDE is an IDE meant for compiling/debugging programs, not really meant as a standalone programmer. It contains some tools capable of flashing programs but those aren't easily exposed to the user. If you have an existing HEX file, a separate application will be easier. It is not a wrapper for STM32CubeProgrammer like it is for STM32CubeMX.

If you feel a post has answered your question, please click "Accept as Solution".
SWenn.1
Senior III

Got it....thanks....Looks like when I downloaded and installed CubeIDE that CubeProgrammer got installed as well!

Thanks again