I have known about Forth since I was sixteen. A family friend gave me a copy of fig-FORTH for the 8080. After puzzling over it off and on for several years, I decided to finally try understand it fully. I think it was 1990.
I lived in Seattle at the time. I had recently quit my job at Microsoft – where, curiously, I had worked side-by-side with a fellow Forth enthusiast, modifying a bytecode interpreter and OS “loader” written in 68000 assembler.
The engineering library at the University of Washington was an amazing resource for learning Forth. They had a lot of Forth-related holdings: the Caltech manual; the FORML (Forth modification lab) proceedings; Forth Dimensions (the now-defunct Forth Interest Group’s now-defunct magazine).
I spent a week or so reading everything and taking notes.
Shortly thereafter, I ran into Trimpin, a local Seattle artist. I had seen a performance of a work of his – Circumference – at Bumbershoot (a big arts festival) a year or two before. This performance involved a roomful of percussion – drums, timpani, garbage cans – all played by “robot hands”. Each instrument had a drumstick poised over it, attached to a solenoid, which was attached via a homemade interface to Trimpin’s computer. Using MIDI and MIDI sequencing software (Performer) he controlled this roomful of instruments. It was breathtaking.
His studio was in my neighborhood, and one day I met him on the street, getting an espresso. Oh, Seattle!
We fell into a collaboration and I was able to realize two dreams: to use Forth, and to program the Motorola 6809, a processor I had been fascinated by since reading about it in Byte magazine in the late 1970s. I wrote a Forth development system, based on a terrible “object-oriented” Forth for the Macintosh. In a few days’ time I was able to write an assembler for the 6809, a Forth cross-compiler, and a simple “chat” protocol that allowed me to type commands on the host machine (the Mac) that were executed on the target (a small 6809-based embedded computer). All this was possible because of the simplicity and transparency of Forth.
I enjoyed this process tremendously. I felt empowered. Programming in Forth was ecstatic, liberating. Programming in C had never been this much fun!
Over the next ten years we collaborated on a series of projects. These were mostly handmade, idiosyncratic – and often musical – kinetic sculptures. Trimpin would collect modern industrial “junk” parts, and piece together a contraption; I would program it, always in Forth. I enjoyed aspects of this collaboration immensely. I worked in his studio – an appealing environment, much more Gepetto’s workshop than high-tech office. I was combining technology and art. I was able to try out new (for me) ideas. I wrote a multitasker. I wrote code to generate and consume MIDI. I wrote an aleatoric music generator.
The largest program I wrote – which sequenced a forty-foot-tall sculpture consisting of four octaves of marimbas, xylophones, and wooden milk bottles, and composed simple musical sequences on the fly – consumed 6k of object code. (This is a permanent installation in the lobby of the Science Museum of Minnesota, in Saint Paul.)
Forth impressed me. It liberated and empowered me. It was a small tool – one that I could understand deeply and entirely. I could make it entirely my own and I have. I have written several Forths – two for the PC (one in 486 assembler, one in C), and a bunch of “target” Forths: 6809, embedded 8086, ARM, RISC-V, MSP430.
I realize, looking back, that Forth is a convivial tool. I didn’t know that going in; I wasn’t sure, at the time, of the source of my sense of joyful liberation; but now I am sure that that is the reason.
Why not read about muforth, my target compiler for microcontrollers?