mass:werk / Blog

“Now Go Bang!” is named after a source comment in Spacewar!, the first digital video game.
It marks the very instance, when a spaceship which has been dragged into the gravitational star starts to explode. What follows, is impressionist pixel-dust floating along the ship’s former trajectory in a sparkling bloom of phosphor activation.

"now go bang" as found in the source code of Spacewar!

RSS feed: Subscribe.

Posts so far: 81, view as comprehensive list.

A few tags:computerhistory, infographics, software, pet2001, basic, pdp-1, archeology, retrochallenge, mixed-bag, long-read.

If you like what I’m doing, you can buy me a coffee: Buy me a coffee

A Guide to Commodore PETs

The original line-up of Commodore PET computers at a glance.

various models of the Commodre PET computer arranged in quadrants of the image

While Commodore PETs are quite easily and unmistakably identified by their unique form factor, the basic model evolved quite a bit over the years. Here’s a comprehensive guide to the various models of the original line-up (not including the later series with rounded case and separate keyboard) and their basic features.

Continue reading…

2024 X-Mas Demo (Commodore PET)

It’s that time of the year, again…

Screenshot: silhouette of a moonlit forest and Santa's sledge flying accross the screen, rendered in blocky PETSII graphics.
1 REM ***** 2024 X-MAS DEMO ***** 2 REM HTTPS://WWW.MASSWERK.AT/PET 3 REM *************************** 4 SYS 1140

This year’s seasonal tribute: a PETSCII animation based on a popular cross-stitch pattern.
Users are kindly requested to imagine that trademark eerily fluttering 1950s UFO sound effect that I find hard to achieve on the PET’s “CB2” sound*.

>Emulation: run it online

*) In case you were to ask, “What is CB2-sound?”
Well, the PET doesn’t feature sound, at all. But you can hook up a speaker to the output of a serial shift-register, creatively named “CB2”, which may be manipulated to output audible frequencies, sampling sound by a single bit at 1 MHz. This is CB2-sound.

Emulated hardcopy of the wiring diagram for CB2-sound on the Commodore PET
The famous wiring diagram for CB2-sound on the Commodore PET from the “Space Invaders” game. Later PETs included a built-in speaker, connected in the same fashion internally.

*****

The already tradional PET recreation of an animated screen of the 1982 Christmas Demo for the C64 has also received an update: it now fits into 4K of RAM and allows for easy updates, as the year is now stored in a dedicated variable at the very top of the BASIC program text.

Screenshot: an Advent arrangement with a candle in the middle featuring an animated flame in pure PETSCII graphics
100 REM PET 2001 - SEASON'S GREETINGS 110 REM NORBERT LANDSTEINER, 2017-2024 120 REM <WWW.MASSWERK.AT> 130 Y=2024:REM YEAR
(You may set Y to zero to omit the output of the year entirely.)

>Emulation: run it online

Japanese Attractions: Kana on the PET 2001

The Japanese character ROM and keyboard come to the PET 2001 emulator.

Katakana on the Commodore PET 2001 (emulation)

Another update to the PET 2001 emulator, spefically, a tribute to Japan and its importance to home computing history in general, and its role for Commodore in particular.

Continue reading…

“The Abominable iPhone Zombies”
– A PETSCII Horror Doom Scroller

A new game for the Commodore PET, also, how to detect keyboards on a Commodore PET.

The Abominable iPhone Zombies, a game for Commodore PET

Rumors that I am might be writing a game (or is it a playable joke?) are not entirey unfounded. Also, another (maybe helpful) note on PET keybords and how to detect them.

Continue reading…

Funny Games on a PET 2001N (or B)

A curious case of jumper settings for PETs with the dynamic system board.

A semi-abstract title illustration

The curious tale of a PET, two jumpers, and some funny games…

Continue reading…

The PET 2001 Emulator Debugger

A visual tour.

Illustration for the PET 2001 emulation debugger article

So a few words on the debugger for the PET 2001 emulator: this is meant to help you around with 6502 machine code on the virtual PET, both for exploring existing software and testing your own code.

Be my guest on a visual tour…

Continue reading…

The Commodore PET INPUT Bug-Feature

Adventures in MS BASIC (Commodore PET edition).

Well, another illustration

As it happens, I recently added a debugger to the PET 2001 emulator, with the expressed purpose of facilitating code reverse engineering. To celebrate this, we’ll risk a glimpse into a peculiar bug — or is it a feature? — of the BASIC flavor found on Commodore’s PET computers. Particularly, it’s about BASIC bailing out into a warm start, whenever an empty string is entered by just pressing RETURN on the INPUT prompt.

Continue reading…

Shiny New 6502 Thing

New 6502 emulator feature: Instruction preview with resolved operands.

Screenshot of the 6502 emulator at masswerk.at/6502

A new feature for the 6502 emulator: Now, there’s an instant preview for the effects of the next instruction to be executed, with effective values and operands resolved.

E.g., given the following memory and register content,

$2004: $88
$0044: $04 ;<$2004
$0045: $20 ;>$2004
    X: $04

the emulator will show the following preview for the instruction `A1 40` or “LDA ($40,X)”:

A ⇐ $88

resolving the X-indexed addressing and showing the effective value, which will be assigned to the A register (accumulator).

Or, for an ASL instruction, it may show this (depending on the content of A):

A ⇐ C < |10001000| < 0

And, for the instruction `CE 04 20` or “DEC $2004”, it may show:

[2004] ⇐ $88 - 1

Thanks to this preview of the effective values, which will be actually used, complex behavior may be followed more easily and common errors, like forgetting “#” to mark up immediate operands in the assembler (and using zeropage mode instead — the dreaded “LDX $00”), should become pretty obvious.
(I’m not aware, whether there is prior art for this idea or not.)

And, by popular demand, there is now a “RST” button, sending a RESET signal to the emulator.

Try the 6502 emulator.