MilliForth-6502, A Forth For The 6502 CPU

Forth is popular on small computers because it is simple to implement, yet quite powerful. But what happens when you really need to shrink it? Well, if your target is the 6502, there’s milliForth-6502.

This is a port of milliForth, which is a fork of sectorforth. The sectorforth project set the standard, implementing a Forth so small it could fit in a 512-byte boot sector. The milliForth project took sectorforth and made it even smaller, weighing in at only 336 bytes. However, both milliForth and sectorforth are for the x86 architecture. With milliForth-6502, [Alvaro G. S. Barcellos] wanted to see how small he could make a 6502 implementation.

Continue reading “MilliForth-6502, A Forth For The 6502 CPU”

The Jupiter Ace Remembered

It is hard to imagine that it has been more than four decades since two of the original designers of the Sinclair ZX Spectrum broke off to market the Jupiter Ace. [Nemanja Trifunovic] remembers the tiny computer in a recent post, and we always love to recall the old computers that used TVs for screens and audio tape recorders for mass storage.

One thing we always loved about the Jupiter Ace is that while most computers of the era had Basic as their native tongue, the Ace used Forth. As the post points out, while this may have given it great geek cred, it didn’t do much for sales, and the little machine was history within a year. However, the post also proposes that Forth wasn’t the real reason for the machine’s lack of commercial success.

Why did they pick Forth? Why not? It is efficient and interactive. The only real disadvantage was that Basic was more familiar to more people. Books and magazines of the day showed Basic, not Forth. But, according to the post, the real reason for its early demise was that it was already using outdated hardware from day one.

The Ace provided only 3K of RAM and did not offer color graphics. While this may sound laughable today, it wasn’t totally out of the question in 1978. Unfortunately, the Ace debuted in 1982. There were options that offered much more for just a little less. There is also the argument that as users became less technical, they just wanted to load pre-programmed tapes or cartridges and didn’t really care what language was running the computer.

Maybe, but we did and we can’t help but imagine a future where Forth was the language of choice for personal computers. Given how few of these were made, we see a lot of projects around them or, at least, replicas. Of course, these days that can be as simple as a single chip.

RISC-V Pushes 400 Million Forth Words Per Second

We’ll be honest. Measuring Forth words per second doesn’t seem like a great benchmark since a Forth word could be very simple or quite complex. But we think the real meaning is “up to 400 million words per second.” There was a time when that level of performance would take a huge computer. These days, a simple board that costs a few bucks can do the trick, according to [Peter Forth] in an online presentation.

The key is the use of the Milk V Duo and some similar boards. Some of these look similar to a Raspberry Pi Pico. However, this chip on board has two RISC V cores, an ARM core, and an 8051. There’s also an accelerator coprocessor for vector operations like AI or video applications.

Continue reading “RISC-V Pushes 400 Million Forth Words Per Second”

Go Forth With This Portable Programmer

When choosing a low-level language, it’s hard to beat the efficiency of Forth while also maintaining some amount of readability. There are open source options for the language which makes it accessible, and it maintains its prevalence in astronomical and other embedded systems for its direct hardware control and streamlined use of limited resources even though the language started over 50 years ago. Unlike 50 years ago, though, you can now take your own self-contained Forth programmer on the go with you.

The small computer is built on a design that [Dennis] built a while back called my4TH which has its own dedicated 8-bit CPU and can store data in a 256 kB EEPROM chip. Everything else needed for the computer is built in as well but that original design didn’t include a few features that this one adds, most notably a small 40×4 character LCD and a keyboard. The build also adds a case to tie everything together, with ports on the back for I2C and power plus an RS232 port. An optional battery circuit lets the computer power up without an external power supply as well.

Continue reading “Go Forth With This Portable Programmer”

Forsp: A Forth & Lisp Hybrid Lambda Calculus Language

In the world of lambda calculus programming languages there are many ways to express the terms, which is why we ended up with such an amazing range of programming languages, even if most trace their roots back to ALGOL. Of the more unique (and practical) languages, Lisp and Forth probably range near the top, but what if you were to smudge both together? That’s what [xorvoid] did and it resulted in the gracefully titled Forsp programming language. Unsurprisingly it got a very warm and enthusiastic reception over at Hacker News.

While keeping much of Lisp-isms, the Forth part consists primarily out of it being very small and easy to implement, as demonstrated by the C-based reference implementation. It also features a Forth-like value/operand stack and function application. Also interesting is Forsp using call-by-push-value (CBPV), which is quite different from call-by-value (CBV) and call-by-name (CBN), which may give some advantages if you can wrap your mind around the concept.

Even if practicality is debatable, Forsp is another delightful addition to the list of interesting lambda calculus demonstrations which show that the field is anything but static or boring.

Bit-Serial CPU: Ultra-Tiny VHDL-Based CPU With Forth Interpreter

Soft cores for FPGAs come in many different flavors, covering a wide range of applications. The Bit-Serial CPU (bcpu) soft core presented by [Richard James Howe] is interesting for taking up just about the most minimal amount of resources (23 slices, 76 LUTs) while providing the means to run a Forth-based (eForth dialect) interpreter. To this CPU core a UART can be added (92 LUTs), as well as other peripherals.

As [Richard] states, the entire core with UART fits in 73 slices (220 LUTs) on a Spartan 6, while requiring a single port BRAM (block RAM). It features a 16-bit accumulator and lacks features such as interrupts, byte addressability and function calls, but those are not required to run the eForth interpreter. The main purpose of this soft core (other than the challenge) is to have a UART-programmable core that can be slotted in any FPGA design. For more serious requirements [Richard] also has the H2 SoC, which can run full-fat FORTH.

Continue reading “Bit-Serial CPU: Ultra-Tiny VHDL-Based CPU With Forth Interpreter”

Recreating The Jupiter ACE

What looks like a Sinclair ZX81 but runs Forth? If you said a Jupiter ACE, you get a gold star. These are rare because ordinary people in 1982 didn’t want Forth, so only about 5,000 of the devices were sold. [Cees Meijer] assumes they are unaffordable, so he built a replica and shows you how you can, too. [Scott Baker] built one recently; you can see his video below.

The resemblance to the Sinclair computer wasn’t just a coincidence. Richard Altwasser and Steven Vickers were behind the computer, and both had worked for Sinclair previously. In addition to being famous for using Forth, the machine initially had a badly manufactured case and an unreliable keyboard. A later version tried to correct these issues, but there were fewer than 1,000 made. [Cees’] replica used a design from [Grant Searle] with some modifications.

We liked the realistic look of the 3D printed keyboard. The keyboard uses white plastic with raised letters. A quick black spray paint followed by sanding gives the appearance of black keys with white printed text.

Overall, this is a good-looking build of a computer you probably won’t see in person. We wish Forth had caught on in the early PC world, but it didn’t. [Grant] was prolific with replica computers, and [Cees] isn’t the only one who used that work as a starting point for their own projects. If you want real old-school Forth, you have to go back a few more years.

Continue reading “Recreating The Jupiter ACE”