Using Dualshock 4 as Kodi Remote

hello there,

I’m trying to use my Playstation 4 Controller (wireless) as a Kodi Remote. nothing special, just navigate, volume control, play/pause…

on a raspberry pi 3, the pairing worked flawless with the MyOSMC -> Bluetooth menu, im seeing the Controller as “Wireless Controller”.

but in Kodi just the touchbar works, i can scroll horizontal through my Recent Movies in the homescreen.

all other buttons do not work.
copying the joystick.PS4.Controller.xml from /usr/share/kodi/system/keymaps/ to /home/osmc/.kodi/usermap/keymaps/ didn’t change anything.

did I miss something here? shouldn’t the dualshock4 work out-of-the-box?


I don’t think controllers will be properly supported until Kodi Krypton. You could try a test build.

does not work in latest krypton build.
is this a Kodi issue or osmc?

using a dualboot with LAKKA, navigating the interface there and playing ROMS with the same controller works perfect.

I don’t know enough about this controller.


Newest console I own is a PS2… so… sorry.

Controllers that are joysticks to linux never worked properly iirc.

When kodi 17 comes out and they still don’t work, we really should investigate further.

Thanks for explaining this

With this I mean that they did not work in kodi and only worked properly with retropie if kodi was quit.
So this could or could not be a problem later with retroplayer if the underlying issue would prevent them from working simultaniously.

I also tried to make a gamepad mapping for kodi, but that also did not work for me with generic usb joypads.

The only people who seems to have some success with controlling kodi with gamepads are the ones with xbox controllers but I think this only works if you pair them in keyboard emulation mode.

ok seems that the ds4drv seems to work fine (at least with moonlight).

Here is a small HowTo for raspberry pi 3:

  1. install python pip
    sudo install python-dev python-pip build-essential

  2. install the dualshock 4 driver:
    sudo pip install ds4drv

  3. Make sure your Controller is paired in MyOSMC -> Bluetooth, name should be “Wireless Controller”

  4. try ds4drv, the --hidraw option makes sure it uses the paired controller
    sudo ds4drv --hidraw

  5. When the device is busy, stop it by pressing PS button for 10secs, then start it again by pressing PS button.
    Now it should scan it sucessfully and show battery status.

  6. autostart it:

cd /etc/udev/rules.d/
sudo wget
sudo udevadm control --reload-rules
sudo udevadm trigger
sudo nano /etc/rc.local

paste ds4drv --hidraw before exit 0

later i try to attach a kodi keymap for the dualshock4, hope this will work

Great :slight_smile:
Then it should also work in retropie.

Eager to hear about your findings in terms of controlling kodi with it.

Great news.

Be good have is working in retropie also.

I presume controllers should be plug and play on krypton?

I just create an account mkub to tell you u are one crazy , big , super , awesome guy !!! I’m trying to make my ps4 controller work wirelessly on kodi from the beginning of times !!!Thanx you man , really thanx not only to find the solution but to share with others. If you ever come to Athens you are my guest !Beers over Akropoli ! Luv u! :heart_eyes: