Commodore PET Programs
A bit of Computer Archeology
Back at the end of the 1970's and at the start of the 1980's, I was a pupil
at Keswick School. During this time, the school bought two Commodore PET computers
("Personal Electronic Transactors"). Initially, there was one model 2001-8N
but, later, a new model 3008 - with more memory and a full-size keyboard - was purchased.
I was the only pupil at the school to have my own key to the computer room. By the time
I was in the 6th form, my ownership of the key had actually become legitimate!
I built up a fair collection of programs for the PET, most of which I wrote
myself in BASIC. A few were hand-coded in 6502 machine-code. Some others were
typed in from magazines, written by other pupils from Keswick School or obtained
from other sources. The programs were saved onto cassette tapes, which I
kept and had latterly been stored in an old shoebox in my loft for nearly 20 years.
The time finally came in 2009 to try and recover the programs from the
cassette tapes. A bit of digging round on the Internet and trying out a few
different ways of decoding the data resulted in the following, successful, method:
- Connect up the line-output of a (half-decent) cassette deck to the
line-input of the sound card in a standard desktop PC (the one I used runs
the "Testing" distribution of Debian GNU/Linux).
- Set the audio mixer to capture only the line input for recording,
i.e. mute the microphone, etc. I found that setting the line-input and
capture levels to about 70% seemed to work best; obviously your ideal
setting could be very different, depending upon the equipment that you
- Use the arecord utility to record the output of the
cassett deck and create a single, large, ".wav" file for each
side of the tape. Depending upon your computer's O/S, you may need to
use different software to capture the audio into a ".wav" file.
- Use the
utility with the -op:[directory] option to process the
- If the tape64 program fails to extract all (or any!) of
the programs from the ".wav" file, then go back to step (2) and try
again with different recording levels. It took me a few goes, with different
levels for different sections of each tape, before I got all the programs extracted.
- Install VICE, the
Versatile Commodore Emulator
onto your computer.
- You can now use the petcat command to de-tokenise the
binary programs into a human readable text format.
- Track down the ROM images that the VICE emulator requires. Searching the Internet
for "vice-1.5-roms" should get you what you need.
- Run the emulator using the xpet command, passing the name
of a binary program to it.
- Revel in the retro-glory of it all!
Some scans, of photographs from circa 1981, showing a few of the programs running
on original Commodore Pets!
I had three tape-fulls of programs, but there was a large overlap between them.
The following list is the result of trying to pick the latest version of any
given program. Both the binary version - ready to run in VICE - and the human-
readable listing, or HEX dumps of machine code programs, are given.
The descriptions of the programs, with any specific notes that were preserved on
the A4 sheets of paper that had survived with the tapes, are included. For anything
further, you'd probably be best off reading the listings and working it out - my
memory really doesn't go back 30 years or more!
Most of the programs run fine in several different (emulated) models of the PET. Select
model 8032 in VICE and you should be fine. The few programs that are specific to the older
2001-8N model PET are flagged up in the notes, above.
For several of the games, keys on your PC's numeric keypad should control movement,
but make sure that you have NUM LOCK on, or this won't work!
A few of the odder low-level programs might not work in any sane way in the emulator, but
they are included here in case anybody want's to try them on a real PET!
Other programs may be of dubious value, or their function may be too obscure to understand,
but are here for completeness.