• Recent
  • Tags
  • Popular
  • Home
  • Docs
  • Register
  • Login
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

Almost finished home RasPi 3B, Issue with Controllers, Need fresh minds

Scheduled Pinned Locked Moved Help and Support
raspberrypi 3b+raspberry piretropie 4.4usb hubusb adapter
36 Posts 5 Posters 2.5k 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.
  • T
    tjayhawk32
    last edited by 20 May 2019, 06:37

    Pi Model or other hardware: B3+
    Power Supply used: 2.5A Power Supply (included)
    RetroPie Version Used (eg 3.6, 3.8.1, 4.1 - do not write latest): 4.4
    Built From: RetroPie website install to SD card
    USB Devices connected: USB hub, wireless keyboard (devices in hub listed below)
    Error messages received: line 1012: 28330 illegal instruction retropie genesis

    I'm almost finished with this project, but getting a bit burned out and thought I might need some fresh eyes on the project. Thank you a ton for anyone helping in advance.

    I am using a RetroPie on a Raspberry Pi 3b+. Using a 400GB SD card for roms and scrapes, if that matters. No issues with storage so far.

    So the problem stems from a decision I made to use real controllers. I am using over 30 consoles on here, and at one point got determined to hunt down original controllers and run them through adapters into a USB hub.

    Here is the port hub I am using - https://www.amazon.com/gp/product/B07FSJ33X6/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1

    If I use the port straight by itself and Retrobit controllers (or something without an adapter), it's largely not an issue, for instance with my two F500 Arcade Sticks.

    The problem seems to be with using adapters.

    Here is a rundown of what I have plugged in right now

    NES x2 (controllers) - 1 of each https://www.amazon.com/gp/product/B00HM3QCN2/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1
    Genesis x2 (this will also work with Atari 2600, in theory. I'd need a second one but I haven't tested it yet. - https://www.amazon.com/gp/product/B00QRZ1HVS/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1

    N64 x2 (same thing, will eventually use two for a total of 4 controllers) - https://www.amazon.com/gp/product/B002B9FIUU/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1

    Dreamcast x2 - https://www.amazon.com/gp/product/B00K7YK0YA/ref=ppx_yo_dt_b_asin_title_o03_s01?ie=UTF8&psc=1

    SNES x2 - https://www.amazon.com/gp/product/B002IXZ5DE/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1

    PS1 - I have a hodge podge of these, at least two of which are this https://www.amazon.com/gp/product/B000YMQGWU/ref=ppx_yo_dt_b_search_asin_title?ie=UTF8&psc=1
    No clue why I have so many (like 7)

    I also have controllers that do not yet have adapters such as Atari 5200, Atari 7800, Jaguar, Turbografx16, Virtual Boy, and maybe a couple others I'm not remembering.
    But hopefully that information paints a picture and gets this going...

    So here is the main problem...

    My initial plan was to get a USB hub with individual power switches on the ports, that way all controllers could stay plugged in for less of a mess (compartmentalized) and you simply pushed the button to activate the needed controller. As I understood how it worked better, that wasn't really possible because turning off the port is the same as unplugging it, which changes the port recognized in RetroPie for that controller.

    As I'm sure many know, this causes potential chaos in the config files on what ports to point to.

    So I activated Joystick-Config and was just going to keep all of them on all the time. This was working at first, but when I started adding multiple adapters, it got weird. The most common symptom is that after configuring the controllers and setting the ports in the config or retroarch, an emulator will stop loading roms altogether...going to the initial splash screen before returning to the roms list.

    Example - Today I plugged in the Genesis adapter and two 3-button OEM controllers. The N64 and Dreamcast adapters/controllers that I did yesterday (and were working ok) seemed to cause an issue. I was able to control the menu with the Genesis controllers, but once I tried to load a rom, there was that soft crash.

    BUT, when I switched off the ports with the DC and N64 adapters, the Genesis emulator loaded fine, and the controllers worked fine also. I tried switching off only one of them twice, but only after turning off both did the Genesis emulator work again, and this was with all three available Genesis emulators.

    I ran several restarts, script rebuilds, etc. to verify the result.

    Curious, I left the configured Genesis adapter in, and loaded back up the other two. Trying Dreamcast, it now has stopped working. At first I was unable to load, just like today's Genesis problem. After switching off the Genesis adapter, it is now recreating an issue I had yesterday where I can move the menu and the Dreamcast clock screen. but not the game itself.

    I repeated the steps to fix this that I ran yesterday, and no dice. It seems to be stuck.

    As a sanity check, I plugged in a PS1 adapter. Precise same issue, soft crash on the rom screen. With this one I had to switch off the Genesis, N64 and Dreamcast adapter ports.

    Once done, PS1 loads perfect, configuration fine on the adapter.

    What is going on here?

    Again, I wouldn't mind switching them off and on if it didn't nuke the config ports every time.

    My basic logic is thinking three things...in order of my biggest to my smallest hunch..

    Somewhere, configurations in the file manager are being overwritten or changed whenever I set up a new one. It seems that the best solution would be to somehow get the Genesis emulator, N64 emulator, and so on completely ignore the other ports. Like don't even check them, as I THINK based on when/how the failed launch is happening, its happening when it comes across other ports and for whatever reason doesn't like what it just read (even though that port will not be used).

    There is an issue with the port hub creating interference between the ports. I got this hunch because when I loaded the Genesis emulator finally, I turned the other two adapters back on while the game was on. The messaging on the bottom right seemed to register one of them fine, but showed the other port # as either unconfigured or some variation of not set up.
    I know that's not accurate, as it shows up in correct configuration elsewhere outside of that situation, if that makes sense. I may try to get another port hub to test today.

    There is an issue with the adapters simply not working well together. If this is the case, I'm unsure how to check or know this, as certain adapters can be quite expensive.

    I did try to check logging on the Genesis when it was failing, but could not find any information on the result. I'm not terribly familiar with verbose logging, so I don't know if there is more information somewhere to be found.

    This was the error at the time - line 1012: 28330 illegal instruction retropie genesis
    I have done various things in the file manager, but for now simply decided to go back and update all installed packages while I power nap. I don't know which of the things that I've done are useful, so please forgive me on that. I just don't want to dump a bunch of unusable information. So please let me know what ideas you have and I can try or let you know what happened when I came across it.

    Again, a huge thanks. My fiance would love to see me finish this thing and work on some other projects :P

    1 Reply Last reply Reply Quote 0
    • M
      mitu Global Moderator
      last edited by 20 May 2019, 11:25

      You may be having multiple problems, but I think you're main issue is that you've perform some - un-needed - extra configuration with RetroArch and your configuration files might conflict. You've used 'Save Configuration' in RetroArch or 'Save Configuration on Exit' and this messes up the controller config.

      Normally, when you configure a gamepad in Emulationstation, this creates the needed RetroArch config for the controller. When the configuration is not created, but the gamepad is detected, you get the message that 'controller # is un-configured' in RetroArch.

      Seeing that you want to have all controllers present all the time, once RetroArch is started it would detect all your joysticks/gamepads and assign them to players (I think by default there are max. 5 players in RA).
      Your problem is just re-ordering the gamepads so that when you start a system, the joysticks/gamepads for that system take precedence. Since the controller order can very between OS reboots, your best bet is to re-order the joysticks by name and for this I think the Joystick selection tool is the utility to do it, since it supports ordering by name and system - i.e. for NES start with Controller names 'NES Adaptor' as P1 and 'Nes Adaptor (2)' as P2, etc.

      I'd suggest starting from scratch, configure your gamepads, install the joystick selection tool I mentioned and re-order them.
      If you find the need to do button/input remapping, use the Core input mapping options or the 'Override' menu.

      The other errors related to ROMs starting, they might be a side-effect of mismatch in the configuration files or bad ROMs, but it's hard to say without an actual example.

      [..]. My fiance would love to see me finish this thing and work on some other projects :P

      It could take a few years, but you'll get there.

      T 1 Reply Last reply 21 May 2019, 16:26 Reply Quote 1
      • T
        tjayhawk32 @mitu
        last edited by tjayhawk32 21 May 2019, 16:26

        @mitu Buddy, this is an incredible response. Excited to get to work on it tomorrow. Everything has gotten a fresh update from the source.
        One thing you said that clicked with me, I did change the save configuration thing in RetroArch at one point.
        But also, the option for the max # of gamepads in RetroArch (which is 5), do I need to make a change there somehow"?

        Also I am using Joystick Selection tool, absolutely critical. But I have not tried by name. Will do that.

        M 1 Reply Last reply 21 May 2019, 17:57 Reply Quote 0
        • S
          stoney66
          last edited by 21 May 2019, 17:36

          oh man the joystick selection tool seems awesome, I was always wondering if there was a way to order the sticks per system.

          @tjayhawk32 I assume if you have 12 gamepads and the joy selection tool sees all 12 then you just put the top 4 or 5 for the system you want to bind it to (what games have 5 players?).

          T 1 Reply Last reply 22 May 2019, 04:33 Reply Quote 1
          • M
            mitu Global Moderator @tjayhawk32
            last edited by 21 May 2019, 17:57

            @tjayhawk32 said in Almost finished home RasPi 3B, Issue with Controllers, Need fresh minds:

            But also, the option for the max # of gamepads in RetroArch (which is 5), do I need to make a change there somehow"?

            I think you need to change it in the /opt/retropie/configs/all/retroarch.cfg, but I see now the default might be higher. It's commented out, but if you need to change it, just remove the # and modify the value accordingly.

            # Maximum amount of users supported by RetroArch.
            # input_max_users = 16
            
            1 Reply Last reply Reply Quote 1
            • T
              tjayhawk32 @stoney66
              last edited by 22 May 2019, 04:33

              @stoney66 I wouldn't have gotten anywhere without that tool.
              I ended up having to install it from command line for some reason, but it's fantastic.

              When you have the tool, go to RetroPie Settings from the main Emulation Station menu, and Joystick Selection is a new option there.
              From there you can select global control ports or individual consoles.
              So go into the individual consoles, select each player port and select the desired controller from the list.

              It works like magic for the most part. I'm about to try the other method @mitu mentioned.

              Also, general update, i bought like 5 different brands of USB hubs. The original 16-port hub that I had would work with the 3 or 4 adapters plugged in, but if I did a 'stress test' and plugged in like 9 or 10, then the crashes would start again.

              Some brands don't register at all (a larger Anker). A couple of others seemed to work no problem.
              So just to mitigate that as a potential issue, I'm going to get a different multi-port one that's hopefully better quality than the 16-port one I was initially using.

              1 Reply Last reply Reply Quote 0
              • T
                tjayhawk32
                last edited by 23 May 2019, 06:49

                That Retroarch max of 16, is that a literal max?
                I need something like 38 ports if I'm going to go all-out with my plan.

                In total it would be about 51 controllers.
                Sounds crazy I know...

                1 Reply Last reply Reply Quote 0
                • T
                  tjayhawk32
                  last edited by tjayhawk32 23 May 2019, 14:05

                  Ok @mitu , I changed the ports to the named thing and while I think this is going to be useful, it didn't solve the problem.

                  I'm burned out. I have revolving problems that just keep popping up.

                  And the main problem, no matter what combination I do (I tried one, two and three USB hubs at a time tonight), once I go over a certain number of controllers...like 4 or 5, certain emulators stop loading ROMs. I tested them all with only one controller plugged in and every emulator loaded.

                  RetroArch just doesnt open from the RetroPie settings sometimes.

                  The change to use names in joystick selection was a nightmare also, with an error i got for a couple of hours saying several permissions were denied. At times it would seem to go through and show that it was 'on' but after restarting or simply closing the selection tool and reopening it, it would be back to off.
                  After the 10th uninstall, refresh operation...it seems to be staying on now.

                  But the unfortunate ending of a long night is the exact same issue.

                  I changed the number of max users in the Retroarch file (can you clarify which you were talking about to be sure, I did it in two places), and I can't make direct adjustments in the RetroArch XMB because I can't open the thing...

                  Also, Mitu, if you're up for it, I would be eternally grateful if you would have a second to video chat or something to really just blaze through the issue. I've really drained a lot of time into it the last few months, and I think it's possible to reach an end on what is or isn't possible.
                  tjayhawk@live.com

                  M 1 Reply Last reply 23 May 2019, 18:37 Reply Quote 0
                  • M
                    mitu Global Moderator @tjayhawk32
                    last edited by mitu 23 May 2019, 18:37

                    @tjayhawk32 Without any logs to spot an error, it's hard to understand where the problem might be. Get a verbose log from RetroArch when the 'ROMs stop loading' and post it on pastebin.com. You can enable the verbose logging from the Runcommand launch menu , then get the /dev/shm/runcommand.log file and post it on pastebin.com

                    I changed the number of max users in the Retroarch file (can you clarify which you were talking about to be sure, I did it in two places), and I can't make direct adjustments in the RetroArch XMB because I can't open the thing...

                    Which files did you modify ? One file should be enough - /opt/retropie/configs/all/retroarch.cfg.

                    And the main problem, no matter what combination I do (I tried one, two and three USB hubs at a time tonight), once I go over a certain number of controllers...like 4 or 5, certain emulators stop loading ROMs. I tested them all with only one controller plugged in and every emulator loaded.

                    Are the USB hubs powered or you're just powering them from the RPI USB port ? With so many controllers, you need a separate powered hub.

                    Also, Mitu, if you're up for it, I would be eternally grateful if you would have a second to video chat or something to really just blaze through the issue. I've really drained a lot of time into it the last few months, and I think it's possible to reach an end on what is or isn't possible.

                    I'm doing enough support for my real job, so I don't think that's going to happen.

                    EDIT: it seemed an interesting question, so I searched how many USB devices could possibly run on an USB connection - http://www.yoctopuce.com/EN/article/how-many-usb-devices-can-you-connect. You might be hitting some physical limits on connecting so many USB devices on a single USB hub.

                    If the USB connection is having problems talking to so many devices, you could get some info about it in the system's log - run dmesg when you connect more than 4-5 devices and see if you notice any errors being reported.

                    T 1 Reply Last reply 24 May 2019, 16:47 Reply Quote 1
                    • T
                      tjayhawk32 @mitu
                      last edited by 24 May 2019, 16:47

                      @mitu Thanks for the reply, I hear you on time.

                      This paste is an attempt to load Sega Genesis after plugging in several controllers. In MC, many of these lines are in red, but I wasn't able to copy it over like that. Not sure if it matters, but they were almost all in the Retropad section.
                      https://pastebin.com/tAnNk48h

                      /opt/retropie/configs/all/retroarch.cfg is the correct file that I changed. But I don't know if 16 is what it's telling me is the max or if it's just a default setting.

                      I have both powered and unpowered USB hubs here, and both 3.0 and 2.0. All have the same issue. What I tried earlier is splitting the controllers between 3 powered hubs (plugged into different ports on the pi), and got the same result.

                      Here is the result of dmesg..
                      https://pastebin.com/HKKeYf3e
                      The article was an interesting read and now I'm curious about how much the 'full-speed' of the device matters. But I haven't sifted through this one yet...

                      T M 2 Replies Last reply 24 May 2019, 16:50 Reply Quote 0
                      • T
                        tjayhawk32 @tjayhawk32
                        last edited by 24 May 2019, 16:50

                        And I just looked up the error at the end of the crash info..

                        https://retropie.org.uk/forum/topic/11221/runcommand-segmentation-fault-after-update-today/11

                        I did consider going through and listing everything that was 'unset' to 'disabled'....think that might be it?

                        1 Reply Last reply Reply Quote 0
                        • M
                          mitu Global Moderator @tjayhawk32
                          last edited by 25 May 2019, 12:10

                          @tjayhawk32 said in Almost finished home RasPi 3B, Issue with Controllers, Need fresh minds:

                          This paste is an attempt to load Sega Genesis after plugging in several controllers. In MC, many of these lines are in red, but I wasn't able to copy it over like that. Not sure if it matters, but they were almost all in the Retropad section.
                          https://pastebin.com/tAnNk48h

                          You've used the 'Save/Reset Configuration' from RetroArch - despite my advice not to so - and your BIOS dir doesn't exist anymore

                          [WARN] SYSTEM DIR is empty, assume CONTENT DIR /home/pi/RetroPie/roms/megadrive/Sonic The Hedgehog (USA, Europe).md
                          [INFO] Environ SYSTEM_DIRECTORY: "/home/pi/RetroPie/roms/megadrive/".
                          

                          https://retropie.org.uk/forum/topic/11221/runcommand-segmentation-fault-after-update-today/11

                          I did consider going through and listing everything that was 'unset' to 'disabled'....think that might be it?

                          I don't know if that old topic's info applies to your error, from the log file you're either missing the BIOS (which is understandable, since your BIOS folder is unset) or the ROM is not correct.

                          I have both powered and unpowered USB hubs here, and both 3.0 and 2.0. All have the same issue. What I tried earlier is splitting the controllers between 3 powered hubs (plugged into different ports on the pi), and got the same result.

                          Your dmesg output shows USB bus disconnects, so the configuration is clearly not working because of USB connection getting reset.

                          1 Reply Last reply Reply Quote 0
                          • T
                            tjayhawk32
                            last edited by 25 May 2019, 12:24

                            @mitu said in Almost finished home RasPi 3B, Issue with Controllers, Need fresh minds:

                            You've used the 'Save/Reset Configuration' from RetroArch - despite my advice not to so - and your BIOS dir doesn't exist anymore

                            I'm not entirely sure what you're referring to.. I didn't use RetroArch to do anything recently. In fact, I just reinstalled from source last night. BUT I can't open the GUI still for Retroarch. That crashes also, from the RetroPie Setup screen.

                            As for the BIOS or the ROM, they all work. If I only plug in a couple of controllers, every single ROM and emulator works.

                            I'll take a closer look at dmesg, but what I was doing right now is reading about segmentation faults, which appears to be pretty widely varied.
                            https://retropie.org.uk/forum/topic/1673/lr-pcsx-rearmed-runcommand-sh-line-804-5728-segmentation-fault-since-3-8/5

                            I am going to try to turn off auto-config and/or RetroResolution's fix here, real quick.

                            M 1 Reply Last reply 25 May 2019, 12:34 Reply Quote 0
                            • M
                              mitu Global Moderator @tjayhawk32
                              last edited by mitu 25 May 2019, 12:34

                              I'm not entirely sure what you're referring to.. I didn't use RetroArch to do anything recently. In fact, I just reinstalled from source last night. BUT I can't open the GUI still for Retroarch. That crashes also, from the RetroPie Setup screen.

                              On a default install the SYSTEM_DIR is set to /home/pi/RetroPie/BIOS, your log shows otherwise.

                              EDIT: if you manually modified the retroarch.cfg, you shouldn't remove the already existing settings.

                              I'll take a closer look at dmesg, but what I was doing right now is reading about segmentation faults, which appears to be pretty widely varied.
                              https://retropie.org.uk/forum/topic/1673/lr-pcsx-rearmed-runcommand-sh-line-804-5728-segmentation-fault-since-3-8/5

                              Segmentation fault means RetroArch crashed. It's usually a ROM or BIOS issue, but your case it might be related to the joypad connections.

                              T 1 Reply Last reply 25 May 2019, 12:43 Reply Quote 0
                              • T
                                tjayhawk32 @mitu
                                last edited by 25 May 2019, 12:43

                                @mitu
                                https://i.imgur.com/1wMJx7x.jpg
                                https://imgur.com/a/IqH7ZhW

                                The BIOS directory is there, with a last modified of May 9th.
                                Something I need to move or change there?

                                M 1 Reply Last reply 25 May 2019, 12:50 Reply Quote 0
                                • M
                                  mitu Global Moderator @tjayhawk32
                                  last edited by 25 May 2019, 12:50

                                  @tjayhawk32 said in Almost finished home RasPi 3B, Issue with Controllers, Need fresh minds:

                                  The BIOS directory is there, with a last modified of May 9th.

                                  I think you misunderstood what I said - you've modified the retroarch.cfg (either editing or using Reset) and RetroArch doesn't know about this folder to search for BIOS files. Look at my previous reply - where I've outlined the lines from the log showing that.

                                  T 1 Reply Last reply 25 May 2019, 13:01 Reply Quote 0
                                  • T
                                    tjayhawk32 @mitu
                                    last edited by tjayhawk32 25 May 2019, 13:01

                                    @mitu Apologies, I follow.

                                    The reason I said a few lines back that I didn't know 'which' retroarch.cfg to go into might have something to do with this.

                                    I have one here
                                    https://imgur.com/81FbkC3
                                    which is at /opt/retropie/configs/all/retroarch.cfg

                                    And this much more complete one
                                    https://imgur.com/DWuZAeA
                                    Which is at /opt/retropie/configs/all/retroarch/retroarch.cfg

                                    Is this unimportant or does the second one need to be a directory back?

                                    EDIT: Also, I'm going to double check this but I am 95% sure this issue of too many controllers = emulator no longer loads is exclusive to the libretro emus, so far with the exception of DGEN which just went to a red screen and paused there.

                                    M 1 Reply Last reply 25 May 2019, 13:11 Reply Quote 0
                                    • M
                                      mitu Global Moderator @tjayhawk32
                                      last edited by 25 May 2019, 13:11

                                      @tjayhawk32 said in Almost finished home RasPi 3B, Issue with Controllers, Need fresh minds:

                                      And this much more complete one
                                      https://imgur.com/DWuZAeA
                                      Which is at /opt/retropie/configs/all/retroarch/retroarch.cfg

                                      That file is not used by RetroArch on a normal RetroPie installation, only the former.

                                      T 1 Reply Last reply 25 May 2019, 13:21 Reply Quote 1
                                      • T
                                        tjayhawk32 @mitu
                                        last edited by 25 May 2019, 13:21

                                        @mitu Ah, so it's at least supposed to be there.

                                        Does the first one look wrong or that it's missing something? Not totally sure what to to next.

                                        T 1 Reply Last reply 25 May 2019, 13:43 Reply Quote 0
                                        • T
                                          tjayhawk32 @tjayhawk32
                                          last edited by 25 May 2019, 13:43

                                          Here's what I think I'm gonna do today later...
                                          I ordered an external hard drive that I'm going to use for ROMs instead of the SD card I have in there to be able to get more stuff on there.

                                          I was going to try to clone it, but if I just do a complete fresh install, would that fix this controller issue in your reasoning?

                                          And do I need to clear the SD card first? (I have all the ROMs on another external drive...scraping again will suck though.)

                                          And @mitu , I see how many times youre reaching out on here to guys in need of help. You're an all-star, thank you.

                                          M 1 Reply Last reply 25 May 2019, 14:02 Reply Quote 0
                                          20 out of 36
                                          • First post
                                            20/36
                                            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.

                                            This community forum collects and processes your personal information.
                                            consent.not_received