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

    Bluetooth controller auto connect

    Scheduled Pinned Locked Moved Help and Support
    bluetoothcontroller
    16 Posts 2 Posters 101 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.
    • M
      mxs @mitu
      last edited by

      @mitu said in Bluetooth controller auto connect:

      So they do reconnect if you use the Bluetooth RetroPie menu's connect all devices ? What if you restart the controller - does it reconnect ? I'm trying to understand what 'manually' means here.

      The only way I can get the Controllers to connect is to remove them(option X) from Bluetooth Device list in the Bluetooth menu, them Pair and Connect them (option P), which I believe erases their button configuration.

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

        The only way I can get the Controllers to connect is to remove them(option X) from Bluetooth Device list in the Bluetooth menu

        Ok, so the automatic re-pairing doesn't work. You may want to try the different 'connect modes' in the Bluetooth menu, one of them may work for your case.

        them Pair and Connect them (option P), which I believe erases their button configuration.

        No, this operation does not remove the configuration.

        1 Reply Last reply Reply Quote 0
        • M
          mxs @mitu
          last edited by mitu

          @mitu said in Bluetooth controller auto connect:

          Please post the file's contents here in the topic. You can access the file also via file shares from \retropie\configs\all\emulationstation.

          <?xml version="1.0"?>
          <inputList>
            <inputAction type="onfinish">
              <command>/opt/retropie/supplementary/emulationstation/scripts/inputconfiguration.sh</command>
            </inputAction>
            <inputConfig type="joystick" deviceName="Xbox 360 Controller" deviceGUID="030081b85e0400008e02000014010000">
              <input name="left" type="hat" id="0" value="8"/>
              <input name="right" type="hat" id="0" value="2"/>
              <input name="pagedown" type="button" id="5" value="1"/>
              <input name="down" type="hat" id="0" value="4"/>
              <input name="pageup" type="button" id="4" value="1"/>
              <input name="y" type="button" id="2" value="1"/>
              <input name="x" type="button" id="3" value="1"/>
              <input name="b" type="button" id="0" value="1"/>
              <input name="a" type="button" id="1" value="1"/>
              <input name="up" type="hat" id="0" value="1"/>
              <input name="select" type="button" id="6" value="1"/>
              <input name="start" type="button" id="7" value="1"/>
            </inputConfig>
            <inputConfig type="joystick" deviceName="Sony Interactive Entertainment Wireless Controller" deviceGUID="0300d0424c050000cc09000011810000">
              <input name="rightanalogdown" type="axis" id="4" value="1"/>
              <input name="left" type="hat" id="0" value="8"/>
              <input name="rightanalogleft" type="axis" id="3" value="-1"/>
              <input name="right" type="hat" id="0" value="2"/>
              <input name="pagedown" type="button" id="5" value="1"/>
              <input name="down" type="hat" id="0" value="4"/>
              <input name="rightanalogup" type="axis" id="4" value="-1"/>
              <input name="pageup" type="button" id="4" value="1"/>
              <input name="rightanalogright" type="axis" id="3" value="1"/>
              <input name="y" type="button" id="3" value="1"/>
              <input name="x" type="button" id="2" value="1"/>
              <input name="b" type="button" id="0" value="1"/>
              <input name="a" type="button" id="1" value="1"/>
              <input name="up" type="hat" id="0" value="1"/>
              <input name="select" type="button" id="8" value="1"/>
              <input name="start" type="button" id="9" value="1"/>
              <input name="leftanalogright" type="axis" id="0" value="1"/>
              <input name="leftanalogup" type="axis" id="1" value="-1"/>
              <input name="leftanalogdown" type="axis" id="1" value="1"/>
              <input name="leftanalogleft" type="axis" id="0" value="-1"/>
            </inputConfig>
            <inputConfig type="joystick" deviceName="Wireless Controller" deviceGUID="05009b514c050000cc09000000810000">
              <input name="rightanalogdown" type="axis" id="4" value="1"/>
              <input name="left" type="hat" id="0" value="8"/>
              <input name="rightanalogleft" type="axis" id="3" value="-1"/>
              <input name="right" type="hat" id="0" value="2"/>
              <input name="pagedown" type="button" id="5" value="1"/>
              <input name="down" type="hat" id="0" value="4"/>
              <input name="rightanalogup" type="axis" id="4" value="-1"/>
              <input name="pageup" type="button" id="4" value="1"/>
              <input name="rightanalogright" type="axis" id="3" value="1"/>
              <input name="y" type="button" id="3" value="1"/>
              <input name="x" type="button" id="2" value="1"/>
              <input name="b" type="button" id="0" value="1"/>
              <input name="a" type="button" id="1" value="1"/>
              <input name="up" type="hat" id="0" value="1"/>
              <input name="select" type="button" id="8" value="1"/>
              <input name="start" type="button" id="9" value="1"/>
              <input name="leftanalogright" type="axis" id="0" value="1"/>
              <input name="leftanalogup" type="axis" id="1" value="-1"/>
              <input name="leftanalogdown" type="axis" id="1" value="1"/>
              <input name="leftanalogleft" type="axis" id="0" value="-1"/>
            </inputConfig>
          </inputList>
          
          M 1 Reply Last reply Reply Quote 0
          • M
            mxs @mxs
            last edited by mxs

            I tried all 3 connect options (default, boot, and background) and none of those are working. Let me make sure I am attempting this correctly. When I start the system it automatically starts Emulation Station and RetroPie. When I first turn it on, I then click the home button on the controllers which makes it give a slow constant white light flash while it looks for a connection. Is this the right mode as opposed to the pairing mode when it does a short blast of white flashes every 3 or 4 seconds?
            When I turn on the controller it attempts to connect for maybe 30 seconds then turns back off.

            I just removed the Bluetooth controller then paired/connected it again, and see that it held the button configuration. I may have been having difficulty because I have had other controllers, a mouse, and a keyboard connected at different times and they may have interfered or been taking the 'Port 1' in games.

            So now I am down to the issue being that the controller will not connect unless I readd it each time I restart the machine in the Bluetooth menu.

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

              @mxs said in Bluetooth controller auto connect:

              . Is this the right mode as opposed to the pairing mode when it does a short blast of white flashes every 3 or 4 seconds?

              Yes, most likely. Assuming the same behavior as a genuine DS4 controller, the flashing lights are specific to the pairing mode.

              When I turn on the controller it attempts to connect for maybe 30 seconds then turns back off.

              Right, so no automatic re-connection. Any chance on getting the debug log I mentioned a while ago ?

              I may have been having difficulty because I have had other controllers, a mouse, and a keyboard connected at different times and they may have interfered or been taking the 'Port 1' in games.

              A keyboard/mouse will not take over the 'Port 1', only a controller.

              So now I am down to the issue being that the controller will not connect unless I readd it each time I restart the machine in the Bluetooth menu.

              Unfortunately I think this is a controller issue, not something that's caused by RaspiOS/Linux (RetroPie just uses the OS's Bluetooth stack). Maybe a debug log would show something of help, but ultimately any paired device should re-connect automatically to it's partner when it's powered on.

              Does the controller work with another PC ? Leaving aside a PS4, does it work properly (i.e. reconnects after a start/restart) to a PC running Windows/Linux ?

              EDIT: just to make sure, is your RetroPie system updated - with the OS packages also ?

              M 2 Replies Last reply Reply Quote 0
              • M
                mxs @mitu
                last edited by

                @mitu said in Bluetooth controller auto connect:

                Right, so no automatic re-connection. Any chance on getting the debug log I mentioned a while ago ?

                I'm not completely familiar with how to do the debug part. I did open a terminal and attempt to connect to the controllers while in desktop and was unsuccessful. I then attempted to connect via the Manage Bluetooth devices icon in the tray with the Wireless Controller -> Connect option and this is what it said in terminal...

                [NEW] Device 8D:AB:C5:B3:48:0E Wireless Controller
                [CHG] Device 8D:AB:C5:B3:48:0E Modalias: usb:v054Cp09CCd0100
                [CHG] Device 8D:AB:C5:B3:48:0E UUIDs: 00001124-0000-1000-8000-00805f9b34fb
                [CHG] Device 8D:AB:C5:B3:48:0E UUIDs: 00001200-0000-1000-8000-00805f9b34fb
                [CHG] Device 8D:AB:C5:B3:48:0E Connected: yes
                [CHG] Device 8D:AB:C5:B3:48:0E Bonded: yes
                [CHG] Device 8D:AB:C5:B3:48:0E UUIDs: 00001124-0000-1000-8000-00805f9b34fb
                [CHG] Device 8D:AB:C5:B3:48:0E UUIDs: 00001200-0000-1000-8000-00805f9b34fb
                [CHG] Device 8D:AB:C5:B3:48:0E ServicesResolved: yes
                [CHG] Device 8D:AB:C5:B3:48:0E Paired: yes
                [CHG] Device 8D:AB:C5:B3:48:0E WakeAllowed: yes
                [CHG] Device 8D:AB:C5:B3:48:0E ServicesResolved: no
                [CHG] Device 8D:AB:C5:B3:48:0E Connected: no
                [CHG] Device 8D:AB:C5:B3:48:0E Trusted: yes
                [CHG] Device 8D:AB:C5:B3:48:0E Connected: yes
                [CHG] Device 8D:AB:C5:B3:48:0E ServicesResolved: yes

                [CHG] Device 16:3F:AD:A3:05:C4 Connected: yes
                [CHG] Device 16:3F:AD:A3:05:C4 Bonded: yes
                [CHG] Device 16:3F:AD:A3:05:C4 UUIDs: 00001124-0000-1000-8000-00805f9b34fb
                [CHG] Device 16:3F:AD:A3:05:C4 UUIDs: 00001200-0000-1000-8000-00805f9b34fb
                [CHG] Device 16:3F:AD:A3:05:C4 ServicesResolved: yes
                [CHG] Device 16:3F:AD:A3:05:C4 Paired: yes
                [CHG] Device 16:3F:AD:A3:05:C4 WakeAllowed: yes
                [CHG] Device 16:3F:AD:A3:05:C4 ServicesResolved: no
                [CHG] Device 16:3F:AD:A3:05:C4 Connected: no
                [CHG] Device 16:3F:AD:A3:05:C4 Trusted: yes
                [CHG] Device 16:3F:AD:A3:05:C4 Connected: yes
                [CHG] Device 16:3F:AD:A3:05:C4 ServicesResolved: yes

                They did connect with the blue and red lights on the controller so that was successful.

                If you can let me know what I need to do for the debug part I can attempt that.

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

                  @mxs said in Bluetooth controller auto connect:

                  If you can let me know what I need to do for the debug part I can attempt that.

                  See:

                  If that doesn't work, you should enable debugging (see https://wiki.archlinux.org/title/Bluetooth, on the debugging section) and post the error/info messages shown by bluetoothd.

                  M 1 Reply Last reply Reply Quote 0
                  • M
                    mxs @mitu
                    last edited by

                    @mitu said in Bluetooth controller auto connect:

                    Does the controller work with another PC ? Leaving aside a PS4, does it work properly (i.e. reconnects after a start/restart) to a PC running Windows/Linux ?

                    EDIT: just to make sure, is your RetroPie system updated - with the OS packages also ?

                    I don't really have another bluetooth computer to test the controllers with.

                    All of the OS packages are updated.

                    1 Reply Last reply Reply Quote 0
                    • M
                      mxs @mitu
                      last edited by

                      @mitu I read the debugging part but I don't really understand it as I am very new with Linux. I attempted and did the stop and start commands it said, but I don't know what I am supposed to be looking for after that.

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

                        @mxs If you've enabled debugging, then run the following command

                        journalctl -f -u bluetoothd
                        

                        This will print the bluetoothd debug messages in real-time. Power up the controller and see what's printed on the terminal after the power up. Leave it to time-out and then post the messages on the screen.

                        Press Ctrl+C to interrupt the journalctl command and get back to the command prompt.

                        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.