I kept working on the bluetooth protocol and I found that there is an authentication process carried over the HID control channel. It consists in a sequence of bluetooth transfers that lasts about 30 seconds, and that restarts after 30 seconds. If this sequence fails 8 times in a row, the PS4 stops taking inputs.
This means GIMX will require a genuine Dualshock 4 to control a PS4. It will have to stay connected as the authentication sequence is periodical.
I also worked on writing an AVR USB firmware that can emulate the pairing procedure of the Dualshock 4. It allows to pair any bluetooth device address with the PS4. I spent more time than I thought on this because of a problem in the USB transfers that only seems to happen with the PS4 as USB host. Frank from eleccelerator helped me to fix this issue.
This firmware is designed to work with a tool called ds4tool that can do the following tasks:
- read the bluetooth device address from a real or emulated DS4
- read the PS4 address from a real or emulated DS4
- write the PS4 address and the link key of a real or emulated DS4
- write the bluetooth device address of an emulated DS4
- read the link key from an emulated DS4
Hey Matlo,
Thank You for doing this and keeping us updated.