Path: utzoo!attcan!uunet!lll-winken!lll-tis!helios.ee.lbl.gov!pasteur!ucbvax!hplabs!hp-sdd!ncr-sd!crash!maddie From: maddie@crash.cts.com (Tom Schenck) Newsgroups: comp.sys.apple Subject: Re: Problem Message-ID: <3357@crash.cts.com> Date: 23 Aug 88 19:11:27 GMT References: <7497@srcsip.UUCP> Reply-To: maddie@crash.CTS.COM (Tom Schenck) Organization: Crash TS, El Cajon, CA Lines: 42 Here's a little demonstration of what's happening : Put your //gs at SLOW system speed, exit to BASIC, and run the following program - 10 PRINT PDL(0), PDL(1):GOTO 10 You should see a long row of values, both somwhere close to 128 (120-135). Now change your system speed to FAST, and run it again. You should get two long columns of numbers, from 250-255. A lot of the time, they will ONLY be 255. The problem derives from the Apple ROM routines. The way they get a joystick reading is thusly: -Reset the joystick timer -wait for the timer to reach 0 -if the timer doesn't reach 0 in a reasonable number of cycles, then it equals 255. From simple deductive reasoning, you can see that there is a problem when this routine (written for the old days of 1.023 Mhz Apples) is run at faster than 1.023 Mhz, namely the 2.5-2.8 Mhz of the fast //gs system speed. Now that I've explained all that, why doesn't it recognize the joystick? Well, 16-bit programs NORMALLY run at the fast system speed, and they also usually use Apple ROM routines. If, for some reason, you don't re-adjust your joystick (By turning the adjustment knobs while running the above program in FAST system speed until both columns are about 128), then the program reads 255 from the joystick. Well, if you UNPLUG your joystick , and run the program, you'll get two long columns of 255's, and nothing else. Most programs don't expect you to have your joystick set like that, so if they read 255 when they first run, it's assumed you don't have a joystick hooked up to you //gs. -- UUCP: {cbosgd, hplabs!hp-sdd, sdcsvax, nosc}!crash!pnet01!maddie ARPA: crash!pnet01!maddie@nosc.mil INET: maddie@pnet01.CTS.COM Disclaimer : The only company who's thoughts are my own is owned by me. Tom Schenck, member 52nd Street Development Team.