recalbox / recalbox-configgen

Emulators configuration tools for recalboxOS
MIT License
7 stars 18 forks source link

controllersConfig.py: invalid gamecontrollerdb.txt when comma in device name #119

Open dahauns opened 7 years ago

dahauns commented 7 years ago

See
https://github.com/recalbox/recalbox-configgen/blob/master/configgen/controllersConfig.py#L65

In 4.1 unstable, PPSSPP doesn't recognize my Buffalo Classic SNES gamepad at all.
The interesting thing is that the gamepad identifies as USB,2-axis 8-button gamepad in its deviceName. I strongly guess the comma in the name breaks the SDL gamecontrollerDB.txt file, since it expects comma as the delimiter and no string quotes. I have no toolchain setup at the moment so I can't test it myself, but I hope this helps.

The gamecontrollerdb.txt entry looks like this:

03000000830500006020000010010000,USB,2-axis 8-button gamepad  ,platform:Linux,b:b0,a:b1,x:b3,leftshoulder:b4,dpup:a1,dpdown:a1,start:b7,dpright:a0,rightshoulder:b5,guide:b6,y:b2,back:b6,dpleft:a0,
substring commented 7 years ago

Hi ! You don't need any toolchain for configgen. Just edit the python code and it most of times recompiles itself on first call.

Anyway, what you can try for now (i hope it works, no time yet to test) :

And yup, that's a bug, thank you for reporting :)