Re: [stella] keypad example

Subject: Re: [stella] keypad example
From: Darrell Spice <dspice@xxxxxxxxxxxxxx>
Date: Sat, 17 Apr 2004 12:14:24 -0500
On Apr 16, 2004, at 8:11 PM, Stephen Anthony wrote:

On April 16, 2004 10:23 pm, Darrell Spice wrote:
I've got reading the keypad figured out, but am having a problem with
the joystick not registering the direction left. All other directions
& fire button work fine.   Anybody have any ideas?

This isn't working in either Stella or z26 for Linux. But I don't know what the problem could be ...


thanx for taking a look. I found it this morning, amazing what a bit of sleep can do :-)

the problem was the color value was in the high-nybble of X. Because the lower nibble had all 0's, DEX decreased the high-nybble by one, but INX increased the low-nybble by one w/out affecting the high-nybble.

To fix the problem, I LSRed 4 times before putting the color into X, then ASLed 4 times after transferring the color back to A.

Attachment: controls.asm
Description: Binary data

Attachment: controls.bin
Description: application/macbinary

Darrell Spice, Jr.
Current Thread