Wireless Dualshock

Note: In recent versions of Lakka, DualShock pairing have been simplified. You can start bluetooth in the Lakka Services and after plugging/unplugging your controller, it should be paired automatically.

If not, read the following guide.

All the following commands have to be executed on your Lakka Box using the Command Line Interface

Enabling bluetooth

Enable and start bluetooth service

systemctl enable bluetooth
systemctl start bluetooth

Check that the service is active

systemctl status bluetooth

● bluetooth.service - Bluetooth service
   Loaded: loaded (/usr/lib/systemd/system/bluetooth.service; enabled; vendor preset: enabled)
   Active: active (running) since Tue 2015-04-07 19:37:50 UTC; 1s ago
 Main PID: 489 (bluetoothd)
   Status: "Running"
   CGroup: /system.slice/bluetooth.service
           └─489 /usr/lib/bluetooth/bluetoothd

If you get this message

● bluetooth.service - Bluetooth service
   Loaded: loaded (/usr/lib/systemd/system/bluetooth.service; enabled; vendor preset: enabled)
   Active: inactive (dead)
Condition: start condition failed at Tue 2015-04-07 19:35:48 UTC; 1min 59s ago
           ConditionPathExists=/storage/.cache/services/bluez.conf was not met

it means you have to create the config file, and restart the service

touch /storage/.cache/services/bluez.conf
systemctl start bluetooth

Pairing the controller

Launch bluetoothctl


A bluetooth prompt will appear. Type the following:

agent on
power on
discoverable on
pairable on
scan on

Dualshock 4

The Dualshock 4 is a bit different from the Dualshock 3 in that you should press the “Share” and “PS Home” button at the same time to get it into detection mode. You do not need to have controller connected via USB. Now press the two buttons and the led should start blinking rapidly. You will see output in your terminal similar to this:

[bluetooth]# scan on`
Discovery started`
[CHG] Controller 00:15:83:0C:BF:EB Discovering: yes
[NEW] Device 90:FB:A6:D6:D0:45 90-FB-A6-D6-D0-45
[CHG] Device 90:FB:A6:D6:D0:45 LegacyPairing: no
[CHG] Device 90:FB:A6:D6:D0:45 RSSI: 127
[CHG] Device 90:FB:A6:D6:D0:45 Name: Wireless Controller
[CHG] Device 90:FB:A6:D6:D0:45 Alias: Wireless Controller
[CHG] Device 90:FB:A6:D6:D0:45 LegacyPairing: yes
[CHG] Device 90:FB:A6:D6:D0:45 RSSI is nil

Now follow the steps under Authorize the Dualshock controller.

Dualshock 3

Connect the DualShock 3 to the system using a USB cable and press the button round Playstation button. Watch for connection and disconnection messages and copy the device address (something like 38:C0:96:56:4D:AA). You will see a prompt that asks you to authorize the device:

Authorize service ''service_uuid'' (yes/no):

Authorize the Dualshock controller

Authorize it by typing ‘yes’. Disconnect the USB cable from the DualShock 3. Hit the Playstation button again and while it blinks type the following:

connect <device_addr>

Keep trying this command if you see device not available (it will loop between connected and disconnected) until you see something like the following

I usually keep pressing up + enter (repeating the last command)

[CHG] Device <device_addr> Modalias: usb:v054Cp0268d0100
[CHG] Device <device_addr> UUIDs:

Now trust the device

trust <device_addr>

You’re done

Next time you hit the Playstation button it will connect without asking anything else.

Common issues

Configuring the controller

If the autoconfiguration does not work, you can manually configure your PS3 controller. You need to use the rgui menu driver to do this configuration for now. You can then switch back to lakka. The recent development builds lets you do that from the default XMB menu.

Make changes survive a reboot

If you had to type power on in bluetoothctl earlier, you will have to do this every time you reboot the system.

A simple way to avoid this is to write a udev rule. Create a file:

nano .config/udev.rules.d/bluetooth.rules

Then put

# Set bluetooth power up
ACTION=="add", KERNEL=="hci0", RUN+="/usr/bin/hciconfig hci0 up"

Also, you should add the MAC address of each of your remote controllers in /storage/.cache/services/bluez.conf:

HIDD_OPTIONS="--connect xx:xx:xx:xx:xx:xx --connect xx:xx:xx:xx:xx:xx"

This causes bluez to always try to connect to those controllers.