8

As mentioned on my Were there any standard tricks to fix PET upper/lower case differences? question, I'm trying to figure out what to expect when running software generically labelled as "PET" on my Model 4016.

A disk of games I found included some space-themed target practice game. The instructions were kind of vague and just said something like "use the numberpad like normal" but when I went to play it didn't not work as expected. Instead of like 8 being up, 4 being left, etc. I found through experimentation that it was something more like * went left, 2 went up, some letter like S (!) made it go right, and I never found a key to make it go down! [I probably have the specifics wrong and could test again this evening if the details are important.]

Were there lower-level scancodes available, that some games relied on, which would explain this behavior? Like on my other question about upper/lowercase, was there a sort of standard expectation that users would patch up software if this was an unavoidable compatibility difference between models? Or is it more likely the code just got corrupted somewhere between the 1980s and me LOADing it?

(Possibly related to What were Commodore's keyboard layouts before the VIC-20? but that doesn't go much into the software side of things.)

1 Answer 1

8

The PET keyboards did have something akin to scan codes. Electrically, the keys were arranged in a matrix of rows and columns, and scanning the keyboard involved selecting each row in sequence (via one of the PIA chips), then reading the column values to see which (if any) keys in that row were pressed. Since there were two keyboard layouts (the 'graphics' keyboard and the 'business' keyboard) it is entirely reasonable to suppose that the game you're running was intended to be used with a different keyboard that had a different row/column layout.

1
  • 3
    If you are interested in more details about the keyboard layout, here is a good resource: 6502.org/users/andre/petindex/keyboards.html Note that row 5 bit 7 is * on the graphics keyboard and keypad 4 on the business keyboard, matching the behavior reported in the question.
    – Ken Gober
    May 7, 2021 at 16:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .