Hello! I want to share with the software community one unusual application of the
MSP430-Launchpad debug board.
The manual is intended for those who already have MSP430-Launchpad, mastered MSP430-ValueLine microcontrollers and thinks about switching to the more advanced MSP430 MK, but have not yet decided to purchase the MSP430-JTAG or MSP430-UIF professional programmer. But it's not scary. As a programmer, you can still use Launchpad. Under the cut, I'll tell you how to do it.
It turns out that the programmer included in the Launchpad board can flash any microcontroller (MK) MSP430 that has a SpyByWire interface (SBW). There are apparently no restrictions on the MK model. Whether this is a Launchpad bug or conceived Texas Instrunmets is unknown. The SBW interface is programmable including the MK MSP430G2553 and MSP430G2452, which come bundled with the board. Make sure that the microcontroller has an SBW interface, you can see its datasheet. We will use an improvised debug board with an MSP430F5438A microcontroller as a test board. The SBW interface in this MK is. The board looks like this:

')
Now you need to remove the jumpers that connect the top of the Launchpad board from the bottom and pull the wires from the RST, TEST, VCC, VSS contacts. These wires need to be connected by a self-made cable with legs of the MK in the following order (in parentheses are the numbering of the findings for the MK MSP430F5438A):
Launchpad <---------> MSP430F5438A
VCC <---------> VDD (87)
RST <---------> SBWTDIO (96)
TEST <---------> SBWTCK (91)
GND <---------> VSS (88)
In the following picture, the legs of MSP430F5438 to which you need to connect are marked with a cross:

Now we make a homemade cable, connect it to MSP430F5438 and to Launchpad. It should look like this:

MK from the socket DIP-20 must be removed. At the same time, the MK on the experimental debug board will be powered by Launchpad, which in turn is powered by USB. Now you can connect the USB cable in Launchad and connect it to the computer. If done correctly, then the green PWR LED should be on on the Launchpad. If VSS and VDD are confused, the LED is off.
Now you can check whether the microcontroller is recognized. Further I will use Linux OS and the mspdebug utility. If you have another toolchain for MSP430 then see the documentation for it. Now let's check if our MK is recognized. In the console, type:
mspdebug rf2500
The fee should give the following answer:
vvk@linux-bmx0:~> mspdebug rf2500 MSPDebug version 0.21 - debugging tool for MSP430 MCUs Copyright (C) 2009-2012 Daniel Beer <dlbeer@gmail.com> This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Trying to open interface 1 on 004 Initializing FET... FET protocol version is 30394216 Set Vcc: 3000 mV Configured for Spy-Bi-Wire Device ID: 0x0580 Code start address: 0x5c00 Code size : 262144 byte = 256 kb RAM start address: 0x1c00 RAM end address: 0x5bff RAM size : 16384 byte = 16 kb Device: MSP430F5438A Number of breakpoints: 8 fet: FET returned NAK warning: device does not support power profiling Chip ID data: 05 80 17 Available commands: = erase isearch opt run setwatch_w alias exit load power save_raw simio break fill load_raw prog set step cgraph gdb locka read setbreak sym delbreak help md regs setwatch verify dis hexout mw reset setwatch_r verify_raw Available options: color gdb_loop enable_bsl_access gdbc_xfer_size enable_locked_flash_access iradix fet_block_size quiet Type "help <topic>" for more information. Press Ctrl+D to quit. (mspdebug) exit
As a result, we have to get into the mspdebug console. To exit from there, enter exit. If MK did not answer, then check the cable.
If you received such an answer, the MC is recognized and you can program it with the command:
mspdebug rf2500 "prog ___.elf"
Through Launchpad programming is very slow. 8kB flash a few minutes. Otherwise, there are no restrictions.
It should also be noted that after we turned off the bottom of the Launchpad, the RESET button is no longer functional. If there is no such button on the board, then you can send the MC to the reset from the command line:
mspdebug rf2500 reset
In general, the above-mentioned method is not a professional programmer to replace, but with the “older” MK of the MSP430 series, however, it is possible not only to get acquainted but also to work fully, if you do not pay attention to the low speed of the firmware.