Commit Graph

14 Commits

Author SHA1 Message Date
Adrià 7feed2748a
Merge pull request #1076 from TideOPL/fix/pad-read-debt-note
fix(libScePad): queue input states for scePadRead
2026-10-11 10:49:44 +02:00
virp-mta 95cd0e8faf feat(libScePad): implement scePadSetAngularVelocityBiasCorrectionState 2026-10-10 02:54:42 +04:00
Scott Schuster 7c8dae0b33 fix(pad): accept the compatible vibration mode
scePadSetVibrationMode rejected mode 2 (compatible, per SharpProspero's
ScePadVibrationMode). The PS5 SDL joystick driver requests it on every
open and closes the pad when it fails, so SDL titles lost their controller.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-08 18:08:05 -05:00
TideOPL 74a4d47133 Merge remote-tracking branch 'origin/main' into pr1076
# Conflicts:
#	core/libs/prx/libScePad/Export.cpp
2026-10-08 10:46:36 +01:00
Dean 8180dc5b9c
Merge pull request #1118 from TideOPL/feat/pad-is-remote-controller
feat(libScePad): implement scePadIsRemoteController
2026-10-08 18:19:30 +13:00
Gjon Gojcevic 54ed8e7f9c feat(libScePad): report special controllers as not connected in scePadOpenExt
Add scePadOpenExt for special ports, which return DEVICE_NOT_CONNECTED because the host has no special controller, and the extended read and report exports, which throw.
2026-10-08 15:31:10 +13:00
TideOPL efceec9c56 feat(libScePad): implement scePadIsRemoteController
NID fCWdlnmB1Ks was exported as an unknown function that threw. The
name scePadIsRemoteController hashes to it. PPSA16064 (Minecraft
Dungeons II) calls it once per controller after
scePadGetControllerInformation, with the pad handle and the address of a
byte it has just zeroed, and ignores the result.

It reports whether the controller is connected through Remote Play.
Controllers here are local devices, so the answer is always false. An
invalid handle returns INVALID_HANDLE and a null output INVALID_ARG, as
the other pad calls do. Without it the title aborted at the main menu.

scePadSetAngularVelocityBiasCorrectionState, which the title imports but
does not call during start-up, is added as an unimplemented export.

guest_pad checks the handle and null-output errors and the result.
2026-10-07 14:08:12 +01:00
TideOPL efa6cd56f0 fix(libScePad): queue input states for scePadRead
scePadRead reported only the current state, so input that changed and
changed back between two reads was lost. Published states are now kept in
a queue of up to 64 and drained oldest first; with none queued the current
state is returned as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 11:03:30 +01:00
alfalfa-star b6176624aa fix(pad): return INVALID_HANDLE from scePadReadState for an unknown handle
PPSA14632 calls scePadReadState (eboot 0x4593a8) for the open pad and
then for a second pad slot it never opened, whose handle is 0. The
title skips only negative handles and ignores the result, but
scePadReadState threw for any handle other than the open one. It now
returns PAD_ERROR_INVALID_HANDLE (0x80920003), as the other pad
functions do and as shadPS4's scePadRead does for an unknown handle;
scePadRead passes it on.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 14:43:00 +02:00
hamb3r aad1be52e8 fix(pad): synthesize touch contact for Xbox View 2026-10-05 16:13:26 +03:00
Phi1ow e4bc4a4ecb fix(pad): check the handle and keep the dead band throwing when enabled
Per review: scePadSetAngularVelocityDeadbandState now returns PAD_ERROR_INVALID_HANDLE for a
handle other than PAD_HANDLE, like the neighbouring setters. Enabling the dead band still throws,
because the angular-velocity reading path does not apply the filter (that would change input, not
UI, so it is not a silent stub); disabling it succeeds, which matches the unfiltered readings.
The test checks the disabled call, the bad handle, and no longer asserts the enabled path.
2026-10-05 00:48:45 +02:00
Phi1ow 1cd34c232d feat(pad): implement scePadSetAngularVelocityDeadbandState
scePadSetAngularVelocityDeadbandState was the last throwing stub in libScePad. It toggles a
dead-band filter on the controller's angular-velocity (gyro) readings; the reading path does
not apply that optional filter, so the call succeeds and does nothing, as it does in shadPS4.

Extends the existing guest_pad test with the two enable/disable calls. It fails on main (the
stub throws) and passes with the change.
2026-10-04 23:19:37 +02:00
SP4C3B4R-8 c4be3f78f6 feat(libScePad): implement scePadSetTiltCorrectionState
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Bn7CrhG7pTPR6DT13tN6Me
2026-10-01 23:44:31 +02:00
Adrià Franch 621c8bea23 feat(libScePad): implement scePadGetHandle and the embedded mic vibration option
scePadOpen now records that the pad is open and scePadClose clears it;
scePadGetHandle returns the handle for a port scePadOpen accepts while
the pad is open, and DEVICE_NO_HANDLE otherwise. No embedded microphone
is emulated, so the option that weakens trigger vibration while it is
in use is accepted with no effect.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-10-01 19:57:32 +02:00