Egghead.page Logo

How to Configure Game Controllers in RetroArch on Linux

This guide provides a step-by-step process for setting up game controllers within RetroArch on Linux systems. You will learn how to connect your hardware, utilize automatic configuration profiles, manually map buttons for specific cores, and save your settings to ensure a seamless gaming experience across different emulators.

Connecting Your Hardware

Before launching RetroArch, ensure your controller is properly connected to your Linux machine. For wired controllers, simply plug the USB cable into an available port. For Bluetooth controllers, open your system settings and pair the device before starting the emulator. Most modern distributions, such as Ubuntu, Fedora, and Arch, recognize common controllers like Xbox and PlayStation pads automatically through the kernel. You can verify detection by running lsusb or dmesg in the terminal to see if the device is listed.

Automatic Configuration

RetroArch features a robust auto-config feature that detects thousands of controllers out of the box. When you launch RetroArch with your controller connected, navigate to the Main Menu and select Settings. Go to the Input section and ensure that “Autoconfig Enable” is turned on. If your controller is supported, RetroArch will display a notification indicating that a profile has been loaded. You can test the inputs immediately by navigating the menu using the gamepad instead of a keyboard.

Manual Input Mapping

If automatic detection fails or you are using a generic controller, you will need to map the inputs manually. Navigate to Settings > Input > Port 1 Controls. Here you will see a list of actions such as “Up,” “Down,” “A Button,” and “Start.” Select each action and press the corresponding button on your physical controller. It is crucial to map the “Menu Toggle” key carefully, as this allows you to access the RetroArch overlay during gameplay. Once all buttons are assigned, test them in the “Input User 1 Binds” section to ensure there are no conflicts or double inputs.

Saving Controller Profiles

To avoid remapping your controller every time you launch the application, you must save the configuration. Once your inputs are configured correctly, go to the Main Menu and select Configuration File. Choose “Save Current Configuration.” This action writes your settings to the retroarch.cfg file. For specific cores, you can save a core-specific configuration by loading the core you intend to use, setting up the controls, and selecting “Save Core Overrides.” This ensures that certain games or systems use the appropriate control scheme without affecting global settings.

Troubleshooting Linux Permissions

On some Linux distributions, permission issues may prevent RetroArch from accessing controller hardware. If your controller is not detected despite being connected, you may need to adjust udev rules. Create a new rule file in /etc/udev/rules.d/ to grant input access to your user group. Additionally, ensure that your user is added to the “input” group by running the command sudo usermod -aG input $USER in the terminal. After making these changes, log out and log back in for the permissions to take effect.