Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I am trying to add a udev alias rule for my xboxdrv (x-box controller) and I can't seem to figure it out.

dmesg | grep "input"

I see:

[    6.239955] input: Microsoft X-Box 360 pad as /devices/platform/bcm2708_usb/usb1/1-1/1-1.3/1-1.3:1.0/input/input2
[   27.057308] input: Xbox Gamepad (userspace driver) - Keyboard Emulation as /devices/virtual/input/input3
[   27.058307] input: Xbox Gamepad (userspace driver) as /devices/virtual/input/input4

It looks likes its input 3 and 4. So I check:

sudo udevadm info -a -p /devices/virtual/input/input3

which gives me:

looking at device '/devices/virtual/input/input3':
    KERNEL=="input3"
    SUBSYSTEM=="input"
    DRIVER==""
    ATTR{name}=="Xbox Gamepad (userspace driver) - Keyboard Emulation"
    ATTR{phys}==""
    ATTR{uniq}==""
    ATTR{properties}=="0"

And input4

  looking at device '/devices/virtual/input/input4':
    KERNEL=="input4"
    SUBSYSTEM=="input"
    DRIVER==""
    ATTR{name}=="Xbox Gamepad (userspace driver)"
    ATTR{phys}==""
    ATTR{uniq}==""
    ATTR{properties}=="0"

I think I have enough info to create my udev rule. I create a new file called 99-x-box.rules in '/etc/udev/rules.d'. I added the following:

SUBSYSTEM=="input", ATTR{name}=="Xbox Gamepad (userspace driver) - Keyboard Emulation", ATTR{properties}=="0", SYMLINK+="xboxcontroller"

I reboot. I dont see the alias in `/dev/input'. I also tried:

SUBSYSTEM=="input", ATTR{name}=="Xbox Gamepad (userspace driver)", ATTR{properties}=="0", SYMLINK+="xboxcontroller"

thanks for the help.

share|improve this question
    
I guess the symlink is not one level up in /dev either? –  goldilocks Mar 30 at 14:48
    
@goldilocks - no its not in /dev/ –  Phil Vallone Mar 30 at 18:02
1  
I think I resolved the issue. The xboxdrv adds a udev entry already crw-rw---T 1 root input 13, 0 Mar 30 17:54 /dev/input/js0 –  Phil Vallone Mar 30 at 18:16

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.