Member-only story
Get Started with MSP430 MCU and Mecrisp Cross
Tethered Forth and Serial Protocol
With the success of my earlier digital dice project, I picked up another chance to use Mecrisp Cross on a low RAM resource MSP430 MCU (i.e. MSP430G2452). The project is to implement a serial bit protocol, like the Parallax Propeller firmware loader protocol.
1. Mecrisp Cross
Mecrisp Cross is a tethered Forth between the host and the target. The host acts like a code debugger, but with Forth scripting capability. The target is a MSP430 MCU that doesn’t have enough RAM resource to run Forth by itself. The host Forth runs on a STM32F407 and connects to the target over the standard MSP430 2-wire SWDIO/SWCLK debug bus.
With tethered Forth, you can develop and debug MSP430 Forth code interactively on the target (MSP430G2452). And once the code is completed, it is compiled into binary without any overhead from the host’s Forth environment itself.
2. MSP430 MCU
After a MSP430 MCU in this case MSP430G2452 is selected, some essential information comes from its MCU datasheet:
2.1 terminal functions table
For example, not all GPIO pin can serve as ADC10 analog input, similarly Timer0 capture can only happen on certain pins…