Skip to content

feat(libScePad): answer the tracker DualShock 4, Blaster and Move queries - #9664

Merged
oneandonlydean merged 1 commit into
boykopovar:mainfrom
krishalivaibhav:feat/pad-tracker-device-queries
Oct 23, 2026
Merged

oneandonlydean merged 1 commit into
boykopovar:mainfrom
krishalivaibhav:feat/pad-tracker-device-queries

Conversation

@krishalivaibhav

Copy link
Copy Markdown
Contributor

What

scePadIsDS4Connected, scePadIsBlasterConnected and scePadIsMoveConnected threw not implemented. They now return false for any handle.

Tested

Linux: Ubuntu x86-64 chroot in a Lima VM on macOS (Apple Silicon), at 81ae747 on main d6eafa5. I built guest_pad_tests and guest_pad_vibration_mode_tests and ran ctest -R '^guest_pad': 2/2 pass.

guest_pad now runs CheckTrackerDevices(). It calls each of the three functions with the open handle and with an invalid one and requires false. On main the first call throws not implemented, so the test fails there.

tools/check_conventions.py --base origin/main passes. tools/progress.py goes from 4,834 to 4,837 done functions out of 11,181 (43.23% to 43.26%).

Windows: not built. No title was run.

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: n/a
  • AI-assisted: yes

🤖 Generated with Claude Code

…ries

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Progress report (d6eafa5 → 81ae747)

📈 System libraries: 43.26% (+0.03%, +3 implemented functions)

✅ 3 implemented
Library Name
libScePad scePadIsBlasterConnected
libScePad scePadIsDS4Connected
libScePad scePadIsMoveConnected
⚪ 3 behaviourally empty (constant return or throw)
Library Name
libScePad scePadIsBlasterConnected
libScePad scePadIsDS4Connected
libScePad scePadIsMoveConnected

@github-actions

github-actions Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.

Pull request Shared files not compared
PR 5038 core/libs/prx/libScePad/Export.cpp
docs/dev/debt/libScePad.md
PR 6044 core/libs/tests/GuestPad.cpp
PR 9178 core/libs/prx/libScePad/Export.cpp
core/libs/tests/GuestPad.cpp
docs/dev/debt/libScePad.md

@fogydes

fogydes commented Oct 22, 2026

Copy link
Copy Markdown
Contributor

Reviewed; this checks out. Answering all three tracker queries with an unconditional false is the only answer consistent with what the module already reports elsewhere: scePadGetInfo_nid_postfix sets slot.deviceType = PAD_DEVICE_TYPE_DUAL_SENSE (Export.cpp:213) and the device-class promotions report PAD_DEVICE_CLASS_STANDARD, and the debt file's Touchpad-resolution entry already records that the library reports one DualSense to every title. So no DualShock 4, Blaster or Move device can ever be behind a handle here, and false for every handle is not an invented value but a consequence of the established pad table. The new debt entry states exactly that and honestly marks the unmeasured part (invalid-handle answer), the signatures were already bool (int32_t) from the pending-export declarations so nothing is invented there either, and the test reuses the file's existing invalid-handle pattern (handle + 1, as in CheckAccessibilityControllerState) with no new registration needed.

Two notes, neither blocking:

  1. The PR body says the pad test run was on Steam Deck only ("deck-only claim") — the Windows CI leg will exercise GuestPad.cpp too, so worth watching its first green run before merge.
  2. The PR body says the 8-PR overlap check was done by hand because pr_overlap.py ran out of disk — a maintainer re-run of python3 tools/pr_overlap.py --branch <branch> would confirm that result cheaply.

@MarcZX10 MarcZX10 left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The unconditional false answers are consistent with the existing emulation, which exposes a single DualSense rather than DS4, Move or Blaster devices. The invalid-handle uncertainty is explicitly documented, and the regression checks both a valid and invalid handle. Exact-head diff-check and conventions pass; hosted eligibility/intake/labels/report pass. Linux/Windows product build jobs are skipped, so the 2/2 guest_pad run is author-reported. The existing open PR overlaps are acknowledged in the description; I did not find a behavior overlap in the listed changes.

I’ve noticed that holding this PR because of #5239 isn’t necessary. It’s fine for PRs to keep coming in; they’ll be handled in due course. Please disregard my earlier request to hold or defer it.

@krishalivaibhav

Copy link
Copy Markdown
Contributor Author

Thanks @MarcZX10, and @fogydes for the review. That's fair: none of the titles I'm testing reaches these. I checked the original modules of Balatro (PPSA21402), Don't Starve Together (PPSA02070) and Vampire Survivors (PPSA21703) for the NIDs of scePadIsDS4Connected, scePadIsBlasterConnected and scePadIsMoveConnected: none imports them (all three import scePadOpen). I'm converting this to a draft and holding it until a title needs these, and I'll take library work from functions a title actually stops on, with the title ID and log line.

(For the record, the guest_pad runs were in an x86-64 Ubuntu chroot in a Lima VM, not on a Steam Deck.)

AI-assisted: yes (Claude Code).

@krishalivaibhav
krishalivaibhav marked this pull request as draft October 22, 2026 09:22

@MarcZX10 MarcZX10 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Correction: my earlier changes-requested review was based only on the mistaken queue hold tied to #5239. I found no code blocker in this PR; PRs may continue to be submitted and will be handled in due course.

@krishalivaibhav
krishalivaibhav marked this pull request as ready for review October 22, 2026 17:59
@oneandonlydean oneandonlydean self-assigned this Oct 22, 2026
@MarcZX10

Copy link
Copy Markdown
Contributor

I’ve noticed that my earlier request to hold this PR based on #5239 was unnecessary. It’s fine to keep submitting PRs; maintainers will handle them in due course. Please disregard that request.

@oneandonlydean
oneandonlydean merged commit 11cf1c8 into boykopovar:main Oct 23, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants