Xbox Series X|S Wireless controller in Fedora/Steam

I recently had to replace a chep quality Xbox-like controller with a proper one, so I decided to get an Xbox controller. This gives me the proper experience in Steam and games which support Xbox controllers in the various configuration options.

I’ve decided to purchase an Xbox Series X|S Wireless controller, which is USB / USB-C or BLE (Bluetooth Low Energy). No issues with USB, the controller is recognized properly, including vibration, but to get it working via Bluetooth it requires a bit of extra software.

image

So here are the packages and how to connect it.

USB / USB-C connection

Just plug it in, it will instantly be recognized. Nothing else to do in this case.

usb 1-3: new full-speed USB device number 12 using xhci_hcd
usb 1-3: New USB device found, idVendor=045e, idProduct=0b12, bcdDevice= 5.07
usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-3: Product: Controller
usb 1-3: Manufacturer: Microsoft
usb 1-3: SerialNumber: 3039373133333431323636313230
input: Generic X-Box pad as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3:1.0/input/input31
usb 1-3: USB disconnect, device number 12

Bluetooth Low Energy connection

Requirements:

  • An up to date 5.13 kernel (already available in Fedora updates)
  • A Bluetooth Low Energy adapter in your system
  • Updated firmware on the controller (5.7 at the time of writing this)
  • Packaged xpadneo software

Firmware update

First of all, make sure your firmware is up to date on the device. Before updating the firmware, I had some issues with Bluetooth constantly cycling with pairing. To update the firmware, unfortunately you have to use a Windows system.

Install the Xbox Accessories app, plug in the controller and follow the wizard to update the controller.

If you already attempted to pair the controller without updating the firmware and then you try again with the new firmware, you might have issues pairing. To fix this, delete all cache files of the Bluetooth stack in Fedora before attempting the connection again:

find /var/lib/bluetooth/ -name cache -exec rm -fr {} \;

Bluetooth Low Energy Adapter

Just run this command, if it shows the setting “le” then it means you have Low Energy support:

$ btmgmt info
Index list with 1 item
hci0:	Primary controller
	addr 00:0A:CD:3B:E0:A5 version 6 manufacturer 10 class 0x7c0104
	supported settings: powered connectable fast-connectable discoverable bondable link-security ssp br/edr le advertising secure-conn debug-keys privacy static-addr phy-configuration 
	current settings: powered connectable discoverable ssp br/edr le secure-conn 
	name workstation.localdomain
	short name 

Packaged xpadneo software

The necessary packages are both in the Steam repository and the Multimedia repository.

Execute one of the following commands to install the appropriate packages.

With akmod:

# dnf -y install akmod-xpadneo
# akmods --force

With DKMS:

# dnf -y install dkms-xpadneo
# dkms build -m xpadneo/0.9.1 
# dkms install -m xpadneo/0.9.1

If you don’t want to trigger the builds manually you can just reboot the system, both DKMS and akmods will take care of rebuilding the necessary kernel modules.

Checking that everything works in BLE mode

Open the GNOME Bluetooth settings, then:

  • Keep the wireless button on the controller pressed for a few seconds until the Xbox logo blinks fast
  • Click on the Xbox Wireless Controller - Not set up entry

After pairing, you will see the following entry in the Bluetooth settings panel:

xbox-bt-paired

And in the Power settings panel you can also see the battery status:

xbox-bt-battery

Finally, in the kernel messages you should see a message like the following:

xpadneo 0005:045E:0B13.0004: pretending XB1S Windows wireless mode (changed PID from 0x0B13 to 0x02E0)
xpadneo 0005:045E:0B13.0004: working around wrong SDL2 mappings (changed version from 0x00000507 to 0x00000903)
xpadneo 0005:045E:0B13.0004: report descriptor size: 283 bytes
xpadneo 0005:045E:0B13.0004: fixing up Rx axis
xpadneo 0005:045E:0B13.0004: fixing up Ry axis
xpadneo 0005:045E:0B13.0004: fixing up Z axis
xpadneo 0005:045E:0B13.0004: fixing up Rz axis
xpadneo 0005:045E:0B13.0004: fixing up button mapping
xpadneo 0005:045E:0B13.0004: enabling compliance with Linux Gamepad Specification
input: Xbox Wireless Controller as /devices/virtual/misc/uhid/0005:045E:0B13.0004/input/input32
xpadneo 0005:045E:0B13.0004: input,hidraw2: BLUETOOTH HID v9.03 Gamepad [Xbox Wireless Controller] on 00:0a:cd:3b:e0:a5
xpadneo 0005:045E:0B13.0004: controller quirks: 0x00000050
xpadneo 0005:045E:0B13.0004: Xbox Wireless Controller [f4:6a:d7:72:3c:ef] connected

If everything is good, then let’s check how Steam reports the controller:

xbox-bt-steam-bp

Voilá, you have an Xbox controller running over Bluetooth LE without any extra dongle.

Powering on / off the controller

After a bit of time without using the controller, it will turn off on its own. To bring it up again and quickly re-pair it, just press the Xbox logo on it.

9 thoughts to “Xbox Series X|S Wireless controller in Fedora/Steam”

  1. Do you know why The Xbox Series X controller is recognized as Xbox One controller? The same happen with Elite Series 2 controller. It drives me nuts because Steam shows the wrong image for the controllers

  2. I was able to get the controller working with xpadneo, and played Ori and the Blind Forest without any problems with the gameplay.

    The only thing I’m wondering about is how can I get the Home/Guide/Xbox button work with Steam so that it launches the overlay in Big Picture mode, like it supposedly does on Windows. Steam’s chord shortcuts also work with the Guide button, e.g Guide + RT should take a screenshot.

    I read some issues on GitHub, and it seems like the Home/Guide/Xbox button is actually mapped to a different HID device, separate from the gamepad device. The button press is mapped to BTN_MODE, which does not seem to be recognized by Steam. The same keycode is also emitted for the Xbox when using the hid-generic driver of the kernel instead of xpadneo. Neither driver activates the Steam overlay when pressing that button.

  3. Hey, I’m getting an errormessage for either install method:

    [root@fedora seby]# akmods –force
    Checking kmods exist for 5.14.9-200.fc34.x86_64 [ OK ]
    Files needed for building modules against kernel
    5.14.9-200.fc34.x86_64 could not be found as the following
    directories are missing:
    /usr/src/kernels/5.14.9-200.fc34.x86_64/
    /lib/modules/5.14.9-200.fc34.x86_64/build/Is the correct ke[FEHLGESCHLAGEN]ge installed?

    [root@fedora seby]# dkms build -m xpadneo/0.9.1
    Error! Your kernel headers for kernel 5.14.9-200.fc34.x86_64 cannot be found at /lib/modules/5.14.9-200.fc34.x86_64/build or /lib/modules/5.14.9-200.fc34.x86_64/source.
    You can use the –kernelsourcedir option to tell DKMS where it’s located.

    The only folder in /usr/src/kernels/ is
    [root@fedora kernels]# ls
    5.14.9-200.fc34.x86_64+debug

    I have installed the steam repository as mentioned in this article. I can already connect my series Xbox Controllers, but they have the wrong key mapping.
    It would be super nice if you could help me out 🙂

  4. I’m seeing the following error:

    Package akmod-xpadneo-0.9.1-2.fc34.x86_64.rpm is not signed

    I was able to workaround the issue with “sudo dnf install –nogpgcheck akmod-xpadneo”, but just letting you know.

Leave a Reply to padajuanCancel reply