How to create a .hex file when running make all

Hi

I am working with stm32f4discovery board. I am would like to create a .hex file when I run the make all. Currently make all creates .elf, .map and .bin. How do I turn on HEX file generation.

Thank you

If your .elf file is bin/stm32f4discovery/hello-world.elf you can manually make the hex file by calling

make BOARD=stm32f4discovery bin/stm32f4discovery/hello-world.hex

There are also targets to get the given file types:

BOARD=stm32f4discovery make -C examples/hello-world/ hexfile
1 Like

Thank you very much.

Thank you very much