PSX GPIO controller giving random outputs
-
Hi, i'm having the following problem: I wired 2 PSX controllers to the GPIO just like is said in https://github.com/recalbox/recalbox-os/wiki/Gamecon-controllers-(EN), everything is correctly wired, the controller 'works' but sends random button pushes, then searching for some fix I found this:
https://retropie.org.uk/forum/topic/6980/random-input-psx-controller-gpio
There is a simple way to solve the problem, but I'm using recalbox 4.1, and aparently this version doesn't have the .c module, found a '.ko' gamecon module in 'libs', but is compiled, so I need to figure out how to make the changes described in that link and recompile, 'amecon_gpio_rpi.c' for editing, any help?
-
@djoni_w you will be able to recompile the module once 4.1 is made public. You'll need to cross compile it from your computer. Or maybe wait for a new release that will have an increased delay. I can add it if you're not in a big hurry
-
@Substring I was already lookin about how to compile .c to .ko (I really don't understand so much about linux compiling but it can't be impossible too), there is some tutorial about this? Then I can try here and post the result as fast as i'm done.. Thanks for the fast response and sorry for the broken english.
-
@djoni_w what you can do (as it should work) :
- get Linux (but it should work in WSL if you have an up-to-date windows with the 16.04 Ubuntu)
- follow https://github.com/recalbox/recalbox-os/wiki/Compilation-%26-Modifications-(EN) and stop once you've typed
make recalbox-${arch}_defconfig
- now type
make gamecon-gpio-rpi-patch
- now
cd output/build/gamecon-gpio-rpi
(there might be some more following the folder name, check by yourself) - edit the source code to change the delay to 5
- climb back in the folder where you issued the make commands (
cd -
should do it if you haven't changed directory since the lastcd
) - now
make gamecon-gpio-rpi
- watch the output, the .ko file should appear. If you can't find it, it should be at least in the folder where you edited the source code
If you're having trouble with all that, i'll compile one for you.
For the explanation : a ko is a kernel object. In this case it's a driver that runs in the kernel space (as opposed to user space)