Home‎ > ‎

Joymap

This project has been replaced by a joystick programming system implemented completely in userspace at http://linuxjoymap.sf.net. (Also available at  https://code.launchpad.net/linuxjoymap)

The old version of the software will remain here for reference purposes.

Joymap - joystick programming for Linux

The standard Linux joystick driver supports several axes and buttons. However, not all software supports all axes and buttons. The current disadvantages of the Linux joystick driver include:
  • If several joysticks are available on a platform, then it may not be possible to use all of the joysticks in a particular application. Applications often allow only one joystick to be selected as a controller.
  • Not all buttons or joystick axes can be assigned to actions within the program.
  • For USB joysticks, the order of detection of the joystick determines which joystick number the joystick is assigned to. If the joysticks need to be unplugged and then reinserted, the joystick numbering may differ.
The Joymap driver and software allows the joystick subsystem to be programmed by installing virtual joysticks, a virtual keyboard and virtual mouse. Existing joysticks are identified by product and vendor so that the mapping is always correct even if the joysticks are unplugged and reinserted.

The driver and software is in an early alpha stage, but it has been used successfully on the authors machine. No warranty is supplied whatsoever. Several sections of the code do not perform sanity checks to ensure the correct working of the system and the compiler has been used, but is not comlpetely tested.

Maintainer

If you have problems you can contact me via email at alexandre.hardygmail.com. However, writing software is not my primary job! So it may be some time before I can provide a satisfactory solution to your problem. I would be interested to hear from anyone who wishes to take over maintenance of the driver and related software.

Installation instructions

The Joymap driver has been designed for kernel 2.6.19. If you wish to provide patches for different kernels, please let me know! Instructions for installing follow below (there are NO autoconf/automake scripts or any such pleasantries!)
  1. Download joymap-0.0.1.tar.gz
  2. Extract the files
    tar xvzf joymap-0.0.1.tar.gz
  3. cd driver
  4. make
  5. cp joymap.ko /lib/modules/`uname -r`/kernel/drivers/input (as root)
  6. depmod -a (as root)
  7. cd ../joymap
  8. make
  9. If you use udev, cp 70-joymap.rules /etc/udev/rules.d (as root)
  10. Otherwise (no udev) make the device node for programming
    mknod /dev/mapper c 240 0 (as root)
  11. Copy loadmap and unmap to somewhere accessible in your path
  12. Copy the manual pages to an appropriate location
  13. Make sure that joymap is loaded before other joystick drivers. On my Slackware system with USB joysticks I modified /etc/rc.d/rc.local to begin with
    rmmod ehci_hcd
    rmmod ohci_hcd
    rmmod joymap 
    modprobe joymap 
    modprobe ehci_hcd 
    modprobe ohci_hcd 

Documentation

A configuration file is required to define the mapping. The details of this configuration file are described in config.pdf.

The mapping can be extended by writing short programs to control a virtual joystick, whose output can then be mapped through the joystick mapping driver again. The details of this programming langauge, with a few short examples are described in program.pdf.

Download

Ċ
Alexandre Hardy,
Sep 7, 2009, 12:28 AM
ċ
joymap-0.0.1.tar.gz
(196k)
Alexandre Hardy,
Sep 7, 2009, 12:27 AM
Ċ
Alexandre Hardy,
Sep 7, 2009, 12:28 AM
Comments