Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
xbox360 controller works as a mouse but not as a controller
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gamers & Players
View previous topic :: View next topic  
Author Message
walkingcorpse
n00b
n00b


Joined: 24 Apr 2017
Posts: 21
Location: Europe

PostPosted: Mon May 15, 2017 12:24 pm    Post subject: xbox360 controller works as a mouse but not as a controller Reply with quote

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
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 6920

PostPosted: Mon May 15, 2017 4:29 pm    Post subject: Reply with quote

Does it show up in Xorg.0.log? /proc/bus/input/devices?
Back to top
View user's profile Send private message
walkingcorpse
n00b
n00b


Joined: 24 Apr 2017
Posts: 21
Location: Europe

PostPosted: Mon May 15, 2017 9:22 pm    Post subject: Reply with quote

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
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 6920

PostPosted: Tue May 16, 2017 3:28 am    Post subject: Reply with quote

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
View user's profile Send private message
walkingcorpse
n00b
n00b


Joined: 24 Apr 2017
Posts: 21
Location: Europe

PostPosted: Tue May 16, 2017 11:58 am    Post subject: Reply with quote

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
View user's profile Send private message
walkingcorpse
n00b
n00b


Joined: 24 Apr 2017
Posts: 21
Location: Europe

PostPosted: Tue May 16, 2017 3:05 pm    Post subject: Reply with quote

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
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gamers & Players All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum