[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Joystick Devices
In article <Pine.A32.3.93.960801074240.45609A-100000@freenet4.afn.org>,
Donald 'X-caiver' Pattee Jr <afn45687@afn.org> wrote:
>Yes, I tested the buttons and such using my little BASIC program. That is
>where I dcided that I could not get any valid position data.
>I was using the print peek(29250) [and the other numbers in that area) to
>detect button presses and joystick position.
Unless you've got some machine language things loaded, the joystick
info is definitely _not_ in that area. 29250 = $7242, which is
available main ram for programs.
Further, you can _NOT_ reliably read the joystick from Basic with
PEEK()s. Because the joystick is essentially an analog device, you
must call a tightly calibrated machine language loop which performs
the necessary info to do the A-D conversion. Use PDL(0) and PDL(1)
to read it.
P.S. Lose the large .sig
Nathan Mates
--
<*> Nathan Mates http://www.ugcs.caltech.edu/~nathan/ <*>
# And he said to them, "To you has been given the secret of the
# Kingdom of God, but for those outside, everything comes in
# parables" Mark 4:11, NRSV