Skip to content

feat(ds5): calibrated Wave haptics, 0-100% Strength, debug level counters - #25

Merged
ripps818 merged 7 commits into
mainfrom
feat/ds5-wave-scale
Oct 14, 2026
Merged

ripps818 merged 7 commits into
mainfrom
feat/ds5-wave-scale

Conversation

@ripps818

Copy link
Copy Markdown
Owner

What

  • Wave Strength is 0-100% (protocol v30, field 30, blob p[197]). In Wave, 100% is 2x the game's haptic track and Auto is 25% (0.5x). In Tone, Split and Rumble, 100% is the old 500%. The gain moves to a config tail byte, so a value saved on the old 10-500% scale loads as Auto.
  • Wave expander raises the gain with the track's own level (1x below 6% of full scale, a 0.35 power law up to 2x).
  • Wave gate drops from 100 to 16 so quiet menu effects play.
  • Soft boost defaults to off on the DualSense (the Switch keeps Gentle); a saved setting is kept. The Grip limiter stays 85.
  • Debug build only: the PCM counters frame (0xB1) gains the ungated haptic and speaker channel levels, and the capture ring logs changes in the game's 0x02 output reports (valid flags + motor bytes) and no longer logs the 130/s grip PCM frames.

How it was calibrated

One Black Flag Resynced clip, recorded from the puck's PipeWire monitor and played at the same time to the puck and a real DualSense, with both controllers' accelerometers read at the same time (both on the same desk):

puck / real Auto (0.5x) 100% (2x)
quiet effects 0.64-1.01 1.7-2.3
mid and sustained hits 0.54-0.75 1.0-1.3
whole clip 0.72 1.14

Notes in docs/DUALSENSE_HAPTICS.md. Held in the hand, the two were "pretty close"; the DualSense feels deeper, which is the actuators, not the signal.

Not covered

  • One game, one clip: Auto should get a check in a second game.
  • A frequency mismatch remains (grips about 2x the real pad at 90-140 Hz, weaker below 60 Hz); the 250 Hz IMUs can't measure it above ~100 Hz.
  • Not run locally: the panel jsdom tests. Host tests and make check pass; standard and debug builds both compile.

🤖 Generated with Claude Code

ripps818 and others added 7 commits October 14, 2026 02:09
…bug build

The 0xB1 frame gains the ungated haptic and speaker channel levels, so
audio with silent haptic channels shows apart from no audio. The capture
ring logs each change in a 0x02 report's valid flags and motor bytes,
and no longer logs grip PCM frames, which have their own counters.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
0-100% of the panel gain now spans 0-8x the haptic channels, and the
Wave gate drops to 16 so quiet menu effects play. Black Flag mixes its
haptics at 0.2-6% of full scale, which the grips barely play at 1:1.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The panel's DualSense Strength slider becomes 0-100% (protocol v30). In
Wave, 100% is 8x the game's haptic track, linear, and Auto is 50% (4x):
Black Flag mixes its track at 0.2-6% of full scale, which the grips
barely play at 1:1. In the other styles 100% is the old 500%. The gain
moves to a config tail byte, so a saved 10-500% value loads as Auto.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Calibrated on both controllers' accelerometers with one Black Flag clip
played to the puck and a real DualSense together: mid-level effects
match at 0.5x, now Auto (25%), and the clip's hits reach the grips'
ceiling at 2x, now 100%.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Against a real DualSense on both controllers' accelerometers, quiet
effects matched at 0.5x while louder ones needed about 0.75x. The Wave
path now multiplies the gain by 1x below 6% of full scale, rising on a
0.35 power law of the track's own level to 2x.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The Wave path now matches a real DualSense without it (Auto 25%, the
expander, limiter 85), so only the Switch keeps the gentle boost as its
default. A saved setting is kept.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@ripps818
ripps818 merged commit 30f4ce1 into main Oct 14, 2026
3 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.

1 participant