[stella] New Guy

Subject: [stella] New Guy
From: Paul Slocum <paul-slocum@xxxxxxxxxxxxxx>
Date: Thu, 09 Aug 2001 23:37:42 -0500
Hey guys. I'm Paul, and I just joined the list. Right now I'm working on a new 2600 tester cart. I thought the original diagnostics was just about useless, so I decided to make a better one. My cart uses the Stellar Track text engine for most of its display.

I've also recently built a 100 game multicart with an onscreen menu system also using Stellar Track kernal. I'm working on a way to mass produce the circuitry required. Currently I've only made one because it took about 6 hours to hand wire and solder the circuit and cram it in a cartridge.

My question: does anyone know how long you need to wait to read the keyboard controllers? The guide states 400 microseconds. See if my thinking is sound: A processor running at 1MHz eats a cycle once every microsecond. So since the Atari runs at 1.3MHz, a cycle lasts a little less than a microsecond. So I need to wait a little more than 400 cycles. About 530 or so. My testing seems to confirm this, but I wanted to double check. The Colecovision with the Atari adapter was the most finicky about the delay being long enough.

Some ideas:

The Commodore 64 Programmer's Reference Guide is an excellent 650x reference. Tells you EVERYTHING you would ever need to know. Has a detailed list of all instructions with OP CODEs, addressing, no. of cycles used, etc. These books are for sale on ebay all the time.

About paddles. This method worked best for me:

	LDA INPT0	;3 cycles
	BMI charged1	;2 or 3 cycles
	DEC Pot1	;5 cycles = 6 or 10 cycles
charged1

This was also suggested as a method of reading the paddles:

	lda INPT0	;3 cycles
	asl		;2 cycles
	adc Pot1	;3 cycles
	sta Pot1	;3 cycles = 11 cycles

But I found that although only bit 7 in INPTx is documented as used, you can't assume that the unused bits are zero. So you have to make it:

	lda INPT0	;3 cycles
	and #%10000000	;2 cycles
	asl		;2 cycles
	adc Pot1	;3 cycles
	sta Pot1	;3 cycles = 13 cycles

-Paul



-
Archives (includes files) at http://www.biglist.com/lists/stella/archives/
Unsub & more at http://www.biglist.com/lists/stella/

Current Thread