# [SOLVED] Can't seem to get PS3 controller working

## Bladesy

Hello all, I've been trying to get my PS3 controller working using the wiki page, but when I connect the controller by USB, nothing seems to happen. 

I've gone back into my kernel config and double checked that everything is checked, and I'm positive that I've replaced the kernel correctly, as I managed to get another device working while I was at it. 

I'm also sure that the controller is connected correctly, as it comes up in the output for lsusb. However, I'm not sure how to see what driver its using - even if I did know, I'm not even sure what generic USB driver it could be using, or even what the driver it should be using is called. 

Does anyone have any ideas? 

Thanks in advance.Last edited by Bladesy on Sat May 14, 2016 11:31 pm; edited 1 time in total

----------

## NeddySeagoon

Bladesy,

Post the lsusb line, so we can see which PS3 controller you have.

Check your kernel in use with uname -v.

The Date/Time in the output is the build time of the running kernel.  IS it what you expected.

Did you build the kernel modules as <M> or <*> ?

If its the former, maybe the driver did not auto load. 

Check with lsmod.

----------

## Bladesy

Thanks for the quick reply, the kernel definitely seems to be the most recent one I've compiled, and I definitely didn't set any of the kernel components to modular. 

I also ran "lsusb -v" as my normal user, and got a large output about the controller:

```
Bus 002 Device 006: ID 054c:0268 Sony Corp. Batoh Device / PlayStation 3 Controller

Device Descriptor:

  bLength                18

  bDescriptorType         1

  bcdUSB               2.00

  bDeviceClass            0 

  bDeviceSubClass         0 

  bDeviceProtocol         0 

  bMaxPacketSize0        64

  idVendor           0x054c Sony Corp.

  idProduct          0x0268 Batoh Device / PlayStation 3 Controller

  bcdDevice            1.00

  iManufacturer           1 Sony

  iProduct                2 PLAYSTATION(R)3 Controller

  iSerial                 0 

  bNumConfigurations      1

  Configuration Descriptor:

    bLength                 9

    bDescriptorType         2

    wTotalLength           41

    bNumInterfaces          1

    bConfigurationValue     1

    iConfiguration          0 

    bmAttributes         0x80

      (Bus Powered)

    MaxPower              500mA

    Interface Descriptor:

      bLength                 9

      bDescriptorType         4

      bInterfaceNumber        0

      bAlternateSetting       0

      bNumEndpoints           2

      bInterfaceClass         3 Human Interface Device

      bInterfaceSubClass      0 

      bInterfaceProtocol      0 

      iInterface              0 

        HID Device Descriptor:

          bLength                 9

          bDescriptorType        33

          bcdHID               1.11

          bCountryCode            0 Not supported

          bNumDescriptors         1

          bDescriptorType        34 Report

          wDescriptorLength     148

         Report Descriptors: 

           ** UNAVAILABLE **

      Endpoint Descriptor:

        bLength                 7

        bDescriptorType         5

        bEndpointAddress     0x02  EP 2 OUT

        bmAttributes            3

          Transfer Type            Interrupt

          Synch Type               None

          Usage Type               Data

        wMaxPacketSize     0x0040  1x 64 bytes

        bInterval               1

      Endpoint Descriptor:

        bLength                 7

        bDescriptorType         5

        bEndpointAddress     0x81  EP 1 IN

        bmAttributes            3

          Transfer Type            Interrupt

          Synch Type               None

          Usage Type               Data

        wMaxPacketSize     0x0040  1x 64 bytes

        bInterval               1

can't get device qualifier: Resource temporarily unavailable

can't get debug descriptor: Resource temporarily unavailable

Device Status:     0x0000

  (Bus Powered)
```

Running "lsmod" however doesn't seem to give much information, but I don't think the controller driver is any of those: 

```
[bladesy@sheath ~ $ lsmod

Module                  Size  Used by

nvidia_modeset        700197  4

nvidia               8689484  76 nvidia_modeset

x86_pkg_temp_thermal     4647  0

efivarfs                5483  1
```

----------

## NeddySeagoon

Bladesy,

It sounds like you are running the kernel you intended to run.  That's always a good start.

The important bit of lsusb is 

```
  idVendor           0x054c Sony Corp.

  idProduct          0x0268 Batoh Device / PlayStation 3 Controller
```

The Wiki looks correct too. 

Look in /dev/input,  now connect your joystick, power it on, wait a few seconds ...

Look in /dev/input again.

Do you have some new nodes?

They will belong to your joystick.  If they are there, your kernel is OK.

----------

## Bladesy

I'm not a very advanced user, so I'm not too familiar with /dev or nodes, but a file called js1 appears only when the controller is plugged in - and it disappears when I take out the controller too. 

I'm guessing that this is the node for the controller, since it resembles joystick1?

----------

## NeddySeagoon

Bladesy,

Thats it. Your kernel can see it.

For some history and a few wrinkles, this Arch wiki page is worth reading. 

The key takeaway for you is that there are two ways to have joysticks appear in /dev and some software will only work with one of them. 

About /dev nodes.  A long time ago /dev was a static filesystem and contained entries for every possible device. It still works but its rarely used.

Today, you will have the kernel option DEVTMPFS on.  This causes the kernel to create entries in /dev only for hardware actually attached to the system.  Entries are removed when a device is unplugged.

Your js is an example. 

If your joystick doesn't work in your application, debugging that is the next step.

----------

## Bladesy

Well, after some testing with the controller - although the driver does not give it the behaviour of turning off and on with the home button, or any LED light activity aside from blinking constantly when plugged in - it does seem to be working fine. 

PCSX2 was able to recognise it as a pad and allowed me to map it and thus use it. 

I initially tried testing the controller in controller-compatible steam games, but they didn't work - and since the activity the controller displayed was nothing like what the driver said, I assumed something had gone wrong. 

Thanks for your help Neddy, I'm sure I can get the controller working in everything else now that I know its working fine, although I feel wine may be a bit of a problem. 

Thanks again.

----------

