• Home
  • Raw
  • Download

Lines Matching +full:len +full:- +full:or +full:- +full:define

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,
20 information. The joystick device can be used in either blocking or
65 -------------
69 #define JS_EVENT_BUTTON 0x01 /* button pressed/released */
70 #define JS_EVENT_AXIS 0x02 /* joystick moved */
71 #define JS_EVENT_INIT 0x80 /* initial state of device */
79 If you choose not to differentiate between synthetic or real events
86 ---------------
88 The values of ``number`` correspond to the axis or button that
108 --------------
110 For an axis, ``value`` is a signed integer between -32767 and +32767
112 don't read a 0 when the joystick is ``dead``, or if it doesn't span the
141 -------------
157 a) use select to wait until there's data to be read on fd, or
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
170 all events on the queue (that is, until you get a -1).
195 mentioned, or because too much time elapses from one read to another
219 In this case, read would return -1 if the queue was empty, or some
231 #define JSIOCGAXES /* get number of axes char */
232 #define JSIOCGBUTTONS /* get number of buttons char */
233 #define JSIOCGVERSION /* get driver version int */
234 #define JSIOCGNAME(len) /* get identifier string char */
235 #define JSIOCSCORR /* set correction values &js_corr */
236 #define JSIOCGCORR /* get correction values &js_corr */
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
260 as is being printed at boot time. The 'len' argument is the length of the
271 -------------
275 such as jscal or kcmjoy. These IOCTLs and data types aren't considered
292 #define JS_CORR_NONE 0x00 /* returns raw values */
293 #define JS_CORR_BROKEN 0x01 /* broken line */
321 #define JS_RETURN sizeof(struct JS_DATA_TYPE)
331 except that the values are non-negative. The 1.2.8+ drivers use a
348 U to "Use The Source Luke" or, at your convenience, Vojtech ;)