When you start up EmulationStation for the first time it prompts you to setup your input devices such as gamepads and keyboards. Currently I have two types of SNES controllers (I only set up one for right now.), two different PlayStation 2 controller adapters, and a keyboard. Even if you don’t plan on using it, it is a good idea to set up a keyboard just in case a controller isn’t working for some reason.
The controllers / adapters I have are:
- SNES Retro USB Super Nintendo Controller
- Buffalo Classic USB Gamepad for PC
- Playstation to USB Adapter from Radio Shack (No longer avaliable.)
- PS2 to PS3 Playstation Controller Adapter USB Converter
I will label them as:
- SNES_1
- SNES_2
- PS2_1
- PS2_2
respectively.
To start, I plugged in all the controllers and keyboard and then loaded up EmulationStation by typing the following two lines in the terminal (Note: if you are not running a vncserver then ignore the first line.):
pi@raspberrypi ~ $ vncserver -kill :0 pi@raspberrypi ~ $ emulationstation |
With EmulationStation 2.0+ it tells you how many inputs are detected. Follow the on screen setup for each controller until they are all set up.
I created a table so that I can keep track of what I assigned to each button:
Command | Player 1 | Player 2 | Player 3 | Player 4 |
SNES_1 | PS2_1 | Keyboard | PS2_2 | |
Up | Up | Up | Up | Up |
Down | Down | Down | Down | Down |
Left | Left | Left | Left | Left |
Right | Right | Right | Right | Right |
A | A | Circle | Enter | Circle |
B | B | X | Backspace | X |
Start | Start | Start | Space | Start |
Select | Select | Select | Tab | Select |
Page Up | Left | Left | Page Up | Left |
Page Down | Right | Right | Page Down | Right |
The first time I ran this it didn’t find all the controllers. After I rebooted and mapped the controllers to a file for a later use I noticed that they were found when I tried again. This only sets up the controllers for EmulationStation. In a future post I will go over how to set the controllers in RetroArch which is the main configuration file for the emulators.
If you ever want to re-do the initial controller set up run this command:
pi@raspberrypi ~ $ rm /home/pi/.emulationstation/es_input.cfg |
That will remove the EmulationStation input configuration file. You can also do it from within EmulationStation but I like to remove the file to start fresh.
Check out these other helpful links:
Mapping Controllers (1 of 3): For EmulationStation
Mapping Controllers (2 of 3): Mapping Controllers to a File
Mapping Controllers (3 of 3): Setting up Controllers in RetroArch
Auto detecting controllers in EmulationStation 2.0+
RetroPie: Adding game roms, BIOS files, and enabling save states
Setting up GameBoy Advance for RetroPie
Adding a XBMC tab in EmulationStation
Adding an Apps tab in EmulationStation
Setting up Playstation for RetroPie
Creating power logs for EmulationStation (1 of 2)
Creating power logs for EmulationStation (2 of 2)
Pingback: Mapping Controllers (2 of 3): Mapping Controllers to a File | ➟ Weekend Engineer
Pingback: Mapping Controllers (3 of 3): Setting up Controllers in RetroArch | ➟ Weekend Engineer
Pingback: Auto detecting controllers in EmulationStation 2.0+ | ➟ Weekend Engineer
Pingback: Setting up GameBoy Advance for RetroPie | ➟ Weekend Engineer
Pingback: RetroPie: Adding game roms, BIOS files, and enabling save states | ➟ Weekend Engineer
Pingback: Adding an Apps tab in EmulationStation | ➟ Weekend Engineer
Pingback: Setting up PlayStation for RetroPie | ➟ Weekend Engineer
Pingback: Creating power logs for EmulationStation (1 of 2) | ➟ Weekend Engineer
Pingback: Creating power logs for EmulationStation (2 of 2) | ➟ Weekend Engineer
Hi im having a hard time setting up a save state in my games
Hi Quang! Check out my other two posts here https://weekendengineer.wordpress.com/2014/08/28/mapping-controllers-3-of-3-setting-up-controllers-in-retroarch/ and here https://weekendengineer.wordpress.com/2014/09/02/auto-detecting-controllers-in-emulationstation-2-0/ and let me know if that helps!
Hi there! I am having trouble getting my PS2 controllers to be recognized. I have the exact same adapters as you, but no keypresses are being detected. Both controllers _are_ being detected in emulationstation, but when I hold a button to configure, nothing happens. Did you have to install anything separately?
What kind of pi and power supply? I’ve seen it when an under powered pi won’t get controllers to work…let’s start there and move on if needed!
Thanks for writing back! I was actually able to get this working, but looks like I was actually doing everything correctly. I had purchased two of those adapters, and one of them came through dead on arrival. So when I plugged in both of them, it was detecting one controller, which is when I realized that the original single one I was trying was simply busted.
Thanks – love the blog! Just getting into all this Raspberry Pi stuff and it’s oddly addicting and very satisfying putting your own system together.
Glad to hear! Thanks! I really have to find time to update amd make new posts that I’m sure you’d enjoy. Yeah it’s so much fun setting it all up on your own!
I’m trying to set up a key to toggle the fast forward option:
input_toggle_fast_forward_btn = “#”
Whatever key I put in there (the number), it is activated using the hotkey + that button… (ie. select+RB button)
Is there a way to assign the toggle button to a single button and not a hotkey button (ie. button combo)?
I’m currently rebuilding my image so i can yake a look into this and get back to you!
Thanks! I can wait.
So i had time to check this out. The only way i was able to get this to work with one button was to assign it the same button as the input_enable_hotkey_btn
Tbe button still worked as a hot key enabler though so you could use it with other key combos!
OK, so to clarify for myself. As far as I can tell, it only really works as part of a hotkey combination, and you’re saying one option would be to assign it to the hotkey button itself so that it would essentially also be a single button press.
Thanks for the help!
Yeah that’s all i was able to figure out…so they’d both have the same button assignment!
I wired a joystick to GPIO ports and all was working fine till I inadvertently destroyed GPIO22 (RIGHT). So I just rewired Button4’s (X) port (GPIO14) to the joystick’s right but EmulationStation won’t let me map that button as RIGHT. It does recognize the button as X but not as RIGHT. Why not?