View previous topic :: View next topic |
Author |
Message |
walkingcorpse n00b
Joined: 24 Apr 2017 Posts: 21 Location: Europe
|
Posted: Mon May 15, 2017 12:24 pm Post subject: xbox360 controller works as a mouse but not as a controller |
|
|
Hello, I tried both xpad and xboxdrv but I it only moves the cursor and it doesn't work as a controller...
How did you make yours work? |
|
Back to top |
|
|
Ant P. Watchman
Joined: 18 Apr 2009 Posts: 6920
|
Posted: Mon May 15, 2017 4:29 pm Post subject: |
|
|
Does it show up in Xorg.0.log? /proc/bus/input/devices? |
|
Back to top |
|
|
walkingcorpse n00b
Joined: 24 Apr 2017 Posts: 21 Location: Europe
|
Posted: Mon May 15, 2017 9:22 pm Post subject: |
|
|
Thank you for your answer,
Ant P. wrote: | Does it show up in Xorg.0.log? |
Yes:
Code: | [ 102.699] (II) config/udev: Adding input device Xbox Gamepad (userspace driver) (/dev/input/event12)
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "joystick-all"
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "joystick catchall"
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "joystick catchall"
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "keyboard-all"
[ 102.699] (II) Using input driver 'evdev' for 'Xbox Gamepad (userspace driver)'
[ 102.699] (**) Xbox Gamepad (userspace driver): always reports core events
[ 102.699] (**) evdev: Xbox Gamepad (userspace driver): Device: "/dev/input/event12"
[ 102.699] (--) evdev: Xbox Gamepad (userspace driver): Vendor 0 Product 0
[ 102.699] (--) evdev: Xbox Gamepad (userspace driver): Found absolute axes
[ 102.699] (--) evdev: Xbox Gamepad (userspace driver): Found x and y absolute axes
[ 102.699] (II) evdev: Xbox Gamepad (userspace driver): Forcing relative x/y axes to exist.
[ 102.699] (II) evdev: Xbox Gamepad (userspace driver): Configuring as mouse
[ 102.699] (**) Option "config_info" "udev:/sys/devices/virtual/input/input20/event12"
[ 102.699] (II) XINPUT: Adding extended input device "Xbox Gamepad (userspace driver)" (type: MOUSE, id 11)
[ 102.699] (II) evdev: Xbox Gamepad (userspace driver): initialized for absolute axes.
[ 102.699] (**) Xbox Gamepad (userspace driver): (accel) keeping acceleration scheme 1
[ 102.699] (**) Xbox Gamepad (userspace driver): (accel) acceleration profile 0
[ 102.699] (**) Xbox Gamepad (userspace driver): (accel) acceleration factor: 2.000
[ 102.699] (**) Xbox Gamepad (userspace driver): (accel) acceleration threshold: 4
[ 102.699] (II) config/udev: Adding input device Xbox Gamepad (userspace driver) (/dev/input/js0)
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "joystick-all"
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "joystick catchall"
[ 102.699] (**) Xbox Gamepad (userspace driver): Applying InputClass "keyboard-all"
[ 102.699] (II) Using input driver 'evdev' for 'Xbox Gamepad (userspace driver)'
[ 102.699] (**) Xbox Gamepad (userspace driver): always reports core events
[ 102.699] (**) evdev: Xbox Gamepad (userspace driver): Device: "/dev/input/js0"
[ 102.699] (EE) evdev: Xbox Gamepad (userspace driver): Unable to query fd: Invalid argument
[ 102.716] (EE) PreInit returned 2 for "Xbox Gamepad (userspace driver)"
[ 102.716] (II) UnloadModule: "evdev" |
Ant P. wrote: | /proc/bus/input/devices? |
Code: | I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="Xbox Gamepad (userspace driver)"
P: Phys=
S: Sysfs=/devices/virtual/input/input20
U: Uniq=
H: Handlers=js0 event12
B: PROP=0
B: EV=b
B: KEY=7cdb000000000000 0 0 0 0
B: ABS=3061b |
|
|
Back to top |
|
|
Ant P. Watchman
Joined: 18 Apr 2009 Posts: 6920
|
Posted: Tue May 16, 2017 3:28 am Post subject: |
|
|
Blacklist it from the X evdev driver:
/etc/X11/xorg.conf: | Section "InputClass"
Identifier "XBox Gamepad"
MatchProduct "Xbox Gamepad (userspace driver)"
Option "Ignore" "on"
EndSection |
|
|
Back to top |
|
|
walkingcorpse n00b
Joined: 24 Apr 2017 Posts: 21 Location: Europe
|
Posted: Tue May 16, 2017 11:58 am Post subject: |
|
|
Ok, now it doesn't control the cursor anymore but it still doesn't work in game (rocket league, speedrunners). It is strange that it doesn't work because js0 is producing output... |
|
Back to top |
|
|
walkingcorpse n00b
Joined: 24 Apr 2017 Posts: 21 Location: Europe
|
Posted: Tue May 16, 2017 3:05 pm Post subject: |
|
|
The problem is in the permissions of this 'file':
Code: | crw-rw---- 1 root input 13, 76 May 16 16:51 /dev/input/event12 |
I don't understand why this udev rule doesn't works:
Code: | KERNEL=="event[0-9]*", ENV{ID_BUS}=="?*", ENV{ID_INPUT_JOYSTICK}=="?*", GROUP="games", MODE="0660"
KERNEL=="js[0-9]*", ENV{ID_BUS}=="?*", ENV{ID_INPUT_JOYSTICK}=="?*", GROUP="games", MODE="0664" |
https://www.linuxquestions.org/questions/slackware-14/xbox-360-controller-not-recognized-by-steam-4175491243/#post5097871
But now that I know that it is event12 (from 'cat /proc/bus/input/devices') a simple chmod +r /dev/input/event12 should fix it without security issues. |
|
Back to top |
|
|
|