Solved: Setting up Gamecon driver with psx controller
-
@Katemonster Oh I thought pads 1 and 2 changed to pads 5 and 6 from Model b rev2 and beyond.
from the link (https://github.com/retropie/retropie-setup/wiki/GPIO-Modules#gamecon_gpio_rpi) above I saw
"NES/SNES Controller Data Pin Location Legend
Rev01 board (Raspberry Pi B)
Gamepad1 = GPIO0 = Physical Pin03
Gamepad2 = GPIO1 = Physical Pin05
Gamepad3 = GPIO4 = Physical Pin07
Gamepad4 = GPIO7 = Physical Pin26Rev02 board (Raspberry Pi A, B+, 2, 3)
Gamepad3 = GPIO4 = Physical Pin07
Gamepad4 = GPIO7 = Physical Pin26
Gamepad5 = GPIO2 = Physical Pin03
Gamepad6 = GPIO3 = Physical Pin05
"I can try to swap that out for sure. I have a pull up resistor I can try it with.
Do you think it would be useful if in the RetroPie-Setup file I configured it for 2 NES/SNES controller then changes the options for what I need?
Is there any other configuration I need to do before testing it out in EmulationStation? Is
jstest /dev/input/js0
Something I can try to see if I'm even getting any inputs if it doesn't work on the front end? -
Yes, jstest is a quick and easy way to sanity-check your install.
The wiring blurb you posted is a little confusing. I have a lot of problems with that guide. What it's really saying is this:
"NES/SNES Controller Data Pin Location Legend
Rev01 board (Raspberry Pi B)
Gamepad1 = GPIO0 = Physical Pin03
Gamepad2 = GPIO1 = Physical Pin05
Gamepad3 = GPIO4 = Physical Pin07
Gamepad4 = GPIO7 = Physical Pin26Rev02 board (Raspberry Pi A, B+, 2, 3)
Gamepad1 = GPIO0 = Physical Pin03
Gamepad2 = GPIO1 = Physical Pin05
Gamepad3 = GPIO4 = Physical Pin07
Gamepad4 = GPIO7 = Physical Pin26
Gamepad5 = GPIO2 = Physical Pin03
Gamepad6 = GPIO3 = Physical Pin05So for the Pi models with more GPIO's, it simply adds support for Gamepad5 and Gamepad6, on GPIO2 and GPIO3, respectively.
-
Well I did a fresh install and even tried
options gamecon_gpio_rpi map=7,7,7,7,7,7
in/etc/modprobe.d/gamecon.conf
. In emulation station it shows that there are 6 devices but no matter what pin I try even with a 4.5K resister jumping it to 3.3V nothing works. I'm left very confused.I do see that during boot up I can turn the analog led on the controller on but once the RetroPie boot screen comes up the led goes off. I have a PSX to USB adapter and that works great with the pi and this controller.
-
@geneworld Filling the map with all 7's isn't the right way to go. It'll just cause more confusion down the line.
Funny business with the LED's after RetroPie starts tells me you probably have one of the wires flipped around. Unfortunately with that block in the way I can't get a good picture of which pins are going to which GPIO's. Please take that out, setup the driver with map=7,0,0,0,0,0 , and plug the data pin, with pull up resistor, to GPIO0, and post a picture. Then we'll go from there.
-
@Katemonster This is what I have currently. with options
gamecon_gpio_rpi map=0,0,7,0,0,0
in/etc/modprobe.d/gamecon.conf
But I can take pictures hopefully later when I get home or tomorrow.
-
@Katemonster Took some pictures
-
@geneworld OK, looks like your wiring is backwards. Use this diagram: psx pinout
-
@Katemonster well that could be an issue right?
I've been using this one:
I'll switch to this one:
and see what I get! Great find this is promising I can't wait to swap it out after work!
-
@geneworld oh wow, yeah that diagram is completely backwards.
This explains why your controller was powered during boot, but not once retropie starts- the 3.3V pin is dead center, so that was correct, but ground was technically plugged in to the PSX_SEL line, which might tend towards ground with the module not loaded.
-
@Katemonster I'm excited to test this out, it will really advance my project!
So to stick with updated I will change my wire diagram to reflect this:
-
@Katemonster It works! I swapped the wires and it works flawlessly now! Thanks for your ongoing help :) I'll edit the top post to reflect the changes.
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.