24 Commits
Author SHA1 Message Date
bl4nkTHEBUNKER f57b79ef51 fix(libScePad): report the DualSense touchpad resolution
The controller information reported 1920 by 943, the DualShock 4 height with
the DualSense pixel density, while the host controller's fingers were scaled to
1920 by 942 and the keyboard touch contacts sat on the 942 centre line. A title
that maps touch coordinates through the reported resolution lost the lower part
of the touchpad. The width and height now live beside the pad state and all
three places use them.
2026-10-20 01:52:50 +02:00
Dean 5606dd7644 Merge pull request #7059 from Aryansh1520/fix/pad-tap-between-reads
fix(pad): report a press that ends before the next pad read
2026-10-20 09:52:24 +13:00
Romans Pokrovskis a2d6c16bcd fix(audio): route legacy vibration PCM with per-port timing 2026-10-18 10:07:29 +03:00
Aryan SharmaandClaude Haiku 5.5 f3e05559d6 fix(pad): expire an older latched press when a newer one arrives
A new press refreshed the latch timestamp for every press still latched, so an
older press could survive a later one. Drop the latch first when it has expired,
and add guest tests for the cleared, expired and newer-press cases.

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
2026-10-17 20:34:52 +05:30
XairRrR a9377e34ba feat(pad): touch the left or right touchpad half from the input command file
APS5_PAD_INPUT_FILE commands can set bit 0x200000 or 0x400000 to put a
finger on the left or right half of the touchpad, as the TouchLeft and
TouchRight keys do, so scripted runs can press touchpad combinations.
tools/pad_input.py queues them as touch-left and touch-right.

AI-assisted: yes
2026-10-17 13:27:54 +02:00
Aryan Sharma baf107a58c fix(pad): clear and expire latched presses, and keep L2/R2 analog with their bits
A latched press is cleared when the pad is initialized and when the title reads through
scePadRead, and is dropped if the title does not read it within 100 ms, so an old press
cannot show up later as a fresh press. A latched L2 or R2 press also carries the analog
value it was published with, so the button bit and the analog value agree.
2026-10-17 16:08:10 +05:30
Aryan Sharma 5786a96283 fix(pad): report a press that ends before the next pad read
scePadReadState only returned the latest input, so a tap that began and ended between two reads was never reported. Latch the pressed buttons when input is published and fold them into the next ReadState.
2026-10-17 16:08:10 +05:30
Adrià 7b63ccbc93 Merge pull request #5970 from Ondra97/codex/fix-pad-command-unicode-path
fix(pad): read controller commands from Unicode paths
2026-10-17 00:15:35 +02:00
Adrià ffbc26c7d0 Merge pull request #5264 from hugodearaujo/fix/pad-vibration-mode-errors
fix(libScePad): check scePadSetVibrationMode's arguments in the console's order
2026-10-14 22:56:29 +02:00
Ondra97 6bddb1aa2c fix(pad): read controller commands from Unicode paths 2026-10-14 19:28:33 +02:00
Joel Fernandes dcfabcc579 feat(pad): bridge controller audio haptics to motor rumble 2026-10-14 13:45:00 +02:00
hugodearaujoandClaude Opus 5.5 b80fefd467 fix(libScePad): check scePadSetVibrationMode's arguments in the console's order
Measured on a PS5 (firmware 13.60): before scePadInit the call returns
NOT_INITIALIZED (0x80920005); after it, a mode of 0 or below returns
INVALID_ARG before the handle is checked, and a bad handle with a
higher mode returns INVALID_HANDLE.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 12:49:00 -03:00
p3nicillinandClaude Opus 5.5 1d115b8962 feat(libScePad): apply the angular velocity deadband
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-12 22:29:57 +01:00
fma-rc e0eef6c57f feat(pad): hold the sticks from the controller command file 2026-10-12 04:47:59 +02:00
Ori ShamirandClaude Opus 5.5 3f4438dcca fix(pad): keep partial L2/R2 values from a controller
An SDL controller sets the L2/R2 bit whenever its trigger axis is above
zero, and BuildData then reported 255 for any set bit, so a partly
pressed trigger read as fully pressed. Report the analog value whenever
there is one; 255 remains for an injected press and for a bit without
an analog value.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 17:52:56 +03:00
TibixDev 3a35841aad feat(pad): accept timed controller pulses from a local command file
Add an optional input helper for test runs without desktop input injection. Preserve physical input and release injected buttons automatically.

Validation: guest_pad tests and Python helper CLI smoke checks passed. Written with AI assistance.
2026-10-11 10:54:18 +02:00
TideOPL 39463913c7 fix(libScePad): fuse queued pad states at the read time
Keeping lastFuseTime at its maximum never let it recover from a process time that wrapped on the first call (fixed separately in #1501), so tilt correction stopped and guest_pad failed. Queued states keep their own timestamp; the orientation is fused once at the time of the read, as scePadReadState does.
2026-10-08 21:56:33 +01:00
TideOPLandClaude Opus 5.5 71e0f6428f style(libScePad): remove code comments
Per CONVENTIONS, code comments only mark technical debt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 11:06:09 +01:00
TideOPLandClaude Opus 5.5 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
SP4C3B4R-8andClaude Opus 5.5 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
OverkillLabsandClaude Sonnet 5 e532b19cee refactor(pad): trim comments and apply naming conventions
Bring the pad-gamepad-haptics diff in line with docs/dev/CONVENTIONS.md:
strip explanatory/rationale comments (struct layouts, algorithm notes,
rewired-NID rationale) down to code only, and rename the anonymous-
namespace helpers in PadState.cpp (Normalize/Fuse/EncodeZones/MaxOf/
ScaleStrength) to camelCase to match upstream's free-function style.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-29 04:24:39 +03:00
OverkillLabsandClaude Sonnet 5 4c349efe4f pad: motion sensor and haptics state/output plumbing
Add PadTouchPoint, motion-sensor fields, and a Mahony gyro/accel
orientation filter to PadInputState/PadState; add PadOutputState and
PadTriggerRequest plus Pad::SetVibration/SetVibrationMode/SetLightBar/
SetTriggerCommand/ResetOrientation/SetMotionEnabled and
PadFetchOutput_nid_postfix for pushing rumble, light bar, and adaptive
trigger requests out to the host pad. PadInfo/device-type constants
needed by the extended pad info NIDs are added to Pad.hpp.

Upstream's own PadInputState addition (analogButtonsL2/R2) is kept and
the new motion/touch fields are layered on top rather than replacing
it. Reported acceleration is converted from the internal m/s^2 fusion
scale back to g (rest = 1.0 on the "up" axis), matching upstream's
existing acceleration_y = 1.0f convention for a pad without sensors.

PadPublishInput_nid_postfix keeps upstream's change-detection (skip
the update, and the reported timestamp, when nothing changed), extended
to cover the new motion/touch/deviceKind fields so a pad with live
sensors still republishes continuously. Pad::ReadState still throws
when called before scePadInit, as upstream did.

The pad_dump.txt debug logger and an unreferenced mouse-emulated
touchpad helper are intentionally not ported: both were dead code,
never invoked, in the source they came from.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-28 13:42:51 +03:00
MartinCajiao 0644a8c38f feat(input): support SDL game controllers 2026-09-27 20:27:22 -05:00
boykopovar 05c8146744 refactor(pad): libScePad files structure refactor 2026-09-25 00:04:19 +03:00