What are Hex files

Hello Community,

I just learned about the new .arduboy file format. While reading about it, I learned that .hex files should be used in order to use tool like the GameLoader.

My question is now: Sorry for such a noob question:

What are Hex files and how do I get a hex file from my .ino file?

1 Like

A .hex file is the binary output that the compiler creates from the .ino and other sketch source files. It’s called a .hex file because it’s in Intel Hex format.

The standard way to make one is to use the Arduino IDE:

  • Load a sketch into the IDE as usual.
  • Instead of verifying or uploading the sketch, from the menu use:
    Sketch > Export compiled Binary
  • To open the folder containing the .hex file use:
    Sketch > Show Sketch Folder
  • The file you want is the .hex file that doesn’t contain with_bootloader in its name.
  • You can rename this file to whatever you wish, as long as the extension is left as .hex

Thanks so much for the quick help! This pushing me really forward in getting more and more done.

How do you load .hex files?

You don’t, use the .arduboy file.

If for some reason you did want to load .hex files then you can do it with the command line tool “avrdude”. There are many tutorials online how to do this, so you can search online for that.

Generally it isn’t a recommended practice, but it’s possible if you want.

One could even flash them directly with my Arduboy Manager. Or… You can import them and add pictures/metadata yourself.