Kernel 6.17.4-200 Xbox 360 Wireless Controller d-pad problem

With kernel 6.17.4-200 the d-pad on Xbox 360 Wireless Controller is incorrectly mapped:

  • UP: button 14, physical LEFT button
  • DOWN: button 15, physical RIGHT button
  • LEFT: button 12, physical UP button
  • RIGHT: button 13, Physical DOWN button

Using kernel 6.16.12-200, the d-pad works as expected.

This behavior is very similar to this Manjaro post from August but in regard to different kernel versions: X360 controller dpad functions incorrectly on 6.15/6.16 kernels - Third-Party Software - Manjaro Linux Forum.

Any advice/guidance into correcting the behavior AND using the current kernel is much appreciated.

Attempted another machine and experienced the same behavior with kernel 6.17.4-200. Booting with kernel 6.16.10-200, the d-pad works as expected.

File a bug at bugzilla.redhat.com
and provide as much info about both systems.
Make sure to answer any questions asked of you there.

just fyi. I dont have this problem. I used to have bluetooth issues with mine until I updated firmware on a windows machine but never this dpad bug. Maybe we have different hardware revisions. Mine is model: ‘UK 1914’.
I’m using a bluetooth 5 dongle, not the microsoft wireless dongle.

I stumbled across some more info here: joystick: Improve Xbox controller mapping with xpad quirks by endrift · Pull Request #13305 · libsdl-org/SDL · GitHub. A GitHub user raised the exact issue I’m experiencing (Wireless Xbox 360 controller d-pad broken on Linux 6.17+ · Issue #14324 · libsdl-org/SDL · GitHub) and, if I’m comprehending correctly, has suggested a fix (Remove special-case Xbox 360 wireless controller mappings by turmoni · Pull Request #14339 · libsdl-org/SDL · GitHub).

I have two model 1403 controllers that I purchased over 13 years ago. They’re tanks. Both connect to the same 1086 wireless dongle that experienced the infamous blown fuse very soon after purchase. I ended up shorting it with a soldered bit of paperclip and it’s been perfect.

1 Like

You can define a custom mapping for SDL until this is resolved in SDL with an updated SDL3 release maybe next month.

Thanks for the suggestion. I haven’t had the opportunity to completely ingest the GitHub conversation and I’m not entirely certain I would understand it anyway. I’ll search for methods to build that custom mapping but would definitely appreciate any direction to reliable resource to assist me.

see PowerA Nintendo Switch Wired controller buttons mapped incorrectly - #5 by anotheruser how to set custom mappings. the testcontroller program is very useful to define mappings.
In this case however I suspect that it should be enough to copy the removed mappings from that PR on github and manually remap the d-pad buttons.

the mappings are:

030000005e0400001907000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,
030000005e0400009102000007010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,
030000005e040000a102000000010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,
030000005e040000a102000007010000,X360 Wireless Controller,a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,
030000005e040000a102000014010000,Xbox 360 Wireless Receiver (XBOX),a:b0,b:b1,back:b6,dpdown:b14,dpleft:b11,dpright:b12,dpup:b13,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,

copy that in to a custom controllerdb.txt edit the mappings for the d-pad to reflect the changes to xpad driver.

I guess you could also use the SDL2 Gamepad Tool by General Arcade to create the mapping or see the gamepad GUID for your controller(s).

Very much appreciated. I’ll have a look at it when I have the opportunity.