Getting the SIMH PDP-8 Paper Tape Punch (PTP) Installed

(all PDP-8 blog entries can be seen by clicking here)

I wanted to experiment with reading/writing paper tape with the SIMH PDP-8 emulator; however, I discovered the distribution of OS/8 I have does not have the paper tape punch installed.

These instructions assume that you have created an RK05 hard drive as I did earlier using this blog entry:

PDP-8 SIMH Emulator: Building and Formatting an RK05 Hard Drive

If you are using the image from that blog entry, it does not have a paper punch defined. In OS/8, you can see what devices you have by typing RES/L:

.RES/L

2363 FREE BLOCKS

 NAME TYPE USER
 SYS  RK8E
 DSK  RK8E
 PTR  PTR
 RXA0 RX8E
 RXA1 RX8E
 RKA0 RK8E
 RKA0 RK8E
 RKB0 RK8E
 RKA1 RK8E
 RKB1 RK8E
 TTY  TTY
 LPT  LPTR

OS/8 V3Q

The device name for the paper tape reader is PTR which IS defined. The device name for the paper tape punch is PTP which is NOT defined.

To define the paper tape punch we need to run the BUILD utility again as was done when setting up the hard drive.

When I ran BUILD the first time I did not understand that one must SAVE the image of BUILD in memory onto itself on disk to maintain the configuration changes for the BUILD utility. This time, after we BUILD the system, we will properly save the configuration.

Assuming you have used the same system image to build your hard drive as I did, here are the commands to re-implement the hard drive AND install the paper tape punch.

.RUN SYS BUILD

$DELETE SYS

$INSERT RK8E:SYS

$INSERT RK8E:RKA0

$INSERT PT8E:PTP

$DSK=RK8E:SYS

$PRINT

PT8E: *PTP  *PTR
RX8E:  SYS
RX01: *RXA0 *RXA1
RK8E: *SYS  *RKA0  RKB0
RK05: *RKA0 *RKB0 *RKA1 *RKB1  RKA2  RKB2  RKA3  RKB3
KL8E: *TTY
LS8E: *LPT

DSK=RK8E:SYS
$BOOT
SYS BUILT
.SAVE SYS BUILD

INSERT PT8E:PTP installed the paper tape punch. SAVE SYS BUILD saved the executing program in memory back to the BUILD file on disk so the next time BUILD is run, it reflects the actual state of the system.

To verify the paper tape punch and reader work, let’s punch some paper tape and read it back.

To use the paper tape punch, you must get back to the SIMH prompt (control-E) and attach the PTP device to a physical file (note that if the file already exists, this process will erase it). Here I attach the file ptape1.bin to ptp:

Simulation stopped, PC: 01207 (KSF)
sim> attach ptp ptape1.bin
PTP: creating new file
sim> go

.

Now I will create a simple file and punch it using the PIP utility. Finally, I must go back to SIMH and detach the punch from the physical file:

.CREATE TEST.TX
#I
THIS IS A TEST.
#L
THIS IS A TEST.
#E

.TYPE TEST.TX
THIS IS A TEST.

.R PIP
*PTP:<TEST.TX
*^C

.
Simulation stopped, PC: 01207 (KSF)
sim> detach ptp

To read back the paper tape, attach the reader to the physical file and run PIP to copy the paper tape to the file TEST2.TX:

sim> attach ptr ptape1.bin
sim> go
.R PIP
*TEST2.TX<PTR:
^

Not sure what PIP is doing when it prints the “^” prompt, but you press escape to get the * prompt, and then control-c to exit PIP. You CANNOT press control-C at the ^ prompt – no data will be transferred if you do.

^*^C
.TYPE TEST2.TX
THIS IS A TEST.

You have successfully created a paper tape and read it back. I will use this for the next blog entry where I assemble machine code to paper tape and load it into memory and execute it.

This entry was posted in c-retro and tagged . Bookmark the permalink.

1 Response to Getting the SIMH PDP-8 Paper Tape Punch (PTP) Installed

  1. Constantino says:

    Thank you for your PDP-8 posts! They’re a valuable resource for those getting into these computers. The ^ on PIP was getting on my nerves, but now I see how it works!

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.