AntiMicroX / antimicrox

Graphical program used to map keyboard buttons and mouse controls to a gamepad. Useful for playing games with no gamepad support.
GNU General Public License v3.0
2.26k stars 138 forks source link

Not enough button mappings on PowerA Nintendo Switch Enhanced Wired Controller #776

Closed yamanq closed 1 year ago

yamanq commented 1 year ago

Is there an existing issue for this?

Current Behavior

When using the controller (SKU 1522782-01), one of the 4 center buttons does not work. However, it shows up in the logs and I can set it in the controller mapping section. The issue is that the Controller Mapping menu only allows for 3 buttons in the center (Back, Start, Guide) when this controller has 4 functional buttons (Button 9, Button 10, Button 13, Button 14).

Expected Behavior

All 4 center buttons should be mappable at the same time.

Steps To Reproduce

  1. Connect a controller with SKU 1522782-01
  2. Try to map the "Capture Button"
  3. Notice that it does not light up any of the default buttons
  4. Try to remap it in the Controller Mapping menu

Environment

Program Version 3.3.3
Program Compiled on Apr 26 2023 at 02:04:03
Built Against SDL 2.26.4
Running With SDL 2.26.4
Using Qt 5.15.8
Using Event Handler: XTest
Compositor type: x11
Host OS: arch Version: unknown Architecture: x86_64

Anything else?

Front face of controller with unmapped button that is detected:

image

Controller Mapping menu showing only 3 buttons that can be mapped: image

It seems that this might be the max of the SDL GameController API. Could JoyButtonEvent be used to map additional buttons that a controller might have? In the logs, the button that is not mapped in Controller Mapping shows as a detected SDL_JOYBUTTONDOWN event: Unmapped Button

[12:52:03.139] 🐞DEBUG  Processing event: SDL_JOYBUTTONDOWN From joystick with instance id: 0 Got button with id: 13 is one of the GameControllers: true is one of the joysticks:false (file /src/inputdaemon.cpp:738)
[12:52:03.220] 🐞DEBUG  Processing event: SDL_JOYBUTTONUP From joystick with instance id: 0 Got button with id: 13 is one of the GameControllers: true is one of the joysticks:false (file /src/inputdaemon.cpp:738)

Other buttons:

[12:51:33.776] 🐞DEBUG  Processing event: SDL_CONTROLLERBUTTONDOWN From joystick with instance id: 0 Got button with id: 5 is one of the GameControllers: true is one of the joysticks:false (file /src/inputdaemon.cpp:738)
[12:51:33.777] 🐞DEBUG  Processing event: SDL_JOYBUTTONDOWN From joystick with instance id: 0 Got button with id: 12 is one of the GameControllers: true is one of the joysticks:false (file /src/inputdaemon.cpp:738)
[12:51:33.828] 🐞DEBUG  Processing event: SDL_JOYBUTTONUP From joystick with instance id: 0 Got button with id: 12 is one of the GameControllers: true is one of the joysticks:false (file /src/inputdaemon.cpp:738)
[12:51:34.029] 🐞DEBUG  Processing event: SDL_CONTROLLERBUTTONUP From joystick with instance id: 0 Got button with id: 5 is one of the GameControllers: true is one of the joysticks:false (file /src/inputdaemon.cpp:738)

Upvote & Fund

Fund with Polar

pktiuk commented 1 year ago

Duplicate of: https://github.com/AntiMicroX/antimicrox/issues/694