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

    2 Joystick 8 Button Controller Hook Up

    Scheduled Pinned Locked Moved Help and Support
    customhelpcustom controll
    20 Posts 3 Posters 1.2k 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.
    • G
      grant2258 Banned @Halvhjearne
      last edited by

      @Halvhjearne said in 2 Joystick 8 Button Controller Hook Up:

      @grant2258

      its not a microcontroller, its an adc + pga ready to use.

      you are essentially suggesting the same thing, just without the pga and in a bigger package.

      Im not referring to you sketch per say. The import part code here is the uinput to make the device for the user to use. The micro controller way you can turn a ardunio and teensy into a usb game controller and do the code

      1 Reply Last reply Reply Quote 0
      • K
        kingfrankbob
        last edited by

        Okay 2 things I do have an Arduino but no trendy I could easily get one tho. I am kinda a noob about raspberry pi but not Arduino. I have no idea how to use the https://www.adafruit.com/product/1083
        Could those joysticks then be used? Also could you add a left and right trigger and other button. Also I would need a wiring hookup for the pi and second thing. There is no need for arguing on this subject. Back to the first of you could I have never used a joystick so maybe a qiring diagram for the Arduino sorry if I am asking to much but like I said earlier I am a noob for the raspberry pi

        HalvhjearneH 1 Reply Last reply Reply Quote 0
        • K
          kingfrankbob
          last edited by

          This post is deleted!
          1 Reply Last reply Reply Quote 0
          • K
            kingfrankbob
            last edited by

            So I still need some guides
            How do you get reputation

            1 Reply Last reply Reply Quote 0
            • G
              grant2258 Banned
              last edited by

              if you want to go arduino route https://github.com/NicoHood/HID teensy has many tutorials and guide online as well.

              The solution to use the pi is posted above by me will get your axis reading and the button pressed via uinput. The first post give you a link to an adc you will need one which one is up to you.

              1 Reply Last reply Reply Quote 0
              • HalvhjearneH
                Halvhjearne @kingfrankbob
                last edited by

                @kingfrankbob

                the 2 routes posted by me and @grant2258 is essentially the same, alltho the adc + pga is clearly superior and im quite sure you can also use the same code aswell-
                the adc+pga is also "ready to use" package where as you would need to make a small circuit to utilize the MCP3008 chip.

                however, considdering this is all running on a pi, the i2c way works via a python script and you say you already have an arduino, i would definitely avoid the i2c way and just use the arduino as already has analog input pins, can act as a usb gamepad and will require minimal configuration on the pi itself.

                1 Reply Last reply Reply Quote 0
                • K
                  kingfrankbob
                  last edited by kingfrankbob

                  Okay so I hook up the 2 joysticks to the Arduino from the Adafruit product and go from there hook up to the analog input and hook up from the usb upload cable correct me maybe today I’ll draw up a sketch with my wiring idea

                  So I’m new to this forum so how do you get reputation

                  HalvhjearneH 1 Reply Last reply Reply Quote 0
                  • G
                    grant2258 Banned
                    last edited by

                    I think the reputation works with the little arrows on a post if its helpful you click up (upvote) if its unhelpful click down

                    1 Reply Last reply Reply Quote 1
                    • HalvhjearneH
                      Halvhjearne @kingfrankbob
                      last edited by

                      @kingfrankbob

                      if you use an arduino, you will not need an adc as it can already read analog inputs.
                      im unsure if you need 2 or 4 for each joystick anf you havent actually mention which model of arduino you have, but iirc the uno has at least 8 analog input.

                      1 Reply Last reply Reply Quote 1
                      • K
                        kingfrankbob
                        last edited by

                        @Halvhjearne said in 2 Joystick 8 Button Controller Hook Up:

                        @kingfrankbob

                        if you use an arduino, you will not need an adc as it can already read analog inputs.
                        im unsure if you need 2 or 4 for each joystick anf you havent actually mention which model of arduino you have, but iirc the uno has at least 8 analog input.

                        Okay I can use a metro uno or mega.

                        HalvhjearneH 1 Reply Last reply Reply Quote 0
                        • HalvhjearneH
                          Halvhjearne @kingfrankbob
                          last edited by

                          @kingfrankbob

                          it seems that the metro and uno actually only has 6 analog inputs, so if each joystick needs 4 analog inputs, you will need to use the mega for your project.
                          if you only need 2 analog inputs per joystick, you should be able to use any of those for both joysticks and buttons.

                          K 1 Reply Last reply Reply Quote 0
                          • K
                            kingfrankbob @Halvhjearne
                            last edited by

                            @Halvhjearne said in 2 Joystick 8 Button Controller Hook Up:

                            @kingfrankbob

                            it seems that the metro and uno actually only has 6 analog inputs, so if each joystick needs 4 analog inputs, you will need to use the mega for your project.
                            if you only need 2 analog inputs per joystick, you should be able to use any of those for both joysticks and buttons.

                            so which joysticks should I use do you have a suggestion?

                            HalvhjearneH 1 Reply Last reply Reply Quote 0
                            • HalvhjearneH
                              Halvhjearne @kingfrankbob
                              last edited by

                              @kingfrankbob

                              it depends on what you are trying to build, but i thought you were using the ones you linked in the op?

                              1 Reply Last reply Reply Quote 0
                              • K
                                kingfrankbob
                                last edited by

                                Yes but how should I hook them up

                                HalvhjearneH 1 Reply Last reply Reply Quote 0
                                • HalvhjearneH
                                  Halvhjearne @kingfrankbob
                                  last edited by

                                  @kingfrankbob

                                  i think this would become a bit too extensive to do via forum posts, but you can try google "arduino gamepad" or "arduino joystick" and you should be able to find plenty of both wiring and code examples to use.

                                  i have considdered doing something similar myself, but i never got around to it since i already own a xin-mo, which works just fine for now, so please show what you end up with, once you are done.

                                  1 Reply Last reply Reply Quote 0
                                  • K
                                    kingfrankbob
                                    last edited by

                                    Okay cool it might be a while I am doing a portapie homemade so I have to get that fixed and finished before I do that

                                    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.