Take the 2-minute tour ×
Arqade is a question and answer site for passionate videogamers on all platforms. It's 100% free, no registration required.

Why did many commodore 64 games require the joystick to be in port #2, despite being single-player games?

I remember being annoyed by having to unplug and plug the joystick between games.

share|improve this question
3  
ha, I didn't remember this. I had a very big problem because when the joystick was plugged to that port it didn't work to move down, so there were games I could not play. +1! –  jmfsg Jul 14 '10 at 13:58
    
I agree with the selected answer, but I heard a rumour once that there was a tendency for American games tended to use one port and UK games the other. I never did an exhaustive study. –  Oddthinking Jul 15 '10 at 13:44
    
But why would that be? I always assumed that the 2# port was intended for plugging a second joystick for a two player game. It's also possible that for some reason it was easier, faster or in some other way more effective to read port #2 than port #1 for games. –  Petruza Jul 18 '10 at 12:21

3 Answers 3

up vote 23 down vote accepted

I never really thought about that much as a kid, when I had my C-64 (we just left a joystick plugged into #2 all the time).

However, after some digging, according to Ode to Joysticks:

Port 2 eventually emerged as the default, mainly because joysticks plugged into Port 1 could interfere with the command line interface.

Which is a good point, now that I read that, I do remember that having a joystick plugged into port #1 would send bizarre key codes to the primary BASIC interpreter/command line.

Ahhhh, memories!

share|improve this answer
2  
Yes! I remember that too! I had though it was on purpose!! –  jmfsg Jul 14 '10 at 14:28
    
Oh Yes!!!! one direction printed the number 2, I recall. Maybe Joystick port #1 used the same OS interrupts that those keys. Totally off-topic: when writing on the command-line, if you opened double quotes, special keys as the cursor, home, etc. would print a reversed char instead of performing their main function, until you closed the double quotes. This was for allowing printing special chars from basic code. I didn't realise this as a kid and sent my C64 to the technical service to get it fixed assuming the keyboard was malfunctioning :P –  Petruza Jul 14 '10 at 19:19
    
Hm, port 2 is read from $DC00 and port 1 from $DC01. I wonder if it might not also be because $DC00 is simply more logical to use. Port 2 will type characters as well. :) –  bzlm Sep 24 '10 at 14:29

My impression was that keys were given by port1 so you could read a joystick with the GET(A$) command just by checking for keypresses.

share|improve this answer

The Commodore 64 keyboard was wired as an 8x8 matrix; it was read by sequentially driving one of eight "row" lines low and then reading whether that caused one of the eight "column" lines to also go low. Joystick port 1 was wired to five of the eight column lines; joystick port 2 was wired to five of the eight row lines. During the time between keyboard scans, the keyboard row containing the space bar would be left active; if when the keyboard was polled the kernel observed any columns were active, it would assume that they represented keys pressed on that row. It would have been possible for the kernel to idle with no rows active, and assume that if any column is active before it scans the keyboard the column should be ignored, but the kernel doesn't do that. Consequently, moving a joystick plugged into port 1 will cause stray characters to be typed. Moving a joystick plugged into port 2 while typing something may cause some keys to be erroneously registered as other keys, but it will not generate stray keypresses by itself.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.