Hello,
I have a cheap but cool Thrustmaster gamepad and I want to use it for playing games in FreeBSD emulators. I tried to configure it but I really don't now very much about this process. Here is what I've done.
I have a cheap but cool Thrustmaster gamepad and I want to use it for playing games in FreeBSD emulators. I tried to configure it but I really don't now very much about this process. Here is what I've done.
- I installed xf86-input-joystick and uhidd from ports
- I added these lines to rc.conf:
Code:uhidd_flags="-kmohs" uhidd_enable="YES"
- When the gamepad is plugged in, the kernel said:
Code:
uhid0: <Mega World USB 2-Axis 8-Button Gamepad, class 0/0, rev 1.10/1.01, addr 3> on usbus1
- I added these lines to xorg.conf:
Code:Section "ServerLayout" Identifier "X.org Configured" Screen 1 "Screen1" 0 0 InputDevice "Mouse0" "CorePointer" InputDevice "Keyboard0" "CoreKeyboard" [B]InputDevice "Joy0" "SendCoreEvents"[/B] EndSection Section "InputDevice" Identifier "Joy0" Driver "joystick" Option "Path" "/dev/uhid0" Option "Device" "/dev/uhid0" # Right Buttons # Button w(Up)/s(Down) # Button a(Left)/s(Right) Option "MapAxis1" "mode=accelerated keylow=38 keyhigh=40" Option "MapAxis2" "mode=accelerated keylow=25 keyhigh=39" # Right joystick: Like mouse Option "MapAxis3" "mode=relative axis=+1x deadzone=5000" Option "MapAxis4" "mode=relative axis=+1y deadzone=5000" # Left joystick: # axis X - Left/Right # axis Y - Up/Down Option "MapAxis5" "mode=relative deadzone=28000 keylow=100 keyhigh=102 axis=0.15key" Option "MapAxis6" "mode=relative deadzone=28000 keylow=98 keyhigh=104 axis=0.15key" # Option "MapButton1" "key=10" Option "MapButton2" "key=11" Option "MapButton3" "key=12" Option "MapButton4" "key=13" Option "MapButton5" "key=14" Option "MapButton6" "key=15" # mouse button: left Option "MapButton7" "button=1" # mouse button: right Option "MapButton8" "button=3" # button "Space" Option "MapButton9" "key=65" # button "Enter" Option "MapButton10" "key=36" EndSection
The current behavior: xev doesn't show any event when the gamepad buttons are pressed.
The Xorg.0.log joystick part here:
Code:[ 52.975] (II) Using input driver 'joystick' for 'Joy0' [ 52.975] (II) Loading /usr/local/lib/xorg/modules/input/joystick_drv.so [ 52.975] (**) Option "SendCoreEvents" [ 52.975] (**) Joy0: always reports core events [ 52.975] (II) No input driver specified, ignoring this device. [ 52.975] (II) This device may have been added with another device file. [ 52.975] (EE) PreInit returned 11 for "Joy0" [ 52.975] (II) UnloadModule: "joystick" [ 52.975] (II) Unloading joystick
Can you help me, please, to understand what have I done wrong here?
Thank you.