Some of the programmable terminals have an onboard analog joystick on the
front panel.
The following interpreter function can be used to poll the joystick in your
application:
-
jx : joystick x-position, "calibrated"
-
Returns the horizontal position of the joystick as a "raw" value from the
analog/digital conterter.
Value range: -100=max. LEFT, 0=center, +100=max. RIGHT .
-
jy : joystick y-position, "calibrated"
-
Returns the vertical position of the joystick as a "raw" value from the
analog/digital conterter.
Value range: -100=max. DOWN, 0=center, +100=max. UP.
-
jxr : joystick x-position, "raw"
-
Returns the horizontal position of the joystick as a "raw" value from the
analog/digital conterter.
Value range: + / - 512
Center position: 0 (+/- mechanic and electronic tolerances); LEFT=negative,
RIGHT=positive .
-
jyr : joystick y-position, "raw"
-
Returns the vertical position of the joystick as a "raw" value from the
analog/digital conterter.
Value range: + / - 512
Center position: 0 (+/- mechanic and electronic tolerances); DOWN=negative,
UP=positive.
-
-
jc : joystick cursor emulation mode
-
If this flag is set (which is the default state), the analog joystick acts
as a replacement for the cursor keys.
The flag is set automatically when entering the terminal's system menu, because
without cursor keys you cannot navigate through that menu (and the first
device with such a joystick didn't have any "real" cursor key. Note: Pressing
the joystick button places code #13 (=RETURN or ENTER) in the keyboard buffer,
because the keyboard of the first terminal with a joystick didn't have an
enter key as well ;-)
See also:
Author: Wolfgang Buescher, MKT
Last modified: 2007-03-08