8.5.0. joystick

This class allows to read data from a joystick using the joystick device interface on Linux. This was tested with USB joysticks. This DOES NOT enqueue events into Lush's centralized event queue. The joystick driver is generally not loaded into the Linux kernel by default. Therefore, yo might have to do "/sbin/insmod joydev" as root. (new joystick device)
[CLASS] (packages/devices/joystick.lsh)

create a an instance of the joystick class on the device device . device must be a valid joystick device e.g. (new joystick "/dev/input/js0") . (==> joystick read)
[MSG] (packages/devices/joystick.lsh)

this method reads the joystick position and the state of the buttons. The actual values can then be obtained by looking at the axis, button and buttontoggle slots of the joystick object. Each of those is an idx of ints containing the values for each axis and button. (joy-test [delay [device])

simple graphical display of joystick values and events reasonnable values for delay are 0 to 0.1. above this, event might be lost. device must be a valid joystick device such as "/dev/input/js0", which is the default value.