As technology progressed and the world of computig systems moved beyond not only the PDP-11 and Digital Equipment Corporation itself, it is becoming very difficult and expensive to find and maintain a PDP-11 system. Fortunately, those same advances have allowed for simulations of PDP-11 systems. SimH ("History Simulator") is a collection of simulators of every PDP-11 model, as well as various vintage IBM, Altair, Data General, HP machines from the 1960s onward.
Installing SimH is beyond the scope of this article, but see the References section below for links to the SimH sites. It is worth the extra effort to build the 4.0 versions of SimH, as they add a number of useful enhancements over SimH 3.9 ("Classic"). Building SimH is very easy on Unix-like operating systems like Linux and MacOS. Windows binaries are also available.
SimH is a command-line application, and includes a command interpreter for configuration, debugging, and device simulation. When you start the SimH pdp11 simulator, you are presented with a prompt:
PDP-11 simulator V4.0-0 Current git commit id: 01234567 sim>
The default configuration simulates a PDP-11/73 with 128kw of memory, a few hard disks, an Ethernet controller, and a few others. We want to simulate a PDP-11/20 with the high-speed paper tape reader and punch, and to disable the other devices that don't exist yet, we can use the commands
SET CPU 11/20 SET CPU 56k SET PTP ENABLE SET PTR ENABLE SET DZ DISABLE SET RK DISABLE SET RL DISABLE SET HK DISABLE SET RX DISABLE SET RP DISABLE SET RQ DISABLE SET TM DISABLE SET TQ DISABLE
SimH includes commands to simulate the programmer's console, allowing the user to virtually flip switches to deposit values into memory, as well as commads to look at memory values without having to simulate flipping switches and using the "EXAM" switch. For example, the paper tape Bootstrap Loader can be entered into the simulated system with
DEPOSIT 157744 016701 DEPOSIT 157746 000026 DEPOSIT 157750 012702 DEPOSIT 157752 000352 DEPOSIT 157754 005211 DEPOSIT 157756 105711 DEPOSIT 157760 100376 DEPOSIT 157762 116162 DEPOSIT 157764 000002 DEPOSIT 157766 157400 DEPOSIT 157770 005267 DEPOSIT 157772 177756 DEPOSIT 157774 000765 DEPOSIT 157776 177550
It can then be verified with the command
SimH simulates many devices, including our paper tape reader. If we
have the contents of the Absolute Loader tape in a file named
DEC-11-L2PC-PO.ptap (DEC-11-L2PC-P0 being Digital's catalog identifier
for the Abolute Loader tape), it can be attached to the reader with
ATTACH PTR DEC-11-L2PC-PO.ptap
Finally, we can run the Bootstrap Loader to load the Absolute Loader with
SimH will load Abolute Loader and halt when the Bootstrap Loader is complete. If you have a program you want to run, like the PAL-11A assembler for example (tape DEC-11-ASXA-PB), you can attach it to the reader, and run the Absolute Loader to load it with
ATTACH PTR DEC-11-ASXA-PB.ptap DEPOSIT SR 000000 GO 157500
At this point, the fifty year old PAL-11A assembler awakens from its long slumber with a prompt on the Teletype:
More on how to operate the assembler, and some tips on how to use SimH in a future article.
For most of us, the closest we will get operating a real PDP-11 is to build the PiDP-11 kit, which is a 60% scaled down panel for a PDP-11/70 with a Raspberry Pi running SimH inside.
PiDP-11 by Oscar Vermeulen