DualSenseX icon indicating copy to clipboard operation
DualSenseX copied to clipboard

[BUG]: Input rate of virtual controller lower than the real one

Open Kanuan opened this issue 3 years ago • 2 comments

Tested with DualSenseX v1.4.9

Verifying DualSenseX's virtual controller Input Rate

Real controller Input Rate

I verified with Wireshark that the average Input Rate of my DualSense controller is ~1,2ms, as shown in the image below:

image

DualSenseX' virtual X360 Input Rate test

I switched DualSenseX to X360 emulation in order to use the following tool: Xbox 360 Controller (XInput) Polling Rate Checker. This tool would then inform the Input Rate of DualSenseX's virtual Xbox 360 controller. This is the result:

image

DS4Windows' virtual X360 Input Rate test

To confirm the tool is functioning as normal, I compared it to DS4Windows' virtual X360 controller, which resulted in what I think is a virtual controller that closely reflects the real controller Input Rate:

image

Though I couldn't make the same test with DualSenseX's virtual DS4, I could more-or-less confirm its Input Rate is the same as the virtual X360 (I can elaborate on how I "confirmed" this if needed).

Conclusion

If DualSenseX was reading every report but then just taking ~10ms to process each the resulting Input Rate would still be the same as the controller's, but every command would be delayed by 10ms (and the XInput tool wouldn't be able to perceive this delay).

What actually seems to be happening is that DualSenseX is reading and processing only 1 out of 9 Input Reports being sent by the controller, the other ones being ignored, resulting in the lower Input Rate.

Kanuan avatar Jan 21 '22 14:01 Kanuan

Hello, this is good insight on the matter, currently I’m running a thread that sleeps every 15ms, then I parse the input report and apply whatever the report is showing to the virtual controllers. I do only read one type of input report, and I don’t think reading others will make a difference since The thread is still at 15ms sleep time. I will try to look into other input reports, if there’s one that is smaller in size, could help in reducing delays. Thank you for posting the link to the polling rate checker, can try to make some adjustments to get the lowest possible rate. Will do some testing later today

Paliverse avatar Jan 21 '22 19:01 Paliverse

I've made some adjustments and now im getting about 3ms duration from that tester

Paliverse avatar Jan 22 '22 02:01 Paliverse