Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tweak PS4 non-hack report timer #903

Merged

Conversation

bsstephan
Copy link
Contributor

@bsstephan bsstephan commented Mar 21, 2024

The old keepalive timer of 250ms (four forced reports when idle, per second) functioned, but was far longer than a single frame, meaning that stuck inputs could still definitely happen, just for short periods of time. This was fine when the only game we knew about was Ultimate Chicken Horse, which, while being a platformer, is not exactly the most precision-heavy game. However, we learned in beta testing 0.7.8 that the Hamster Arcade Archives also often exhibit this problem, especially games like Tetris: the Grand Master, where precision is absolutely important.

Turning the timer down to sub-frame (assuming 60 Hz input mechanisms) means we have a couple opportunities to force the correct input down to the PS4 within one frame, which in my testing to this point has eliminated any stuck/missed inputs in TGM.

the synthetic results at 2ms were pretty good, just a bit too high of a
stddev (compared to other modes) for my liking. I think 5ms will do what
I want (multiple forced reports when idle per 60 Hz frame) without
harming real-world usage.

2ms results for posterity (three runs of WydD):

min: 0.55
max: 2.38
average: 0.97
stddev: 0.38

min: 0.55
max: 2.24
average: 0.97
stddev: 0.38

min: 0.55
max: 2.38
average: 0.99
stddev: 0.38

5ms should scoot the average and stddev down a bit.
@bsstephan bsstephan marked this pull request as ready for review March 27, 2024 16:39
@bsstephan bsstephan changed the title WIP/DEMO: Tweak PS4 non-hack report timer Tweak PS4 non-hack report timer Mar 27, 2024
Copy link
Contributor

@arntsonl arntsonl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good!

@arntsonl arntsonl merged commit a64eaa1 into OpenStickCommunity:main Mar 28, 2024
32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants