Use the XBox 360 controller with Arch Linux
I was pleasantly surprised today when I plugged in an XBox 360 controller into my Arch Linux box today and it lit up! I was excited to show my girl that she could still play “Yoshi’s Island” just as she had years ago. I soon found that even though the controller appeared to be connected, there was no way to play with the controller yet.
She assured me that it was fine and really not a big deal. I tried a few things like rebooting, reading a few forums, and even popping my head in
irc again to see if others were using it successfully. After half an hour of playing around I decided to
RTFM of the tool I decided to try which is called
When I initially ran the program
xboxdrv, the output looked like this:
-- [ ERROR ] ---------------------- No Xbox or Xbox360 controller found
This really pissed me off because the controller was obviously plugged in and lit up. Also, I really just wanted to use the controller to impress my girl. In the troubleshooting section of the man page, I read:
As an alternative you can also use the --device and --type option to enforce a USB device as well as a controller type an bypass any auto detection.
Just as she came back from throwing together a delicious meal, she asked how it was going. I assured her that she was my lucky lady and since she was there it would probably work. To impress her with magic, I typed two incantations.
The first was to find the USB device path that
xboxdrv needs to locate the controller.
Which produces output like:
Bus 002 Device 005: ID 04f2:b1b9 Some Corporation
The path is the combination of Bus number and the Device number. So
002:005 would be the path. Then the second command was to call
xboxdrv with the manual options.
sudo xboxdrv --device-by-path 002:005 --type xbox360
With that, I noticed that the controller was now being detected and various buttons caused the terminal output to change. I told her she was indeed lucky and started the Super Nintendo emulator. I mapped the buttons correctly and handed her the controller after loading “Yoshi’s Island”.
I scooped a plate of food for myself and settled into the couch to enjoy watching her playing her favorite childhood video game. A game she played for about an hour straight.