2 player retro pi setup
-
Hi
A few days ago i just both rpi 3 the one with 1.2 ghz. I installed retropi. I have connected a usb game-pad and a keyboard to the rpi hoping i can play fba aerofighters in 2 players, one player with keyboard and the other with game-pad. However the second player is not configured and both game-pad and keyboard are controlling player 1.
Is there a chance i can configure player 1 with keyboard and player 2 with game-pad? or vice-versa?.
I am using usb not gpio pins. -
In the retroarch.cfg for that system add:
Input_player2_device = 3
I think thats correct. I am on the road so i cant get to my computer to verify. I think the retroarch config you need is:
/opt/retropie/configs/fba/retroarch.cfg
Make sure you put it above the #include line -
is there way to apply this for all the emulators? like nes snes etc?
-
@badboy1985ro Not too long ago, I added the ability for either player to use keyboard controls if necessary in every RetroArch core by altering
/opt/retropie/configs/all/retroarch.cfg
. You can use my alterations as a starting point for your own personal preference.By default, the entry you want to alter looks like this:
# Keyboard input, Joypad and Joyaxis will all obey the "nul" bind, which disables the bind completely, # rather than relying on a default. input_player1_a = "x" input_player1_b = "z" input_player1_y = "a" input_player1_x = "s" input_player1_start = "enter" input_player1_select = "rshift" input_player1_l = "q" input_player1_r = "w" input_player1_left = "left" input_player1_right = "right" input_player1_up = "up" input_player1_down = "down" # input_player1_l2 = # input_player1_r2 = # input_player1_l3 = # input_player1_r3 = # Two analog sticks (DualShock-esque). # Bound as usual, however, if a real analog axis is bound, # it can be read as a true analog. # Positive X axis is right, Positive Y axis is down. # input_player1_l_x_plus = # input_player1_l_x_minus = # input_player1_l_y_plus = # input_player1_l_y_minus = # input_player1_r_x_plus = # input_player1_r_x_minus = # input_player1_r_y_plus = # input_player1_r_y_minus =
You'll want to alter it to look something like this:
# Keyboard input, Joypad and Joyaxis will all obey the "nul" bind, which disables the bind completely, # rather than relying on a default. input_player1_a = "a" input_player1_b = "b" input_player1_y = "y" input_player1_x = "x" input_player1_start = "t" input_player1_select = "e" input_player1_l = "l" input_player1_r = "r" input_player1_left = "left" input_player1_right = "right" input_player1_up = "up" input_player1_down = "down" input_player1_l2 = "d" input_player1_r2 = "f" input_player1_l3 = "c" input_player1_r3 = "v" input_player2_a = "k" input_player2_b = "m" input_player2_y = "o" input_player2_x = "n" input_player2_start = "num9" input_player2_select = "num0" input_player2_l = "p" input_player2_r = "q" input_player2_left = "g" input_player2_right = "h" input_player2_up = "i" input_player2_down = "j" input_player2_l2 = "s" input_player2_r2 = "u" input_player2_l3 = "w" input_player2_r3 = "z" # Two analog sticks (DualShock-esque). # Bound as usual, however, if a real analog axis is bound, # it can be read as a true analog. # Positive X axis is right, Positive Y axis is down. # input_player1_l_x_plus = "right" # input_player1_l_x_minus = "left" # input_player1_l_y_plus = "down" # input_player1_l_y_minus = "up" # input_player1_r_x_plus = "num2" # input_player1_r_x_minus = "num1" # input_player1_r_y_plus = "num4" # input_player1_r_y_minus = "num3" # input_player2_l_x_plus = "h" # input_player2_l_x_minus = "g" # input_player2_l_y_plus = "j" # input_player2_l_y_minus = "i" # input_player2_r_x_plus = "num6" # input_player2_r_x_minus = "num5" # input_player2_r_y_plus = "num8" # input_player2_r_y_minus = "num7"
You'll notice that I also added the ability to control the emulated analog sticks from the keyboard as well, but I decided to comment them out for my purposes. If you want those controls to be functional, you'll have to remove the # at the beginning of the lines.
-
@badboy1985ro said in 2 player retro pi setup:
is there way to apply this for all the emulators? like nes snes etc?
/opt/retropie/configs/SYSTEM_NAME/retroarch.cfg
is the system specific retroarch config file./opt/retropie/configs/all/retroarch.cfg
is the global retroarch config file.More info here:
https://github.com/RetroPie/RetroPie-Setup/wiki/RetroArch-Configuration#hardcoded-configurations
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.