Keyboard and Button Coniguration
-
I have edited my /opt/retropie/configs/all/retroarch.cfg as follows:
input_player1_a = "enter" input_player1_b = "control" input_player1_y = "shift" input_player1_x = "c" input_player1_start = "num1" input_player1_select = "x" input_player1_l = "alt" input_player1_r = "space" input_player1_left = "left" input_player1_right = "right" input_player1_up = "up" input_player1_down = "down"
However, it seems like lr-mame2003 and lr-fbalpha are just ignoring these values for the button assignments. input_player1_left, input_player1_right, input_player1_up, input_player1_down all work. As does input_player1_select and input_player1_start. however none of the buttons like a,b, x,y appear to be working.
I know my buttons are working because if I quit emulationstation to a bash prompt and hit the input_player1_a button I get a new line; likewise I have edited /opt/retropie/configs/all/emulationstation/es_input.cfg as follows and all of the buttons are working just fine in emulationstation. It seems like the problem is with retroarch.
<inputConfig type="keyboard" deviceName="Keyboard"> <input name="start" type="key" id="49" value="1"/> <input name="up" type="key" id="1073741906" value="1"/> <input name="a" type="key" id="13" value="1"/> <input name="b" type="key" id="1073742048" value="1"/> <input name="down" type="key" id="1073741905" value="1"/> <input name="right" type="key" id="1073741903" value="1"/> <input name="x" type="key" id="99" value="1"/> <input name="select" type="key" id="120" value="1"/> <input name="y" type="key" id="32" value="1"/> <input name="left" type="key" id="1073741904" value="1"/> </inputConfig>
What am I missing here?
-
@golaat do you have additional retroarch.cfg files in the config folders for those emulators? If so, they might be overriding the one on the /all directory.
-
I looked at the retroarch.cfg files in the folllowing folders:
/opt/retropie/configs/mame-libretro
/opt/retropie/configs/arcade
/opt/retropie/configs/fbathey all had just a barebones include of the config file from
/opt/retropie/configs/all/retroarch.cfg
Are there any other locations I should check?
-
@golaat there is also the chance that a config is inside the ROMs folder, but this would be a per-rom config (one for each game, or at minimum, the game you are testing) and named for the ROM itself: romname.zip.cfg
-
@caver01 Well, unless each ROM came bundled with a rogue config, this can't be the case as I have tested multiple roms. I am super frustrated at this point. I have attached my retroarch.cfg file in the hopes that someone will spot an issue or perhaps be able to point me to look at something.
My buttons are hooked into an IPAC and I also have a keyboard attached to another USB port. Retroarch does not recognize the assignments on either the keyboard or the IPAC.
-
@golaat something about that link is being blocked for me. I would take a look. Perhaps you could post it on pastebin?
-
By the way, what happens if you bring up the lr-mame2003 GUI and try to map a control input? What does MAME see?
-
@caver01 Try the link again; I had inadvertently pasted it as https instead of http.
Here is a pastebin version just in case.
Ok.. so when I press the TAB key to bring up the MAME 2003 menu, button one says LCONTROL or Retropad 1
When I try to remap and press my button one, it successfully remaps to 'RETURN' (which is my enter key) and button one works without issue. Its like it is not seeing my retroarch config.
-
@golaat Good. That explains a lot. I think we can figure this out.
First, your retroarch config usescontrol
but I think the acceptable value for the control key isctrl
. Maybe both spellings work, but I would fix that one first. Then, let’s look at MAME:Normally, button 1 in MAME is LCONTROL, so it appears to have a combination of the default RAW input, and retroarch’s virtual gamepad input on the buttons. MAME may be expecting that you have all of your keys setup with the expected defaults, and because of a strange RAW+virtual input combo in lr-mame2003, button 1 was broken (until you remapped it) because of the mismatch. I bet button two was LALT. Anyway, you might just go into the controls screen in MAME for ALL GAMES and simply re-map the buttons. This will sync up the defaults for your configuration for all games.
l-fba might be different, but it could be that the misspelled
control
instead ofctrl
in your retroarch.cfg file is to blame for that. -
@caver01 Here is a screenshot of the retroarch input configuration menu while in the fba core.
-
@golaat I might not be much help there as I configure everything through the cfg files (old school) not the retroarch interface.
-
@golaat interesting that it has SHOT, but your enter key is set to an input that is N/A. What game is this for?
-
@caver01 that is 1941.
At this point in time, I think retroarch is a hunk of junk. Is there a way i can disable retroarch and its input remapping and just specify the key configs manually for each emulator?
-
@golaat Yes and no. Since some of the emulators run inside retroarch, you are somewhat tied to that environment, but with lr-mame2003 you can actually work around it. You COULD go in and set all of your player 1 inputs to “nul” (don’t use curly quotes like I did here). This is unique for this version of mame because it still “listens” to RAW keyboard inputs. You then have to go into MAME and map keys using the ALL games menu as opposed to just THIS GAME and you will have a nice clean input setup which is what I already proposed above.
However, this doesn’t work for other libretro cores. Still, I
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.