The usage of Terminal-BASIC sources is described in the set of examples.
The stable releases of Terminal-BASIC are downloaded from the Files section.
Let's download the latest release.
Unpack the downloaded archive. There are some folders inside: terminal-basic-<version> is a main project sketch directory, while others are libraries:
libps2uart
libsdcard
libutft
terminal-basic-<version></version>
tvoutex
README</version>
Open Arduino IDE, then open a sketch from terminal-basic-<version>/terminal-basic directory.
Choose Arduino UNO board, verify and upload program to your Arduino UNO compatible board.</version>
If compiled file is too big switch off (set to 0 instead of 1) some features in config.h and config.hpp files:
Let's switch off the strings manipulation functions LEFT$, MID$/SEG$, RIGHT$.
config.hpp
// LEFT$ function, return leftmost part of the string #define USE_LEFT 0 // RIGHT$ function, return rightmost part of the string #define USE_RIGHT 0 // MID$ function, return middle part of the string #define USE_MID 0 // A variant of MID$ equivalent #define USE_SEG 0
Then switch off the ability to use INPUT command with printed text (Like INPUT "X is:"; X).
config.hpp
/** * Allow INPUT command with text message e.g. INPUT "A:";A */ #define OPT_INPUT_WITH_TEXT 0
Open Putty gui.
In "Session" category choose "Serial" connection type. Enter appropriate COM-port name in the field "Serial line".
Enter 115200 in the "Speed" field.
In "Terminal" category set "Implicit CR in every LF" flag. Set "Local echo" and "Local line editing" options to "Force off".
In "Keyboard" subcategory choose "Control -? (127)" in the "The backspace key" group.
You can save session parameters at the "Session" category.
With much more FLASH memory it's possible to enable most of the supported BASIC features:
Long (4 byte) integer types:
/* * Support of 4-byte integer datatype * Functions, variables and arrays of long integer type ends with double % mark */ #define USE_LONGINT 1
Matrix operations:
/* * Support of Darthmouth BASIX-style matrix operations */ #define USE_MATRIX 1
DATA/READ statements as in old batch processing systems
/** * Support of DATA/READ statements */ #define USE_DATA 1
Support of one-line macro's like functions
/* * Support of DEF FN construct */ #define USE_DEFFN 1