This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Difference between MSP430 binary files in Debug and Release folders

Other Parts Discussed in Thread: MSP430F5437A

I am currently using CCS Version: 4.2.5.00005.  I am developing with the MSP430F5437A.

I have found that whenever I build the project I am working on that under both the projects Debug and Release folder I find a .txt hex file.  I have used the file under the Release folder for programming the target hardware via the Bootstrap Loader so I know that that file works well enough.

However, I was researching about programming the MSP430 via a 3rd party tool (such as provided by Elprotronic) and found of a property I can select under C/C++ Build -> Build Steps -> Apply Predefined Step that builds and places a TI-TXT file in the Debug folder.  It appears to me that this file should be the same as the one that I have used in the Release folder.  However, the two files are different in size with the one in the Release folder being larger (the opposite of what I would expect).

So my question is, what is the difference between these two text files? They appear to both be binary files that can be used to program a device, but why then would they be different?

Thanks for the help.

  • Hi Robert,

    this is likely because debug and release use different optimization (and perhaps a couple other) settings.

    Have a look and you might see this for yourself.   I hope this helps clarify.

    Best Regards,
    Lisa

  • Hi Lisa,

    Thanks for the lead on this. I looked through all the possible differences between the release and debug properties and actually found that the debug version was using an older compiler version.  I've now made sure that both use the same compiler version and the .txt files now appear to be the same.

    It was an educational journey, thanks for the help!

    Dustin

  • Hi Dustin,

    very happy to hear that you got that clarified.  All the best with development and thanks for the update.

    Best Regards,
    Lisa

  • Generally the Debug executable has extra symbols in the file to assist the debugging utilities. I've found that debugging in release mode doesn't work quite as well. I'm actually surprised that the Debug and Release mode produced txt files of the same size. 

  • Debug mode and Release mode are different configurations for building your .Net project. Programmers generally use the Debug mode for debugging step by step their .Net project and select the Release mode for the final build of Assembly file (.dll or .exe).   The Debug mode does not optimize the binary it produces because the relationship between source code and generated instructions is more complex. This allows breakpoints to be set accurately and allows a programmer to step through the code one line at a time. The Debug configuration of your program is compiled with full symbolic debug information which help the debugger figure out where it is in the source code.

    More about......Difference between a Debug and Release build

    Walsh