MSP430 for OS XI collected some information on how to setup the MSP430 toolchain for Mac OS X
The easy wayA new google Code project provides all the files you need to get your launchpad working with OS X. Check out
Another easy way for all Arduino userThere's also a port of the Arduino IDE out there for the Launchpad. Check out
https://github.com/energia/Energia/wiki/Getting-Started Install the driver and the Energia program as mentioned there, and have fun.
Just remember two things:
- Trying to upload a sketch after using the serial monitor (may?) result in a "usbutil: unable to find a device matching ..." error - just briefly unplug the launchpad before uploading.
- And, most important, use the HW UART and not the SW UART jumper settings on the launchpad, otherwise the serial connection won't work (uploading is still possible).
And, by the way, if the launchpad hasn't enough pins for you, the MSP430G2553 is also available in a 28pin smd-package with 24 usable pins. It could be programmed by connecting the RST/TEST/VCC/GND Spy-By-Wire interface of the launchpad with the external micro-controller. No bootloader needed, works just like the inserted micro-controller at the launchpad.
Other Spy-By-Wire capable MSP430s should be programmable in the same way, especially the whole value line:
$ cd mspgcc4 && perl buildgcc.pl
There are binary packages available at http://sourceforge.net/projects/mspgcc4/files/
Install MSPdebugInstall libusb and libelf using MacPorts
$ sudo port install libusb-compat
$ sudo port install libelf
Download MSPdebug from http://mspdebug.sourceforge.net/ and unpack it.
$ sudo make install
Using the TI LaunchPad with OS X.This seems to be a very tricky task. Although there are some reports on the internet that some made the serial connection work, I didn't manage to do so.
To at least be able to program your MSPs, follow the instructions at http://mspdebug.sourceforge.net/faq.html#rf2500_osx which worked for me.
Be aware that mspgcc does not support the MSP430G2231 MCU that comes with the launchpad. However, simple programs seem to work with the msp430x2012 setting.
Running mspdebugTo connect mspdebug with the LaunchPad or ez430 programmer, enter the following command
If you want to use the MSP430 USB-Debug-Interface
If you are using an MSP-FET430UIF with a usual MSP430 (e.g., MSP430F249) then you need to provide the serial port to connect to (-d /dev/tty.TIVCP3410410) and set the protocol to JTAG (-j).
mspdebug -d /dev/tty.TIVCP3410410 -j
Once you're on the mspdebug console, you can interrupt your program, step through, inspect the memory, erase the program memory and flash new code to it (see http://mspdebug.sourceforge.net/manual.html for detailed information).
Blinking LED programTo test your toolchain, you can flash your MSP430 with a simple BlinkLED program. Here's how it works:
- Download this simple MSP430 BlinkLED example
makeon the console
mspdebugFlash the new program by entering
prog main.elfStart the program with
runTo interrupt the program flow just press Ctrl-C
You can issue commands now. If you want to quit the debugger just type
exit. When the debugger quits, it resets the MCU and the program starts over.