User Tools

Site Tools


bsd:notes:joystick

This is an old revision of the document!


Joystick Research

  • :!: Joysticks on FreeBSD need to be at /dev/uhid# 1)
  • uhidd by-default does /dev/uvhid#, that can be symlinked to /dev/uhid# or be done automatically with uhidd -H uhid
  • uhidd has a lot of flags in examples for keyboard/mouse/consumer, but a joystick only needs the virtual generic interface with uhidd -h
  • uhidd has to unbind whatever is on the joystick with uhidd -u
  • :?: Seemingly once uhidd takes control of the original /dev/input/event# device, if it had evdev or joystick forced through xorg.conf that driver gets unloaded according to Xorg.0.log
uhidd -h -H 'uhid' -u '/dev/ugen0.6'

devd.conf

su -
pkg install uhidd
ee '/usr/local/etc/devd/sidewinder-joystick-uhidd.conf'
notify 0 {
        match "type" "ATTACH";
        match "ugen" "ugen[0-9]+.[0-9]+";
        match "vendor" "0x045e";
        match "product" "0x0008";
        action "env LD_PRELOAD=/usr/lib/libcuse.so /usr/local/sbin/uhidd -h -H uhid -u /dev/$ugen";
};
1)
flightgear, neverball, seemingly doomsday but it freezes on launch
/srv/www/wiki/data/attic/bsd/notes/joystick.1726003906.txt.gz · Last modified: by Sean Rhone