Pocophone F1 + Dualshock 4 (DS4) of PS4 + Rules of Survival (ROS)

CosmicDan

Senior Member
Jun 19, 2009
5,845
7,676
113
33
Sydney
anyone managed to get ds4 working on custom pie roms?
Trying to figure this out too. Absolutely nothing even detects the device - BT can pair of course, but zero function of the gamepad in any app. USB is useless.

EDIT: Suddenly it works (over BT)! I have no idea how though sorry lol. I do have the 1controller and Sony Framework magisk modules, though - am using TwistedKernel right now.

Sadly though, BT Autoconnect doesn't fix the lag. It does for a while, but then goes bad again. I *do* have continuous connect set to 5 seconds doesn't help.

EDIT2: Here is an interesting bit of logcat:

Code:
03-31 03:47:31.986   706  3677 I [email protected]_handler: ProcessIbsCmd: Received IBS_SLEEP_IND: 0xFE
03-31 03:47:31.986   706  3677 D [email protected]_handler: SerialClockVote: vote for UART CLK OFF
03-31 03:47:32.041   706  3677 I [email protected]_handler: ProcessIbsCmd: Received IBS_WAKE_IND: 0xFD
03-31 03:47:32.041   706  3677 D [email protected]_handler: SerialClockVote: vote for UART CLK ON
03-31 03:47:32.041   706  3677 I [email protected]_handler: ProcessIbsCmd: Writing IBS_WAKE_ACK
03-31 03:47:32.044   706   706 I [email protected]_handler: DeviceWakeUp: Writing IBS_WAKE_IND
03-31 03:47:32.045   706  3677 I [email protected]_handler: ProcessIbsCmd: Received IBS_WAKE_ACK: 0xFC
03-31 03:47:32.137   706  3677 I [email protected]_handler: ProcessIbsCmd: Received IBS_SLEEP_IND: 0xFE
03-31 03:47:33.046   706  3684 I [email protected]_handler: DeviceSleep: TX Awake, Sending SLEEP_IND
03-31 03:47:33.046   706  3684 D [email protected]_handler: SerialClockVote: vote for UART CLK OFF
03-31 03:47:33.197   706  3477 D [email protected]_lock: Release wakelock is released
The last few lines (from DeviceSleep) is exactly when the lag started again. Bluetooth Auto Connect seems to not be working with this particular driver I guess? Hmm... I have a feeling this won't be solved until dev's start releasing ROM's with custom vendors based on CAF stuff.

EDIT3: After a reboot, once again I can't get the controller working at all. Curious. I see this kind of thing looping in logcat:

Code:
03-31 04:39:44.244  1857  2533 W bt_btif : bta_hh_co_data: Error: fd = 228, ready 0, len = 10
03-31 04:39:44.288   702  2530 I [email protected]_handler: ProcessIbsCmd: Received IBS_SLEEP_IND: 0xFE
03-31 04:39:44.288   702  2530 D [email protected]_handler: SerialClockVote: vote for UART CLK OFF
03-31 04:39:44.295  1857  2533 W bt_btif : bta_hh_co_data: Error: fd = 228, ready 0, len = 10
03-31 04:39:44.313   702  2530 I [email protected]_handler: ProcessIbsCmd: Received IBS_WAKE_IND: 0xFD
03-31 04:39:44.313   702  2530 D [email protected]_handler: SerialClockVote: vote for UART CLK ON
03-31 04:39:44.313   702  2530 I [email protected]_handler: ProcessIbsCmd: Writing IBS_WAKE_ACK
03-31 04:39:44.347  1857  2533 W bt_btif : bta_hh_co_data: Error: fd = 228, ready 0, len = 10
bt_btif seems to be spitting out an error. This *is* from platform code (not a qcom blob) so maybe it can be fixed without moving to a whole CAF vendor afterall. Looking at the source of this error, finding out why the HID device won't report ready is probably beyond my skill, let alone fixing it... *charges Google-fu*

UPDATE: Forget what I said about kernel. It would be better to use Franco's or any other kernel that upstreams from mainline Linux because kernels based on LOS/Android one use hid-sony driver from 2016; Linux kernel has had a looooot of updates to hid-sony since then so it's best to use Franco or other mainline base. Also note that both Franco kernel and TwistedKernel have the same not-ready error from above.
 
Last edited:

CosmicDan

Senior Member
Jun 19, 2009
5,845
7,676
113
33
Sydney
Some progress, for Pie custom ROM's

The kernel in POSP 2.0 is the only one I found which has working DS4 over BT. I repacked the zImage for another recent ROM (building myself) and it also worked, except Wifi was broken.

I could not get the latest POSP 2.2 kernel to boot at all on the same custom ROM (stuck on boot logo).

Additionally, to avoid the lag-after-30-seconds issue, I found the only device profile in Bluetooth Auto Connect that actually worked was PAN (Networking) with Continuous Connect enabled (I have mine on 5 seconds). This has the side-effect of a "Connecting..." ongoing notification, but I don't care - at least that works.
 
Last edited:

CosmicDan

Senior Member
Jun 19, 2009
5,845
7,676
113
33
Sydney
I'm almost ready to give up but have one last thing to try.

The ROM "potato_beryllium-9-20190127.Baked-v2.1.WEEKLY" has DS4 working fine, but the next weekly named "potato_beryllium-9-20190213.Baked-v2.1.WEEKLY" has it broken. The former has a kernel with a different base, but I'm having trouble finding that exact source code. If I can do that, though, it's only a matter of time before I find the problem.

EDIT: Yep, I've had enough. Back to MIUI lol.
 
Last edited:

BennyX1

Member
May 27, 2019
11
4
3
Running Havoc OS (Android Pie, based on the 9.4.x Vendor. Had to downgrade from Miui 10) with Sphinx Kernel. Just tried Bluetooth with my PS4 and unfortunately it connects but with absolutely no button/trigger responses.

Heard MIUI has native support on 10, but Havoc can only be flashed over 9's Vendor.

I will also post this on the Official Havoc OS forum for Pocophone but I'm posting this here so I can get updated whenever this Magisk Module supports MIUI 10 too.:victory:
 

voetbalremco

Inactive Recognized Developer
Jan 6, 2012
4,620
1,875
253
gelderland
This gets relevant again now that Sony has opened up the Remote play app.
I'm on Xiaomi.eu MIUI 10.3.8.0 with Franco kernel, which supposedly has added the controller drivers.
The DS4 connects but doesn't respond to any input though.
1Controller is said to not work on MIUI unfortunately.