I have a low-key, ongoing project to produce a fully open source CP/M clone which can be distributed with emulators (or used in real hardware). The issue is that while Caldera and Lineo have released all the old source, it’s under an encumbered license which prohibits redistribution, making it useless for these purposes. As part of this, I’ve just written a mostly-functional clone of the original asm.com which was shipped with CP/M — a simple 8080 assembler. And I did it all on video, so you can watch me do it.

asm.com is one of the key parts of the development system: CP/M originally came with an assembler, editor, and link kit for CP/M itself. The tools were minimal but complete, and with just the contents of the boot floppy you had everything you needed not just to bootstrap all further development, but to port CP/M to new systems. (And people did.)

Here it is, all seven hours of it. (Not including tea breaks.)

It’s missing a few features, like error recovery and transcript, but is functional enough to compile the original Digital Research CCP source code into an almost byte-for-byte copy of the original (Digital Research’s own assembler isn’t deterministic, leaving random garbage in uninitialised areas, where mine writes zeroes, hence the ‘almost’). At some point I’ll complete it, but it works now.

It’s written in C and is compiled with sdcc, so it’s currently producing Z80 machine code. The resulting binary is about 5.5kB vs the 8kB of the Digital Research hand-tooled original, which is probably due to it being Z80 machine code rather than the bigger and slower 8080 — I have an 8080 compiler but I just hadn’t bothered to get it set up. One day.

The assembler source

Find the assembler source here. It's MIT licensed.