RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    Joystick/controller input in text UI menus?

    Scheduled Pinned Locked Moved Help and Support
    retropie 4.4controllerretropie-setup
    4 Posts 3 Posters 666 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P
      pkzipfish
      last edited by

      The Retropie setup script accepts joystick input. I'm working on a script that can be run from within emulationstation that I'd like users without a keyboard to be able to run, or at least cleanly exit from.

      The script is working fine with keyboard input, but doesn't accept any joystick input. It's a fairly simple script, built with the "dialog" utility. Does anyone know how to enable joystick input in dialog, or what text UI tool that does support controller input is used to create RetroPie-Setup? I tried reading through the script files, but couldn't make heads or tails of them.

      Pi Model or other hardware: 3B+
      Power Supply used: Canakit
      RetroPie Version Used: 4.4
      Built From: Pre made SD Image on RetroPie website
      USB Devices connected: Logitech wireless keyboard, Buffalo Classic USB controller

      1 Reply Last reply Reply Quote 0
      • mituM
        mitu Global Moderator
        last edited by

        RetroPie uses joy2key to simulate a keyboard using the gamepad. Look in the RetroPie scripts which use dialog to see how it's used - i.e. the Wifi setup dialog, the scraper configuration screen, etc.

        1 Reply Last reply Reply Quote 1
        • jandalf81J
          jandalf81
          last edited by jandalf81

          @pkzipfish

          Take a look at my post here: https://retropie.org.uk/forum/topic/18978/script-setup-for-an-automatic-savestate-selector/8#
          I had the exact same problem and could solve it.

          In short, RetroPie uses Joy2Key to map jystick input to keyboard input to let users navigate menus with their joysticks. There are scripts which can be used to 'borrow' that function. Feel free to look at my script to see how I did that.

          Here's my script: https://github.com/Jandalf81/savestate_selector/blob/master/savestate_selector.sh

          1 Reply Last reply Reply Quote 2
          • P
            pkzipfish
            last edited by

            Thanks. Worked perfectly.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post

            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.