Skip to content

Instantly share code, notes, and snippets.

@monsonite
monsonite / TinyForth.ino
Created January 15, 2016 09:46
A Tiny Forth for Arduino - adapted from code from T. NAKAGAWA
// Tiny FORTH by T. NAKAGAWA 2004/07/04-10,7/29,8/5-6
/*
Tiny FORTH
Experimental Forth for Arduino
T. Nakagawa
2004/07/10
*/
#include <stdio.h>
// Txtzyme_UART_2
// A code-reduced version of Txtzyme for the Arduino
// Ken Boak 2013-2016
// Inspired by Txtzyme by Ward Cunningham
// https://github.com/WardCunningham/Txtzyme/blob/master/arduino/Arduinozyme/Arduinozyme.pde
// Replaced many of Arduino I/O dependencies reducing code from 3518 to 1040 bytes!
@monsonite
monsonite / ROMulator3.ino
Created June 4, 2016 18:04
A ROM Emulator for Z80 retro computer - using a 62256 SRAM, 2 x 74HC595 and 74HC245
//--------------------------------------------------------------------------------------------
// ROMulator 3
// Compiled using Arduino 1.65 or later
// A customised vesrion of SIMPL to allow RAM and Z80 bus to be exercised using SIMPL.
// Address is st using a pair of 74HC595 shift registers
// Data is passed through a 74HC245 bi-directional bugger
// TRISTATE line when raised isolates the address and data registers from the Z80 bus - allowing it to run
@monsonite
monsonite / ROMulator_TEST_1.ino
Created June 5, 2016 16:35
Test code for Arduino Z80 ROM Emulator
//--------------------------------------------------------------------------------------------
// ROMulator 3
// Compiled using Arduino 1.65 or later
// A customised vesrion of SIMPL to allow RAM and Z80 bus to be exercised using SIMPL.
// Address is st using a pair of 74HC595 shift registers
// Data is passed through a 74HC245 bi-directional bugger
// TRISTATE line when raised isolates the address and data registers from the Z80 bus - allowing it to run
@monsonite
monsonite / SIMPL_ASM_1
Created May 23, 2017 16:12
A tiny forth-like language for MSP430G2553
;-------------------------------------------------------------------------------
; SIMPL - a very small Forth Inspired, Extensible Language
; Implementing the Initialisation, TextTead, TextEval and UART routines in MSP430 assembly language
;
; A Forth-Like Language in under 1024 bytes
; Ken Boak May 22nd/23rd 2017
; Loops, I/O, Strings and Delays added
; This version 872 bytes
; SIMPL_ASM_1
@monsonite
monsonite / SIMPL_430ASM_5
Created May 24, 2017 07:05
A Tiny Forth-Like interactive language for MSP430
;-------------------------------------------------------------------------------
; SIMPL - a very small Forth Inspired Extensible Language
; Implementing the Initialisation, TextTead, TextEval and UART routines in MSP430 assembly language
;
; A Forth-Like Language in under 1024 bytes
; Ken Boak May 2017
; Loops, I/O, Strings and Delays added
; This version 888 bytes
; SIMPL_430ASM_5
@monsonite
monsonite / SIMPL_MSP430ASM_6
Created May 25, 2017 07:59
SIMPL - a tiny forth like language implemented in under 900 bytes of MSP430 Assembly Language (For MSP430G2553 Launchpad)
;-------------------------------------------------------------------------------
; SIMPL - a very small Forth Inspired Extensible Language
; Implementing the Initialisation, TextTead, TextEval and UART routines in MSP430 assembly language
;
; A Forth-Like Language in under 1024 bytes
; Ken Boak May 22nd/23rd 2017
; Loops, I/O, Strings and Delays added
; This version 888 bytes
; SIMPL_430ASM_6
@monsonite
monsonite / SIMPL_ASM430_13
Created June 9, 2017 16:21
A tiny "Forth-like" interpreted language for MSP430 - in under 800 bytes of codespace
;-------------------------------------------------------------------------------
; SIMPL - a very small Forth Inspired Extensible Language
; Implementing the Initialisation, TextTead, TextEval and UART routines in MSP430 assembly language
;
; A Forth-Like Language in under 1024 bytes
; Ken Boak May June 2017
; Loops, I/O, Strings and Delays added
; Jump table reduced by 36 entries (72 bytes)
@monsonite
monsonite / SIMPL_ASM430_14
Created June 13, 2017 16:41
A better documented version of SIMPL - with commands listed
;-------------------------------------------------------------------------------
; SIMPL - a very small Forth Inspired Extensible Language
; Implementing the Initialisation, TextTead, TextEval and UART routines in MSP430 assembly language
;
; A Forth-Like Language in under 1024 bytes
; Ken Boak May June 2017
; Loops, I/O, Strings and Delays added
; Jump table reduced by 36 entries (72 bytes)
@monsonite
monsonite / SIMPL_EDSAC_SIM_1.ino
Created August 3, 2017 14:41
SIMPL- with EDSAC virtual machine grafted in!
// SIMPL Interpreter for MSP430 Launchpad MSP430G2553 - with EDSAC Simulator grafted on!
// An experiment in minimal computing simulated on an MSP430 launchpad
// Really a dreadful hack, done on a very hot day in Greece - I'll get my coat.......
// SIMPL provides a shell to allow basic communications with EDSAC simulator
// Teraterm is a convenient means of sending files to the SIMPL machine