I have many new projects on the way that are quite a bit different from those I've published in the past. Here's the latest project in honor of 50 YEARS OF CP/M:
I'll be describing the design and construction of the computer and demonstrating various BASIC interpreters from the 70s, how to get CP/M installed and running, and then showing you some of the most popular CP/M applications from the 70s and early 80s. Below I've attached everything you need to replicate this project (or one of your own design) including schematics, board layouts, documentation, software, and source code. This project is more suited to the advanced builder but I'm hoping it will be fun to read for everyone interested in retro-computing or considering building their own microcomputer with the 8080 or Z80 microprocessor. You don't have to spend $10,000 on an old IMSAI or Altair. Build your own for less than $200 that is easier to use and runs the same software.
The microcomputer system shown above has:
I am very surprised how much can be accomplished with an 8-bit microcomputer and only KBs of RAM and MBs of disk: software development in BASIC, FORTRAN, COBOL, PASCAL, and C; Word Processing; Spreadsheets; Databases, Adventure Games.
The video below provides an overview of the design of the 8080 computer by briefly describing the most important parts of the schematic including the "shadow ROM" feature needed for CP/M.
Below are the documents and parts list that more fully describe the design:
File Name | Description |
parts-list.txt | Full parts list for the 8080 computer |
8080-computer-schematic.dch | Schematic file for DipTrace |
8080-computer-schematic.png | Schematic in PNG format |
8080-computer-schematic.pdf | Schematic in PDF format |
8080-board-top.png | Logic board top layout in PNG format |
8080-board-top.pdf | Logic board top layout in PDF format |
8080-board-bottom.png | Logic board bottom layout in PNG format |
8080-board-bottom.pdf | Logic board bottom layout in PDF format |
8080-reference-card.pdf | Easy to use reference card for the 8080 |
mcs80-datasheet.pdf | 8080, 8224, 8228 datasheets |
8250-datasheet.pdf | 8250 UART datasheet |
flash-card-datasheet.pdf | 128MB Compact Flash datasheet |
sp232a-datasheet.pdf | RS-232 Driver datasheet |
pt65-datasheet.pdf | Mean Well power supply datasheet |
The video below provides an overview of how the computer was constructed and demonstrates the use of the monitor program stored in the flash ROM.
Below are the documents and useful links that were demonstrated in the video:
File Name | Description |
altmon.pdf | The original documentation for the monitor I adapted for the 8080 computer |
altmon-flash.asm | Assembler source for the monitor stored in flash ROM |
altmon-ram.asm | Assembler source for the monitor, relocated to address 2000h |
altmon-cpm.asm | Assembler source for the monitor, relocated to address 0100h |
The FLASH version of the monitor is written to the flash ROM and includes the startup routine that triggers the shadow ROM feature. The RAM version of the monitor is used when loading the PCGET utility on the newly initialized CP/M file system. The CPM version of the monitor runs in the CP/M TPA area for use when launching the monitor from the CP/M command line.
Useful Links:
Link | Description |
john.ccac.rwth-aachen.de:8000/as | Manual for the monitor in PDF format. |
altairclone.com/downloads/roms/Altair%20Monitor | The original source for the monitor. |
deramp.com | Interesting web site for classic micro computers. |
deramp5113 | Also take a look at the DERAMP YouTube channel. |
noicedebugger.com | A truly excellent debugging tool for embedded systems |
The video below demonstrates several BASIC interpreters that were popular in the early days of the micro computer.
The presentation file is here: part3-slides.pdf
Be sure to check out the presentation document it may contain updates and corrections to those shown in the video.
Below are the source files used in the demonstrations.
NOTE: If using the ASL assembler, be sure to run P2HEX using the -R option to add an offset to the HEX file. The source files that I show loading at address 8000h use the following command:
P2HEX -R 0x8000 <filename.p>
File Name | Description |
tinybasic-jwd.asm | Tiny BASIC source adapted for the 8080 computer |
tinybasic-jwd-loader.asm | Tiny BASIC loader for the 8080 computer |
tinybasic-manual.pdf | Tiny BASIC manual in PDF format |
altair4k-jwd.asm | Altair 4K BASIC source adapted for the 8080 computer |
altair4k-jwd-loader.asm | Altair 4K BASIC loader for the 8080 computer |
altair8k-jwd.asm | Altair 8K BASIC source adapted for the 8080 computer |
altair8k-jwd-loader.asm | Altair 8K BASIC loader for the 8080 computer |
altair-basic-manual.pdf | Altair BASIC Manual in PDF format |
imsai8k-jwd.asm | IMSAI 8K BASIC source adapted for the 8080 computer |
imsai8k-jwd-loader.asm | IMSAI 8K BASIC loader for the 8080 computer |
imsai-basic-manual.pdf | IMSAI BASIC Manual in PDF format |
scelbal-jwd.asm | SCELBAL source adapted for the 8080 computer |
scelbal-jwd-loader.asm | SCELBAL loader for the 8080 computer |
scelbal-manual.pdf | SCELBAL Manual in PDF format |
scelbal-strings-supplement.pdf | SCELBAL Strings Supplemental in PDF format |
scelbal-math-supplement.pdf | SCELBAL Math Supplemental in PDF format |
scelbal-update.pdf | SCELBAL Updates in PDF format |
xybasic-jwd.asm | XYBASIC source. Assemble with CP/M MAC |
xybasic-manual.pdf | XYBASIC Manual in PDF format |
Useful Links:
Link | Description |
retrotechnology.com/restore/a8008.html | 8008 cross-assembler for SCELBAL |
The video below describes the process for adapting CP/M to the 8080 Computer.
The presentation file is here: part4-slides.pdf
Be sure to check out the presentation document it may contain updates and corrections to those shown in the video.
Below are the CP/M 2.2 source files used on the 8080 computer.
File Name | Description |
ccp.asm | CPM 2.2 Console Command Processor |
bdos.asm | CPM 2.2 Basic Disk Operating System |
cbios.asm | CPM 2.2 BIOS for the 8080 computer |
format.asm | CPM 2.2 file system initialization for 8080 computer |
install.asm | CPM 2.2 RAM to DISK installer |
load.asm | CPM 2.2 DISK to RAM loader (used for testing install) |
boot-load.asm | On-Disk Boot Loader for 8080 Computer |
boot-install.asm | On-Disk Boot Loader RAM to DISK installer |
boot-read.asm | On-Disk Boot Loader DISK to RAM loader (tests install) |
format.asm | CPM 2.2 logical disk formatter (TPA utility) |
UNARC.COM | CPM 2.2 UNARC utility for extracting CPM utilities |
util.zip | CPM 2.2 Utilities in ZIP format |
UTIL.ARC | CPM 2.2 Utilities in ARC format |
arc.zip | DOS/Windows ARC utility for creating archive files |
pcget.asm | PCGET Utility Source for the 8080 computer |
pcget.hex | PCGET utility in HEX format (used for utility install) |
pcput.asm | PCPUT Utility Source for the 8080 computer |
8080-programmers-manual.pdf | 8080 Programmers Manual in PDF format |
asm-manual.pdf | CPM 2.2 Assembler Manual in PDF format |
cpm-22-alteration-guide.pdf | CPM 2.2 Alteration Guide in PDF format |
cpm-22-reference-card.pdf | CPM 2.2 Users Reference Card in PDF format |
cpm-22-users-manual.pdf | CPM 2.2 Users Guide in PDF format |
ddt-manual.pdf | CPM 2.2 Debugger Manual in PDF format |
ed-manual.pdf | CPM 2.2 Editor Manual in PDF format |
pcget-pcput-manual.pdf | PCGET/PCPUT Manual in PDF format |
power.txt | Help file for POWER.COM |
Useful links:
Link | Description |
github.com/brouhaha/cpm22 | Original CP/M 2.2 Source Code adjusted for modern assemblers |
retroarchive.org/cpm/archive/unofficial/source.html | More source code for Digital Research products |
cpuville.com/Code/CPM-on-a-new-computer.html | Extremely good article getting CP/M 2.2 running on the Z80 |
cpm.z80.de/ | Great repo of DR software |
I think it is incredible how much can be done with an 8-bit microprocessor and 64K of RAM. The killer applications of the 80s all run on the 8080 computer described in this article. The video below proves it:
The presentation file is here: part5-slides.pdf
Be sure to check out the presentation document it may contain updates and corrections to those shown in the video.
Below are the applications demonstrated in the video along with the four most important programming languages available on CP/M (BASIC, C, FORTRAN, and PASCAL).
File Name | Description |
ws.zip | WordStar 4.0 in ZIP format |
ws.arc | WordStar 4.0 in ARC format |
wordstar-manual.pdf | WordStar 4.0 manual in PDF format |
sc2.zip | SuperCalc II version 1.00 in ZIP format |
sc2.arc | SuperCalc II version 1.00 in ARC format |
supercalc2.pdf | SuperCalc II manual in PDF format |
dbase2.zip | dBASE II version 2.4 in ZIP format |
dbase2.arc | dBASE II version 2.4 in ARC format |
dbase2-manual.pdf | dBASE II manual in PDF format |
zork.zip | Zork 1, 2, and 3 in ZIP format |
zork.arc | Zork 1, 2, and 3 in ARC format |
zork1-manual.pdf | Zork 1 manual in PDF format |
zork2-manual.pdf | Zork 2 manual in PDF format |
zork3-manual.pdf | Zork 3 manual in PDF format |
basic.zip | BASIC Interpreters and Compilers in ZIP format |
basic.arc | BASIC Interpreters and Compilers in ARC format |
ms-basic-manual.pdf | MS BASIC-80 manual in PDF format |
ms-basic-compiler-manual.pdf | MS BASIC Compiler in PDF format |
aztecc.zip | Manx Aztec C version 1.06D in ZIP format |
aztecc.arc | Manx Aztec C version 1.06D in ARC format |
f80.zip | MS Fortran 80 version 3.44 in ZIP format |
f80.arc | MS Fortran-80 version 3.44 in ARC format |
mtplus.zip | PASCAL/MT+ version 5.6.1 in ZIP format |
mtplus.arc | PASCAL/MT+ version 5.6.1 in ARC format |
Useful links:
Link | Description |
retroarchive.org/cpm/ | Large repo of CP/M software |
cpmarchives.classiccmp.org/ | Large repo of CP/M software |
z80.eu/cpmsoft.html | Nice repo of CP/M software |
medium.com/@davidly_33504 | An extremely good article comparing CP/M 2.2 development tools |
github.com/davidly/cpm_compilers | Repository of tools used in the article above |
In the video below I spend some time discussing the CP/M 2.2 File System of which a key component is the Directory. I also demonstrate a sector editing program I wrote for the 8080 computer that aids examining the directory and disk blocks assigned to files.
The presentation file is here: part6-slides.pdf
Be sure to check out the presentation document it may contain updates and corrections to those shown in the video.
Below is the source code for the sector editor program used in the video:
File Name | Description |
diskedit.asm | Disk sector editing program |
In the video below I discuss some upgrades I did on the system software, I describe how I resolved two pesky problems that cropped up while using the system, and I provide some more information about the CP/M 2.2 file system.
The presentation file is here: part7-slides.pdf
Be sure to check out the presentation document it may contain updates and corrections to those shown in the video.
Below are the source files for the demonstration programs shown in the video:
File Name | Description |
setvol.asm | Displays volume mounts and mounts logical volumes on a drive letter |
volumes.asm | Displays the logical volumes available on the CF drive |
label.asm | Assigns a name to a logical volume |
VOLUMES.DAT | The hidden system file containing the volume labels |
create.asm | Demonstrates the create file BDOS function call |
write.asm | Demonstrates the sequential write BDOS function call |
writem.asm | Demonstrates multiple sequential write function calls |
baud.asm | Changes the baud rate of the 8250. Not covered in the video. |
This has been a fun and challenging project and I am amazed at how much a small computer system like this can do, and how fast it can do it. Although nowhere near as fast as a modern PC, I am still amazed.
As a bonus I've added a VI editor to my 8080 computer which is based on the VED editor from Manx Software Systems. The source code for VED was originally written in C and compiled on an Apple 6502 machine. I've modified the source code to run on CP/M 80 with ANSI terminal and keyboard codes so that it can work with Putty or Tera Term. The VI editor below contains a nice subset of the UNIX VI commands. It's not lightning fast but it seems to work really well on my 8080 computer. I'll be writing a VI editor from scratch in 8080 assembly which should be much smaller and faster. But for now this C language VI editor seems to work well for me.
File Name | Description |
vi.arc | CP/M archive file containing all source, make, and text documentation |
readme.txt | Documentation and notes |
makevi.sub | A SUB file that builds vi.com |
unmkvi.sub | A SUB file that removes vi files from the Aztec disk |
vi.c | The main C routines for vi.com |
vi.h | The main C header with global variables and flags |
cpm.c | CP/M specific routines for the vi editor |
file.c | File I/O routines for the vi editor |
insert.c | Line insert and delete routines for the vi editor |
subs.c | Sub-command routines for the vi editor |
disp.c | Main display control routines for the vi editor |
scr.c | ANSI display driver for the vi editor |
getkey.asm | ANSI keyboard driver for the vi editor |
By 1982 these amazing 8-bit computers were still not being given credit for all the things they could do. Most enterprise companies still viewed the Apple, Commodore, and TRS-80 machines as "toys". Although the personal computer would gain new and well-deserved respect when the IBM PC took over the market, I just don't think it was fair for the 8080, Z80, and 6502 to be viewed as "not ready for business". I regularly review and retrain as part of my engineering discipline and I think all engineers should do the same to avoid becoming stale. I recently purchased a book on computer algorithms used in computer science courses across the nation. You are never too smart or too old to go back to the basics every now and then. So that's what I did for this video. Along the way, I get to demonstrate my 8080 computer as a C language development platform.
The presentation file is here: insertion-sort.pdf
File Name | Description |
sort.c | Ascending order insertion sort example |
usort.c | Descending order insertion sort example |
netZener