Mecrisp-Across Unofficial Documentation

What is this Website About ?

This website provides unofficial documentation for Mecrisp-Across, which is an Interactive Tethered Forth development tool.

_images/f4disco-roundpcb-2.jpg

This tool uses a REPL (Read-Eval-Print Loop) enabled by a 4-wire ‘tether’ cable from the host to the MSP430 target.

During development, the host emulates the target CPU, keeping it reset, and reads and writes target registers via the JTAG ‘tether.’

Once development is complete, the host cross-compiles a binary image for the target that does not contain Forth. When connected to the tether, the target appears to have an onboard interactive Forth; when disconnected, it runs a standalone Forth-free binary image.

The tether is a simple four-wire cable for power and signal lines

More Mecrisp-Across Detail Please ?

A brief history of Microprocessor development including more detail about how how Mecrisp-Across works.

Index

The Target: MSP430xxxx

The Texas Instruments MSP430 family of ultra-low-power microcontrollers consists of several devices featuring different sets of peripherals targeted for various applications. The architecture, combined with five low-power modes, is optimized to achieve extended battery life in portable measurement applications. The device features a powerful 16-bit RISC CPU, 16-bit registers, and constant generators that contribute to maximum code efficiency. The digitally controlled oscillator (DCO) allows wake-up from low-power modes to active mode in less than 1 µs.

Why use the MSP430 ? How about LOW PRICES ($0.40 AUD). huge availability (NOW, during the 2021 - 2022 ‘Great Chip Shortage’) and a fantastic programmer ISA !

MSP430G2201IRSA16 pricing

See Target Definitions for the complete list of Across-V0.9 MSP430 Target Words, (which you can extend).

See predefined constants I use in my custom version.

Mecrisp-Across Advanced Cross-Compiler Features

  • It’s like a interactive Gcc with Gdb.

  • A Blinky written in Forth compiled to a total of 36 Bytes of bootable binary image using Mecrisp-Across.

  • The peripherals are pre-defined, no need for memory maps, SVD’s, include or header files. They are ready to code for right away.

  • It generates a highly optomised bootable binary image for the target, including vector configs

  • There is no Forth kernel pre-install or bootloader necessary in the target hardware, it runs on a totally blank mcu.

  • The HOST compiler is GPL3 licensed, your target binary image license is gpl unencumbered. License it how you wish.

  • Mecrisp-Across is possibly one of the strongest optimizing Forth cross compilers you have ever seen. Out of the box, it does:
    • Constant folding

    • Register allocation for both data and return stack

    • Dead code elimination (imagine a constant feed into case)

    • Register allocation across control structures

    • Determination which definitions are in use,

    • Automatic inlining of definitions used one time only

    • Interrupt handler framing depending on register usage

Example Target Hardware Types

MSP430xxxx MSP-EXP430G2 Board or a standalone home made board using the cheapest MSP430xxxx model available..

_images/MSP-EXP430G2-315x.jpg _images/pcb-round-pins-mcu-top-315x.jpg _images/pcb-round-pins-mcu2-315x.jpg

See Target Definitions for V-0.9 for the complete list of Target Words.

The Host

Mecrisp-Across has two choices of tether capaconsumer electronicsble Host board, the STM32F4 Discovery, the TM4C1294 Tiva Connected Launchpad. a tether-less Linux or FreeBSD PC or Laptop which you can run right now after getting the release and a tether-less Linux ARM device such as the Raspberry Pi.

_images/f4disco-roundpcb-2.jpg _images/boards-wired-323.jpg _images/laptop-323x.jpg _images/rpi-323.jpg

f4disco, Ti Tiva, PC or Laptop, Raspberry Pi

INDEX