Recalbox Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • recalbox.com
    • Gitlab repository
    • Documentation
    • Discord
    1. Home
    2. Cacodaemon
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 1
    • Best 0
    • Controversial 0
    • Groups 0

    Cacodaemon

    @Cacodaemon

    0
    Reputation
    1
    Profile views
    1
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    Cacodaemon Unfollow Follow

    Latest posts made by Cacodaemon

    • Question: Setting controller order/priority via commandline?

      Hello,

      I am the proud owner of a GPi CASE 2, and I have got one problem when connection the case to its docking station.
      The "build in" controller remains on it's slot/position and the controller connected via USB becomes the secondary controller.

      When starting a game it may be uncontrollable until the priority is changed via the UI's controller setting. Which can be confusing, hence the internal controller is named "Xbox 360 Controller" as well as the one connected via USB 😕 .
      I would like to change the controller slots whether it's connected to the docking station or used in handheld mode.

      Is there any kind of CLI for configuring the controller settings, otherwise is there a another approach than messing up the config files?

      I figured out that the controller config get stored in /recalbox/share/system/recalbox.conf and the handheld's controller id is 030000005e0400008e02000014010000, I assume that each GPi CASE 2 controller has the same id.

      grep "Xbox 360 Controller" /recalbox/share/system/recalbox.conf
      emulationstation.pad0=030000005e0400008e02000020010000:Xbox 360 Controller
      emulationstation.pad1=030000005e0400008e02000014010000:Xbox 360 Controller
      

      So my current approach would be to execute a script like this, below (not tested) when connected to the docking station, to swap the controller order:

      /etc/init.d/S31emulationstation stop
      sed -i 's/pad0/pad99/g' /recalbox/share/system/recalbox.conf.bak
      sed -i 's/pad1/pad0/g' /recalbox/share/system/recalbox.conf.bak
      sed -i 's/pad99/pad1/g' /recalbox/share/system/recalbox.conf.bak
      /etc/init.d/S31emulationstation start
      

      Any other ideas how to manage the controller and swap their order?

      Thanks!

      posted in GamePad/GPIO/USB encoder
      Cacodaemon
      Cacodaemon