Link controller in bluetooth

How to Connect a Bluetooth Controller to Lakka? (Really works)

pair bluetooth controller lakka

Whatever the system you choose for retro-gaming, playing with a Bluetooth controller is really the best experience you can have.
Unfortunately, it’s rarely the easiest way to plug a controller, and you might have a hard time figuring out how to do this.
Don’t worry, I’ll explain everything for Lakka in this tutorial.

How to connect a Bluetooth controller to Lakka?
On Lakka the Bluetooth is disabled by default, so the first step is to enable it in the system settings.
Then, some controllers will pair automatically once connected, but most of them will require command lines.

In the following of this tutorial, I will do step-by-step explanations of how you can do this, whatever your controller.

By the way, I recommend using the 8BitDo Pro controller that is really above the other models available for an affordable price, or at least a PS4 controller if you already have one (maybe too expensive if you need to buy it).

Getting started on Lakka

Ok, so your Bluetooth controller will not work directly, so you have to start with something else to set up Lakka correctly before anything else.
I have an entire tutorial about Lakka here if you need some help about this.
Make sure to have an Internet access, maybe do a few updates and basic configuration (date/time, keyboard, enable SSH, etc.).

I’m using my Bluetooth keyboard to do this, as there is a dedicated USB adapter, I don’t have anything to configure, so it’s pretty cool.
But any USB keyboard or wired controller is ok to start (try to avoid using the one you want to put in Bluetooth for the moment).

My favorite games!
Get a list of my 24 favorites games (with links) to play on Retropie, Recalbox or Lakka

Once you’re satisfied with your Lakka installation, you can move to the next step.

Читайте также:  Драйвера виндовс 10 блютуз acer

Enable Bluetooth

For almost anything on Lakka, you can do it in the graphic interface or in command line. I will give you both each time I can, but the interface way is the first one to try.

Interface

As I told you, the Bluetooth is disabled by default, so the first thing to do is to enable it:

  • In the main menu, open the Settings submenu (the second one).
  • Scroll download to “Services“.
  • Find the Bluetooth line and click on it to enable the service.

It’s ok, Bluetooth is enabled and you can move to the next step.

Command line

If you have any issue with the previous method, or prefer to do this in command line, here is how to do the same thing:

  • Enable the SSH service (just above the Bluetooth line in the settings).
  • Connect to your Raspberry Pi (with Putty or any other SSH client).
    You can find the IP address in “System information” in the first menu.
    And the default user and password are : root / root
  • Once connected, enter the three following commands:
    touch /storage/.cache/services/bluez.conf
    systemctl enable bluetooth
    systemctl start bluetooth
  • Check that the service is working correctly:
    systemctl status bluetooth
  • In my case, I got something like this:

    I don’t know if the last line is a problem, but the service is running so it should be ok 🙂

Pairing the Bluetooth controller

Interface / automatic method

In theory, most Bluetooth controller should pair automatically.
Let’s try this with my first controller (8BitDo SF30 Pro) :

  • Make sure your controller has enough battery (or charge it before doing this)
  • Plug your controller to a free USB port (use the supplied cable)
  • Lakka should detect it automatically while plugged:
  • In theory, your controller should now be paired with Lakka, and you can unplug it to use it in Bluetooth.
    In reality, none of my controllers is working this way, so I’m not even sure if this method can work.

That’s why, in both case, I had to follow the manual method with the command line.

My favorite games!
Get a list of my 24 favorites games (with links) to play on Retropie, Recalbox or Lakka

Command line / manual method

If like me, your controller are not pairing directly with a USB connection, you can try this:

  • Access Lakka via SSH (see previous parts)
  • Start a Bluetooth prompt with:
    bluetoothctl
  • Put your controller in pairing mode. The method depends on your controller.
    On 8BitDo, press Start+X for example. The 2 first LEDs should start blinking.
    For a PS4 controller, press PS and Share simultaneously:
    pairing mode for a ps4 controller
    The light should start to blink quickly.
  • Enter the following commands in the prompt:
    agent on
    default-agent
    power on
    discoverable on
    pairable on
    scan on
  • The tool will start detecting any Bluetooth device and display the address
    For example, for the PS4 controller:

    I started the scan a second time thinking it was too late, but it was not necessary.
    Once you see the controller address, you can start the connection
  • Type the following command to pair the controller manually:
    connect
    In my case:
    connect 1C:96:5A:AD:6F:7E
  • You’ll get a few messages, including a confirmation:
    [CHG] Device 1C:96:5A:AD:6F:7E Connected: yes
    [CHG] Device 1C:96:5A:AD:6F:7E Paired: yes
    If it doesn’t work, try again (for both mine, it works the second time…)

You should now be able to navigate in the Lakka menus with your Bluetooth controller.

That’s it, my two favorites are ready to use. Who wants to play? 🙂

Controller configuration

Lakka is a simple system for controller configuration.
On Retropie & others, you need to configure all the buttons for each new controller you plug.
On Lakka, most controllers are detected automatically (as seen previously), and you don’t have anything to do, it will work correctly as soon as you plug it.

But if you want, you can still edit the configuration to make it as you want:

lakka input configuration

  • Go to the Settings submenu, and select the corresponding input
  • In the submenu, you can configure the main part of your controller individually:
    • Combo
    • Swap OK & Cancel (A & B vs B & A for example)
    • Hot keys
    • Input User X Binds, for all the other buttons

Once done, you can play your favorite game in wireless 🙂
Need a few games ideas? Check my top 12 here.

Get My Commands Cheat Sheet!
Grab your free PDF file with all the commands you need to know on Raspberry Pi!

Want to chat with other Raspberry Pi enthusiasts? Join the community, share your current projects and ask for help directly in the forums.

Auto-reconnect controllers after a reboot

I noticed in the Lakka version I tried that Bluetooth controllers are not connected automatically after a reboot.
So you have to do the same thing each time.
I like this system mainly because it’s easy to use, but I’m very disappointed by this issue. I think it’s pretty new, I don’t remember it (maybe only on Pi4?).

I don’t know if it’s a bug in the recent versions or anything else, but I have found a basic workaround on this Lakka forum.
You can create a script to run the “connect” command automatically on boot (we already have the controller MAC, so we don’t need the other commands).

But I hope that developers will fix this soon, so beginners don’t have to create a script and schedule it for such a basic feature.
Let me know if you find another way.

Get My Commands Cheat Sheet!
Grab your free PDF file with all the commands you need to know on Raspberry Pi!

Conclusion

That’s it, you should now be able to connect any Bluetooth controller on Lakka.
If you have any issue with this, feel free to leave a comment in the community with the errors you get, and I will try to help you.

Also, if you love retro-gaming on Raspberry Pi, I have many tutorials on this website that you’ll like, here are a few examples:

I’m the lead author and owner of RaspberryTips.com.
My goal is to help you with your Raspberry Pi problems using detailed guides and tutorials.
In real life, I’m a Linux system administrator with web developer experience.

Источник

Оцените статью
Adblock
detector