The two faults that matter on a used DualShock 4
This is the oldest pad on the site and by now most of them have seen years of use, so the interesting question is not "do the buttons work" — they nearly always do — but whether the analog parts have aged. Two failures dominate, and both pass a test that only shows lights.
Sticks that no longer rest at zero. Put the pad down, take your hands off, and run the drift meter for a minute. It reports the largest resting offset each stick produced, along with the share of samples that read exactly zero — the figure that tells you whether a clean result is real or just a dead zone applied upstream. Triggers that no longer return. With your hands off, L2 and R2 must read exactly 0.000. A trigger resting at 0.02 is below the threshold that flips the pressed flag, so it looks fine everywhere except in a game that reads the analog value.
What Chromium reads each DualShock 4 button from
| Canonical index | Button on the pad | Read from | Arrives as |
|---|---|---|---|
| buttons[0] | Cross ✕ | buttons[1] | a raw button |
| buttons[1] | Circle ○ | buttons[2] | a raw button |
| buttons[2] | Square □ | buttons[0] | a raw button |
| buttons[3] | Triangle △ | buttons[3] | a raw button |
| buttons[4] | L1 | buttons[4] | a raw button |
| buttons[5] | R1 | buttons[5] | a raw button |
| buttons[6] | L2 | AxisToButton(axes[3]) | an axis, converted |
| buttons[7] | R2 | AxisToButton(axes[4]) | an axis, converted |
| buttons[8] | Share | buttons[8] | a raw button |
| buttons[9] | Options | buttons[9] | a raw button |
| buttons[10] | L3 | buttons[10] | a raw button |
| buttons[11] | R3 | buttons[11] | a raw button |
| buttons[16] | PS button | buttons[12] | a raw button |
| buttons[17] | beyond the Standard Gamepad | buttons[13] | Tagged GamepadButtonType::kTrackpad — the touchpad click, not the touch surface. |
DpadFromAxis(axes[9]) fills indices 12–15 from a single hat axis.
The triggers are the row to look at. They are not read from raw buttons at all — they are converted from axes, which is why they carry a continuous value while every other entry in the array is effectively on or off. The face buttons are reordered rather than passed through, because the raw report lists them in Sony's order and the canonical layout wants them in geometric order.
The DualShock 4 and the DualSense are the same device to a browser
Put the two mapper tables side by side and every canonical button is read from the
same raw source, position for position — this page checks that programmatically when
the site is built, so you never have to compare by eye. At the label level the two
pads differ at exactly 1 of the 17 canonical indices:
buttons[8], the left button in center cluster,
which Sony printed as Share on the DualShock 4 and
renamed to Create on the DualSense. The other
16 indices carry identical labels.
The practical consequence is pleasant: anything you write against a DualShock 4's indices runs unchanged on a DualSense, and a binding screen built for one needs no work for the other beyond the printed name of a single button. It also means a diagnosis made here transfers — if you are comparing an old pad against a new one, you are comparing like with like. The PS5 DualSense test covers what the newer pad adds that a browser still cannot reach.
Bluetooth, USB, and the pads that are not really DualShocks
Chromium routes controllers to a mapping by product id, and it carries entries for the
original DualShock 4, the PS4 Slim revision and the USB receiver. A genuine pad on any of
those paths reports mapping === "standard" and behaves as this page
describes. A third-party PS4-style controller very often does not: it reports the empty
string, its buttons arrive in its own order, and no published index table applies —
including this one. The device panel makes this a one-second check, and it is worth doing
before you conclude that a button is in the wrong place.
The same caution applies to adapters. What the browser identifies is the adapter, not the controller behind it, so two adapters for the same DualShock 4 can produce two different orderings. If you use one, run the live panel once and write down what each button actually reports; that list beats any chart.
Run the list backwards
On a pad this old the usual order is the wrong order. Start with the two checks that actually fail, and only then work back to the buttons, which almost always still work.
- Sticks at rest first. Hands off for a minute on the drift meter, and read the zero-sample share as well as the offset.
- Triggers at rest second. L2 and R2 must read exactly 0.000 with nothing touching them.
- Then L2 and R2 under load, sweeping smoothly from 0.000 to 1.000; L1 and R1 digital.
- Touchpad click — index 17, in the extras row — plus L3 and R3 by clicking each stick.
- Share, Options and the PS button; then the d-pad, indices 12 to 15.
- Cross, Circle, Square, Triangle last — canonical indices 0 to 3, around the cluster.
- Vibration, from the device panel.