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

    GameStick controller connects but input not recognized

    Scheduled Pinned Locked Moved Help and Support
    bluetoothcontrollergamestick
    6 Posts 3 Posters 1.7k 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.
    • R
      Ray Ingles
      last edited by

      Have a couple GameStick controllers I'd love to use with our RetroPie, but for some reason they won't play nice together.

      I've paired one controller with the RetroPie (Raspberry Pi 3 Model B), and if I drop to the console I can see axes move and buttons trigger using jstest. But when the controller is configured, no button presses are recognized except the Home button (the big round center button) and the "Back" button. And these are detected as "Keyboard" for some reason.

      Interestingly, when running jstest, both the Home and Back button don't show activity, except that an "@" character is displayed at the end of the jstest line.

      What would cause the controller not to be recognized even if it successfully pairs via Bluetooth and jstest shows that the controller actually produces input events? Is there a config file that can be tweaked to recognize this thing? It pairs successfully, and is operational, with Android devices, so I figure there must be a way...

      1 Reply Last reply Reply Quote 0
      • R
        Ray Ingles
        last edited by

        OK, so... can anyone point me to documentation about how, "under the hood", controllers are recognized by Emulation Station/RetroArch/whatever? Like I said, this thing pairs, and the Linux kernel is obviously seeing the inputs.

        How does the software read events from controllers? Is there documentation? I'm willing to poke around but a little nudge in the right direction would save me quite a bit of time...

        herb_fargusH 1 Reply Last reply Reply Quote 0
        • herb_fargusH
          herb_fargus administrators @Ray Ingles
          last edited by

          @ray-ingles I'm not familiar with gamestick controllers. But basically: you have the kernel level integration in Linux that you see results with jstest. When you configure controls through emulationstation, the generated ES config is parsed out into the retroarch configs and a few non retroarch systems as well.

          This page talks a bit about controller heirarchy in retroarch specifically.

          https://retropie.org.uk/docs/RetroArch-Configuration/

          If you read the documentation it will answer 99% of your questions: https://retropie.org.uk/docs/

          Also if you want a solution to your problems read this first: https://retropie.org.uk/forum/topic/3/read-this-first

          1 Reply Last reply Reply Quote 0
          • R
            Ray Ingles
            last edited by

            Well, I dug around the docs, and even manually created some configurations in "/opt/retropie/configs/all/retroarch-joypads", and an entry in "es_input.cfg" for the controller. It shows up in the Bluetooth settings as "GameStick Controller", so that's what I named it in the configuration files.

            But no go. When I boot up the retropie and EmulationStation starts up, it still says "No Gamepads Detected", even though the controller is paired.

            How does EmulationStation figure out what controllers are available? Do I have to dig into the code?

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

              @ray-ingles ES uses SDL underneath, so the easiest way to test is to grab a program called jstest-sdl[*] (which is similar to jstest mentioned in the docs) and see if your gamepad is detected by this program.

              • https://github.com/Grumbel/sdl-jstest
              R 1 Reply Last reply Reply Quote 0
              • R
                Ray Ingles @mitu
                last edited by

                @mitu - I've done some more digging. The GameStick doesn't seem to be recognized properly by the evdev system. Found some fun log messages via dmesg:

                [ 15.328485] hid-generic 0005:0F0D:1011.0003: unknown main item tag 0x0
                [ 15.328963] input: GameStick Controller as /devices/platform/soc/3f201000.uart/tty/ttyAMA0/hci0/hci0:11/0005:0F0D:1011.0003/input/input2
                [ 15.330713] hid-generic 0005:0F0D:1011.0003: input.hidraw2: BLUETOOTH HID v7.07 Keyboard [GameStick Controller] on b8:27:eb:03:bd:7f
                

                It appears that the "unknown main item tag" error (which, googling around, seems to be a bug), is causing the controller to be detected by evdev as a "Keyboard". Which, obviously, doesn't work so hot for controller stuff, since the various buttons don't seem to map to anything ES's controller setup recognizes as a button or axis.

                I'm going to see if there's any kind of config option or something I can pass to allow this to work...

                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.