Eclipse IDE with MSPGCC
For those who already have installed this stuff, go directly to Eclipse tips
As a primary statement it must be noted that TI also provides an Eclipse-based environment, named Code Composer Essentials (CCE). A version with an 8 KB binary limit is free of charge. However, the JTAG communication is not very reliable. This is a known problem at TI. They are willing to improve CCE, but currently (end of 2005) no time resources are planned for doing this. As of january 2006 CCE still is living in version 1.0.
Meanwhile, Eclipse has been evolved further and today good universal support for embedded systems is present (i.e. configuration capability for debug sessions). So, debugging MSP430 programs within standard Eclipse is possible yet. The only drawback is the lack of a comprehensive view of peripheral registers (which is definitely an advantage of CCE). And there is a lack of comfort with handling the Development process: A so called proxy program must execute in order to convert GDB debug commands into a communication flow with the JTAG pod.
Of course, CCE provides a compiler from TI. It is said that Gnu is not as good with floating point operations, but in general the Gnu compiler for the msp430 is excellent. Moreover, header files are very well organized. There are separate header files for each peripheral unit, and these are included in derivative specific header files. Compared to other vendors this is advantageous, because an update in a certain peripheral header file inherently affects all derivatives.
The compiler that goes with CCE provides absolute references to variables (e.g. peripheral symbols) using a linker command file. This is a clean solution, formally better than e.g. "unsigned char p3out @ 0x0070", because this sort of references make compilers less ANSI-compliant. However, it is better to have it the usual way, because it is simpler to define aliases of the same symbol, e.g. with byte access or with bit access (using a struct). With the CCE compiler, header file(s) and also the linker command file must be altered to accomplish this.
Installation Preparation
The following files must be downloaded prior to starting any installation (the versions are given as of October 2007):
Since the CDT plugin seems to require the Eclipse IDE V3.2 or later, you might have to update the Eclipse IDE if you installed a previous version. However, this manual assumes that you will use Eclipse Europa (3.3), as we did.
- Eclipse Europa - Eclipse IDE for C/C++ Developers (3.3), at eclipse.org (October 2007 direct download Windows, direct download Linux both approx. 60 MB). Please check the Eclipse website for other builds, e.g. other platforms, updates and more information. Eclipse itself is written in Java. It is assumed that a Java runtime system is already present.
- CDT plugin package V2.1 (handles C projects) in a modified version optimized for embedded systems, at zylin.com. According to the information at this link location, two files must be downloaded (click on "latest snapshot", then load embeddedcdt-{datecode}.zip (approx. 12 MB) and zylincdt-{datecode}.zip (approx. 80 KB)). The page provides some more information. A Linux version is also available!
With these downloads, a universal embedded debug system can be established for a wide range of controllers. Within an eclipse session it is possible to maintain more than one project for different targets, with different compilers.
- MSPgcc, at mspgcc.sourceforge.net. There are binary distribution for Windows in "download area", however, it does not work good with eclipse, so you need to build it from CVS sources. The necessary proxy program can be downloaded from "download area" on mspgcc sourceforge page, as a tool to upload a binary directly to the target flash. You will need HIL.dll, MSP430.dll and msp430-gdbproxy.exe files on Windows, or libHIL.so, libMSP430.so and msp430-gdbproxy files on linux from msp43-gdbproxy directory there, put them into bin directory of your mspgcc toolchain installation (do not forget to run ldconfig on linux).
Eclipse installation
Eclipse need not be "installed" (but you may also have downloaded an executable that does a normal installation). Simply unzip the eclipse file (e.g. eclipse-cpp-europa-fall-win32.zip). and place the files at a suitable location for storage of programs. Create a link to eclipse.exe on your desktop etc. Principally, eclipse can be started now. However, yet it would not handle embedded projects.
CDT installation
Installation of embeddedCDT only requires that files be copied to the "features" and "plugins" directory of your eclipse program directory. The unzipped EmbeddedCDT consists of these two directories, so copying to the proper location is easy. Please note, you should remove existing CDT (org.eclipse.cdt.*) from plugins directory before installation.
ZylinCDT must also be unzipped. Here only plugin files are present. These must be copied to the plugins directory of your eclipse program location.
When eclipse was running during these actions, close it and reopen eclipse again. The features and plugins are recognized now.
MSPgcc installation
The good building guide located at http://mspgcc.sourceforge.net/manual/c1685.html. One important note: to use msp430-gdb with eclipse you should get gdb-6.0 distribution instead of gdb-5.1.1, and use the patch from gdb/gdb-current CVS directory. Add the cygwin bin directory (e.g. c:\cygwin\bin) and the mspgcc bin directory into your PATH on Windows.
Installation has been completed now. Next page, a tutorial from the beginning of a project until debugging is presented.
next =>
