Lines Matching +full:on +full:- +full:axis
1 .. _joystick-api:
7 :Author: Ragnar Hojland Espinosa <ragnar@macula.net> - 7 Aug 1998
18 driver now reports only any changes of its state. See joystick-api.txt,
57 __u8 number; /* axis/button number */
65 -------------
74 events on open. That is, if it's issuing an INIT BUTTON event, the
86 ---------------
88 The values of ``number`` correspond to the axis or button that
90 is, you have both an axis 0 and a button 0). Generally,
93 Axis number
95 1st Axis X 0
96 1st Axis Y 1
97 2nd Axis X 2
98 2nd Axis Y 3
99 ...and so on
108 --------------
110 For an axis, ``value`` is a signed integer between -32767 and +32767
111 representing the position of the joystick along that axis. If you
141 -------------
145 task of detecting double clicks, figuring out if movement of axis and button
157 a) use select to wait until there's data to be read on fd, or
158 until it timeouts. There's a good example on the select(2)
161 b) open the device in non-blocking mode (O_NONBLOCK)
165 ----------
167 If read returns -1 when reading in O_NONBLOCK mode, this isn't
169 are no events pending to be read on the driver queue. You should read
170 all events on the queue (that is, until you get a -1).
219 In this case, read would return -1 if the queue was empty, or some
245 -------------
247 JSIOGCVERSION is a good way to check in run-time whether the running
249 IOCTL will fail. For a compile-time decision, you can test the
257 ----------
259 JSIOCGNAME(len) allows you to get the name string of the joystick - the same
271 -------------
273 For usage on JSIOC[SG]CORR I suggest you to look into jscal.c They are
315 int x; /* immediate x axis value */
316 int y; /* immediate y axis value */
330 The axis values do not have a defined range in the original 0.x driver,
331 except that the values are non-negative. The 1.2.8+ drivers use a