Aha, I checked, I was thinking of the Epson QX-10, which had something called Valdocs, that was originally written in Forth. Valdocs hit some roadblocks that Forthers still debate about, and was (per Wikipedia) later rewritten in C.
I love Forth and and have implemented it (well, not compliant) twice (Z-80 and C) back in the day for fun.
Postscript should get a mention, as its a related surviving stack language (though higher level - but in the spirit of the article, for a very domain-specific purpose), even if printer drivers do all the coding.
Though they changed most of the word names to protect the innocent: http://hyperpolyglot.org/stack
(And lest we forget display Postscript a la Sun NeWS - boy that was fun stuff! - still the coolest way to write your own desktop widgets)
Forth is (I think?) the oldest and most well-known. Postscript, the printer control language, is possibly more widely-deployed. And Factor is a modern take on Forth.
i had a room mate in the early 90's who was a forth programmer. At the time they wrote the code that did the airport displays. It was all forth. I wrote c back then and never really grasped it. Always seemed a little like a weird assembler.
Yeah, I have (maybe slightly fond?) memories of using Forth to develop a tape drive reader and writer for an undergraduate lab project. It is wonderful for some things, although in this case, where the problem was literally which addresses the instructions got assigned to, it is unclear if it would have made anything better.
Similar story here. Co-worker (German dude, very nice otherwise) was going to build OCR software from scratch using FORTH (1985 or so). After blowing the complete allotment of time for the project about a week before 'D' (demo) day I was asked if I could still make something that was demonstrable.
The problem wasn't all that hard actually so I wrote a bit of C code that did the job in about 2 working days...
Now, there is nothing wrong with FORTH per-se, it's a great little language and it has some elements that I think are super elegant, in the same way that I think LISP is super elegant (though I'd have a much easier time programming some problem in FORTH than in LISP simply because I have a lot more FORTH experience).
When I looked at the code I decided that FORTH was the wrong tool for that particular job, doing it in C (to great scorn of the original German dude who called C sneeringly a 'great' language because of the larger runtime) made the job very much easier.
The same 'it will work tomorrow' attitude was what kept the project going for all the time that went into it (multiple years), I think in part this was because the guy was so nice and a close buddy of one of the people that ran that place. But when push came to shove the un-elegant sledgehammer of C rammed that particular nail in in record time.
Image processing in FORTH is not the best fit, though I can see some ways in which you could make it fit. Maybe if I tried my hand at it by tomorrow I could have a working prototype ;)
I had access to a Novix eval system (like a shoebox with a 5 1/4 floppy in the side) at the time and for a lot of things it was _very_ fast - on a par with a VAX 8600 as I remember.
My memories of FORTH are really good too, especially after writing PostScript (FORTH enough) printer drivers that were downloaded printer programs. They turned further downloaded lists of nodes into properly placed topological diagrams and printed them out.
I still think Forth beats C as a language for microcontrollers programming. I didn't try it myself, yet, but I think a built-in REPL, nearly 1-1 correspondence with ASM and programmable compilation (among other things) can sum up to a really nice programming environment.
Edit: I never used one (or indeed ever saw one) but for some reason reading about Forth at the time gave me a lingering fascination with Forth type languages - which was useful when I worked on a project for a few years that used PostScript, C & Lisp ...
I was a big fan of Postscript and Forth. I loved Forth for the way it made you think about dividing up a program. It felt so natural to build a dictionary of words in pursuit of defining a higher level solution. I don't get the people who think its a write-only language. I came upon one of my old programs a decade after I first wrote it. Its was really easy to understand even now. Stack notation for comments with a bit of explanation are some fine documentation.
Postscript was a better Forth IMHO. I loved creating Postscript files for reports. My Turbo C, foxbase, and a Postscript printer were my main tools at my first job.
I was 'into forth' a good bit in the mid 80's, I worked together with a german programmer that really 'grokked' it (Lothar, his biggest dig at me was to call 'C' a 'great' language, by which he meant 'so verbose that it takes a lot of keystrokes to do simple stuff, to tease him I wrote a Forth in C ;) ), I was the newbie learning little by little.
We got some pretty hot forth hardware to play with (first chip of the 'Novix' line, pre-production) and we did neat stuff with it.
(until someone dropped a dime onto the experimental board when it was powered up that is, after that I had to pull some long nights coding a C replacement of our OCR code to save a demo... those were the days :) ).
Anyway, during the run up to this we got all kinds of good stuff on what was going on with the design of the chip, and my colleague Charly had some direct contact with Chuck, the stories about Okad come from him.
Charly was pretty good with the routing packages on our PDP-11 himself but he revered Chuck.
See my other post in this thread for some more details.
edit: iirc there was something about the Novix that was classified, I remember having to sign a bunch of documents about it being 'strategic'. I don't remember the details though.
Intriguing article. Just updated some Forth code for interfacing with an ADC on a sensor I’m building. Dealing with SPI/I2C and sensors/adc’s in Forth really is fantastic. The results in much more succinct hardware code IMHO than C or even higher level languages. Really Chuck Moore seems spot on when dealing with specific hardware.
One example is a simple Forth word (macro) to convert 3 bytes into one 32 bit number integrates well into code for dealing with an adc chip.
However I wouldn’t want to write while applications in Forth as dealing with stack swaps becomes annoying. Still writing your own Forth is pretty fun too. I did mine by basing C compiler XMacros which made porting to an Itsy M4 trivial (about 3-4 of work) [1].
Still there’s a few Forth’s for Arduino’s, Itsy’s, ESP’s [2] which are really fun as they enable repl style interactive programming with hardware while still being blindingly fast!
On 6502-based computers, C was highly unusual. Not only was C not nearly that widespread in hobbyist computing, but it's really painful on an 8-bit CPU with such a tiny stack (256 bytes) and few registers.
Forth, on the other hand received lots of attention for its small size and compact code, and e.g. I remember articles extolling Forth as easier to learn than BASIC at the time....
reply