mupen64plus / mupen64plus-user-issues

Issue reports from users go here
http://www.mupen64plus.org/
17 stars 3 forks source link

XBoX 360 USB Controller - messed up Analog Sticks #675

Open cookiengineer opened 8 years ago

cookiengineer commented 8 years ago

The XboX 360 USB Controller is messed up. First, I thought it was the auto configuration - so I used m64py to configure everything correctly.

The problem is that the analog stick always fires twice, but first in the opposite direction.

Say if you want to play Super Smash Bros. and you use the Analog stick up to jump, it will eventually lead that you will always double jump because if you press Analog stick down, the first time the input is recognized it will always be the same as the last pressed analog stick input.

So I guess there's something wrong in the state driven handles, as the last state value of any analog stick is fired before it is updated to the correct value.

I confirmed that by experimentally binding N64 buttons (A,B) to analog stick values.

I have no clue if this error is related to SDL or mupen64plus. Anybody has a clue on how to fix this?

cookiengineer commented 8 years ago

I got it now working. The issue is that the analog stick functions as the same input in the driver, so double-binding stuff on the outer analog stick and the inner analog stick (and/or the click actions of them) will result in misbehaviour and state overrides.

Is there a way to have an Input Auto config entry based on USB identifiers? Autoconfig will always prefer the other previous setup, which is completely broken with my official MS Xbox360 controller.

As the analog sticks function as the same axis on my controller, I have no space for DPad. I added the USB identifiers, but I have no clue if there's an option allowing to use this config over others if USB identifier matches!?!?

# 045e:028e Microsoft Corp. Xbox360 Controller
[Linux: Microsoft Corp. Xbox360 Controller]
plugged = True
plugin = 2
mouse = False
AnalogDeadzone = 4096,4096
AnalogPeak = 32768,32768
# DPad R = hat(0 Right)
# DPad L = hat(0 Left)
# DPad D = hat(0 Down)
# DPad U = hat(0 Up)
Start = button(7)
Z Trig = button(2)
B Button = button(1)
A Button = button(0)
C Button R = hat(0 Right)
C Button L = hat(0 Left)
C Button D = hat(0 Down)
C Button U = hat(0 Up)
R Trig = button(5)
L Trig = button(4)
Mempak switch = 
Rumblepak switch = 
X Axis = axis(0-,0+)
Y Axis = axis(1-,1+)