This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Creating binary for ST Micro STEVAL-3204

Hello.  ST Micro provides a project for a BLDC.  They provide a readme with an outline of the process, and simply say to copy over the final binary file to the 3204 without any information on how to make it. I can create the HEX file with uVision 5 and convert this to a BIN using srec_cat. However, the size of the resulting file is over 128k, while the available space on the STEVAL-3204 is only about 42k.  

Is there a way to create a much smaller object file, one that I would think has everything not needed stripped out (such as debug code)?

Thank you.

Parents
  • However, the size of the resulting file is over 128k, while the available space on the STEVAL-3204 is only about 42k. 

    The size of a BIN file may not have much of a correlation to the space actually used by the program, depending on aspects like the address mapping of the controller, and/or gaps in the used space.  BIN files, by their very nature, cannot usefully represent such gaps.  That's why it's almost always better to use HEX files as the flashable file format.

    Is there a way to create a much smaller object file, one that I would think has everything not needed stripped out (such as debug code)?

    Your BIN file is not an object file, so that question makes very little sense.  In particular there is no "debug code" left in there to be stripped out.

Reply
  • However, the size of the resulting file is over 128k, while the available space on the STEVAL-3204 is only about 42k. 

    The size of a BIN file may not have much of a correlation to the space actually used by the program, depending on aspects like the address mapping of the controller, and/or gaps in the used space.  BIN files, by their very nature, cannot usefully represent such gaps.  That's why it's almost always better to use HEX files as the flashable file format.

    Is there a way to create a much smaller object file, one that I would think has everything not needed stripped out (such as debug code)?

    Your BIN file is not an object file, so that question makes very little sense.  In particular there is no "debug code" left in there to be stripped out.

Children
No data