Artikelindex

 

Installation 4e4th on TI_launchpad under Linux

For the moment you may try 4e4th, an already existing Forth from the German FIG. This document describes the steps to get the 4e4th into the TI-Launchpad.

Linux version: Ubuntu 11.10 32 bits. If you use another linux distro your mileage may vary.

Use Ubuntu Software Center to

  • Install package 'mspdebug'
  • Install package 'minicom' and/or 'ckermit'

This example uses the terminal program minicom to test the connection to 4e4th on the Launchpad, when it is programmed.

Set the straps TXD and RXD in the TI_launchpad in hardware-position (HW on board).

Download the file: 4e4th.a43 from the internet:

http://www.forth-ev.de/repos/4e4th/Release0.34/Exe/4e4th.a43

Connect the TI-launchpad to the USB port.

Determine the device of the TI-Launchpad in a terminal:

Linux vesta 3.0.0-19-generic #33-Ubuntu SMP Thu Apr 19 19:05:57 UTC 2012 i686 athlon i386 GNU/Linux fransm@vesta:~$ ls -l /dev/ttyACM* crw-rw---- 1 root dialout 166, 0 2012-06-02 19:35 /dev/ttyACM0

Stop the modemmanager from grabbing the port:

sudo service --status-all ps -ef | grep modemmanager (first number is the PID) sudo stop modemmanager sudo kill <PID_modemmanager>

Program the 4e4th in the MSP430G2553:

sudo mspdebug rf2500 "prog 4e4th.a43"

Disconnect and reconnect the TI-Launchpad to reset the processor. Now there must be 3 leds burning on the TI launchpad:

green powerled green LED2 red LED1

Test the connection:

minicom -D /dev/ttyACM0 -b 9600 -o -w

Set port connection in software handshake mode with: ctrl-A, O, Serial port setup, (F=No G=Yes), Esc, Esc <Enter> ok

words <Enter>

S2? S2 GREEN RED P3 P2 P1 UNUSED MEM MEMTOP MEMBOT CGET CTOGGLE CCLR CLR CSET SET MS 1MS BIN PAGE AT-XY BELL .VER \ 2CONSTANT WIPE FACTORY COLD WARM BOOT SAVE VALID? APPCRC ITHERE crc (crc ccrc .S DUMP U.R WORDS MARKER FLALIGNED NOOP ENVIRONMENT? DEPTH MOVE WITHIN LEAVE +LOOP LOOP ENDLOOP DO L> >L REPEAT WHILE AGAIN UNTIL BEGIN ELSE THEN IF POSTPONE ['] ; : IMMEDIATE REVEAL HIDE ] [ RECURSE DOES> (DOES>) CREATE <BUILDS HEADER ( [CHAR] CHAR ' ABORT" ?ABORT ABORT QUIT EVALUATE INTERPRET ?NUMBER >NUMBER ?SIGN DIGIT? LITERAL FIND IMMED? NFA>CFA NFA>LFA WORD >COUNTED /STRING SOURCE IC, I, IALLOT IHERE C, , ALLOT HERE HEX DECIMAL . U. SIGN #> #S # >DIGIT <# HOLD UD* UD/MOD IWORD ." IS" (S") (IS") TYPE ACCEPT UMAX UMIN SPACES SPACE CR COUNT 2OVER 2SWAP 2DUP 2DROP 2! 2@ MIN MAX */ */MOD MOD / /MOD * FM/MOD SM/REM M* DABS ?DNEGATE DNEGATE ABS ?NEGATE S>D APPU0 INFOB COR #INIT UINIT BL TIBSIZE TIB S0 R0 L0 PAD CAPS APP NEWEST IDP LP HP LATEST 'SOURCE DP STATE BASE >IN U0 ,NONE !DEST ,DEST ,BRANCH ,EXIT !COLON ,JMP ,CALL ,CF !CF COMPILE, >BODY CHARS CHAR+ CELLS CELL+ CELL ALIGNED ALIGN ZERO KEY? KEY EMIT N= S= SCAN SKIP I->D CMOVE> CMOVE FILL UM/MOD UM* UNLOOP J I (+loop) (loop) (do) ?branch branch U> U< > < <> = 0< 0= RSHIFT LSHIFT 2/ 2* >< 1- 1+ NEGATE INVERT XOR OR AND - M+ +! + D->I IC! I! FLERASE C! C@ ! @ TUCK RP! RP@ SP! SP@ R@ R> >R NIP ROT OVER SWAP DROP ?DUP DUP USER CONSTANT VARIABLE EXIT lit EXECUTE ok

7 39 3 */ . <Enter> 91 ok

green cclr <Enter>

green cset <Enter>

red cclr <Enter>

red cset <Enter>

0 p1 ! <Enter>

Leave minicom with the keys ctrl-A, X, Yes

Study the documentation of 4e4th and enjoy.

With thanks to the excellent work of the German Forth Gesellschaft.