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

    Controls mixed up again and again

    Scheduled Pinned Locked Moved Help and Support
    arcade controlsxinmomapping
    30 Posts 6 Posters 4.8k 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
      Tim's up @mitu
      last edited by

      @mitu

      Hey thanks for this.
      Yes, I was careful to wire all the controllers in the same way. Although there a small differences : players 1 and 2 have 6 buttons, players 3 and 4 have only 4 buttons and player 1 has a hotkey button.

      When I map only one player, the other controllers don't seem to work. When I map them all separately they do work...until I open a rom or reboot.

      1 Reply Last reply Reply Quote 0
      • T
        Tim's up @mitu
        last edited by Tim's up

        @mitu
        Also, I was wondering how can one explain the rising number of "IDs" allocated to my controllers? The ES log shows this quite well.

        YFZdudeY mituM 2 Replies Last reply Reply Quote 0
        • YFZdudeY
          YFZdude @Tim's up
          last edited by

          @tim-s-up
          I just did an experiment to see if this happens to me.

          RPi3B+ with only 1 logitech F310 controller plugged in.
          I started ES, launched an Atari 2600 game, quit, launched a 2nd game, quit, launched a 3rd game, then quit.

          My ES log shows that when ES starts, my controller has instance ID 0, then at each game launch, the instance ID increases by 1. Everything works fine in each game, so apparently the increasing IDs are not the problem and is somewhat normal.

          T 1 Reply Last reply Reply Quote 1
          • mituM
            mitu Global Moderator @Tim's up
            last edited by

            @tim-s-up It's an internal SDL allocated number, as I explained in your previous topic. Each time libSDL initializes the joystick, it allocates another number - this happens when the controller is detected or after ES starts a game/script and goes into background.

            1 Reply Last reply Reply Quote 0
            • T
              Tim's up @YFZdude
              last edited by

              @yfzdude
              @mitu

              Thank you both. OK so controller IDs are not the problem. I will recheck my wiring, seems to be the only sensible thing to do.

              J 2 Replies Last reply Reply Quote 1
              • J
                JakeS @Tim's up
                last edited by

                @tim-s-up Any success with this? I'm facing the same sort of issue with my 2 player xin-mo setup.

                1 Reply Last reply Reply Quote 0
                • J
                  JakeS @Tim's up
                  last edited by

                  @tim-s-up I broke down and re-wired all the controls. It turns out the kit I got (from Microcenter) had some bad advice about not worrying about the order they are wired, it said remapping in emulationstation would be fine.

                  But it DID matter that A button for joystick1 was wired the same as the A button for joystick2, etc. I had several things wired differently on each side. That meant when I mapped them independently in ES they would work, but ES would apply that mapping to the other side too.

                  T 1 Reply Last reply Reply Quote 1
                  • T
                    Tim's up @JakeS
                    last edited by

                    @jakes Hey, sorry I was away for some days and didn't see your post.

                    Unfortunately, I couldn't do all the testing yet. I tried my 2 Xinmos separately (connecting only one) and it did work, so the issue is the two working together.

                    When you say they all have to be wired the same way, how do you handle the extra buttons (hotkey, in my case also buttons 5 and 6 on 2 main controllers) ?

                    lostlessL 1 Reply Last reply Reply Quote 0
                    • lostlessL
                      lostless @Tim's up
                      last edited by lostless

                      @tim-s-up meaning every button is wired to the same physical spot on each encoder. A goes to whatever you make A. But it has to be the same spot . Every encoder has to be wired IDENTICALLY. If you don’t have 5-6 on 2 of them, just ignore them on those 2. You can wire the hot key to whatever for player one. When you config the controllers in emulation station, ONLY CONFIG PLAYER ONE. The rest will just use that config. No need to config each encoder if they share the same brand and model. Also Only player one can use hot key.

                      T 1 Reply Last reply Reply Quote 0
                      • T
                        Tim's up @lostless
                        last edited by

                        @lostless @mitu I tried to map only player 1 in Emulationstation. Indeed it worked after a reboot, the other 3 players were mapped the same. BUT, for players 3 and 4 only the buttons work, the joysticks don't. When I manually map the two non working joysticks, P1 and P2 stop working. I checked, all 4 joysticks are wired the same way :-(

                        mituM 1 Reply Last reply Reply Quote 0
                        • mituM
                          mitu Global Moderator @Tim's up
                          last edited by

                          @tim-s-up Use jstest with each joystick and see what's the output for 3 and 4 for the non-working analog joysticks. Are they registered on the same device as the buttons or on another device ?

                          T 1 Reply Last reply Reply Quote 0
                          • T
                            Tim's up @mitu
                            last edited by

                            @mitu Ok, I will give it a go with jstest but joysticks 3 and 4 are working. E.g. they are working when I map them manually (but P1 and P2 stop working in that case).

                            @tim-s-up Are they registered on the same device as the buttons or on another device ?

                            You mean wired to the same interface ? Yes, P1 and P2 on Xinmo I, P3 and P4 on Xinmo II.

                            lostlessL 1 Reply Last reply Reply Quote 0
                            • lostlessL
                              lostless @Tim's up
                              last edited by

                              @tim-s-up said in Controls mixed up again and again:

                              Yes, P1 and P2 on Xinmo I, P3 and P4 on Xinmo II.

                              This look like it may be your problem right there. The xinmo 1 and 2 may be using the same encoder chip, so retropie sees them both as the same controller, but the pins might not match up between each. This is where some trouble shooting comes in. You have to match the virtual buttons to their proper locations. So if you configure player one and the dpad is using the hat input, ie hat up, down, etc, you have to find out what pins match up for the encoder for players 3 and 4 that use the hat output.

                              T 1 Reply Last reply Reply Quote 0
                              • T
                                Tim's up @lostless
                                last edited by

                                @lostless said in Controls mixed up again and again:

                                So if you configure player one and the dpad is using the hat input, ie hat up, down, etc, you have to find out what pins match up for the encoder for players 3 and 4 that use the hat output.

                                Thanks, but, noob question, how do I do that?

                                lostlessL 2 Replies Last reply Reply Quote 0
                                • lostlessL
                                  lostless @Tim's up
                                  last edited by lostless

                                  @tim-s-up
                                  If these are the correct products I found by googling, these are the correct pinouts. Notice how they don’t match for the 1 player vs 2 player. Match up the proper buttons accordingly. Button one go to button one on all player. Ect. Ect..
                                  note that these may not be the proper pinouts. Check your documentation because I just found these by googling the brand. If these aren’t correct or you don’t have documentation, it might be easier to just use windows joystick tool and map out each pin.
                                  296682DC-2262-4ABC-BB3B-04C0557B3F62.jpeg
                                  383F8590-51BF-45FE-8343-5B8D36DF0AB9.png

                                  1 Reply Last reply Reply Quote 0
                                  • lostlessL
                                    lostless @Tim's up
                                    last edited by lostless

                                    @tim-s-up actually looking at your logs you posted I think I see your problem. It looks like one type of controller is mapping to the x/y axis and the the other to the hat directions for the UDLR. That is an issue. It’ll explain why when you configure one you lose direction control on the other . You may not be able to mix the 2 encoders you might have to get all the same for all 4. Now I do see a mode button on the 1 player, if it is the right pinout, that button might toggle between analog and digital. Problem is who knows if that setting will stick when powered off.

                                    T 1 Reply Last reply Reply Quote 0
                                    • T
                                      Tim's up @lostless
                                      last edited by Tim's up

                                      @lostless thanks for the pinouts, those are the ones I'm using. And sorry for this, I misunderstood the question.

                                      So, you think I have one Xinmo going digital controls and the other analog ?
                                      What if I wire a button to the mode pin on each Xinmo ? Could it toggle between the two ?

                                      lostlessL 1 Reply Last reply Reply Quote 0
                                      • lostlessL
                                        lostless @Tim's up
                                        last edited by

                                        @tim-s-up I assume so. Give it a try

                                        T 1 Reply Last reply Reply Quote 0
                                        • T
                                          Tim's up @lostless
                                          last edited by

                                          @lostless Oh man, you made my day! It works!

                                          To sum up for others facing this problem with a 4 player Arcade setup :
                                          I reset all controls in Retropie setup, shut down, wired the "mode" pin on each Xinmo to a physical arcade button. Launched the machine, mapped only P1 when prompted upon entering emulationstation, reboot, P1 and P2 working as usual, P3 and 4 don't. Then pushed the "mode" button and Hallelujah!

                                          The kids will love it. We can finally play 4 player games after all those months of looking for the issue. Big thanks to all who helped and especially to @lostless and @mitu for your support. Love the forum!

                                          mituM 1 Reply Last reply Reply Quote 1
                                          • mituM
                                            mitu Global Moderator @Tim's up
                                            last edited by

                                            @tim-s-up Glad you got it working, @lostless is the one that provided the solution though :).

                                            1 Reply Last reply Reply Quote 1
                                            • 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.