Sony DualSense

= HID Interface =

Offical Interface
The official interface for the DualSense controller is not public and likely confidential. This static library is likely a descendant of the original libPad library used for the DualShock 4 controller.

Limitations

 * Three trigger effects (and reset)
 * USB only, no Bluetooth support

Likely Interface
Apple's  interface reveals some aspects of Sony's API. We can assume the following:
 * The controller is handled through an instance, be it class or indexed static, which stores at least some of the state data written to the controller. This can be determined because while there is no way to read the full parameters of the current trigger effect back from the controller the API somehow knows not to send the same parameters to the controller again when provided with the same input.
 * The names of effects can be determined as follows:
 * Valid effects with their custom construct enumeration values that match  from the input:
 * off = 0
 * feedback = 1
 * weapon = 2
 * vibration = 3
 * Valid trigger statuses are derived from the combination of  and   that do not match   from the input report:
 * unknown = -1, adaptive trigger status cannot be determined.
 * feedbackNoLoad = 0, adaptive trigger is in feedback mode, and a resistive load has not been applied yet.
 * feedbackLoadApplied = 1, adaptive trigger is in feedback mode, and a resistive load is applied.
 * weaponReady = 2, adaptive trigger is in weapon mode, the trigger is ready to fire, and a resistive load has not been applied yet.
 * weaponFiring = 3, adaptive trigger is in weapon mode, the trigger is firing, and a resistive load is currently being applied.
 * weaponFired = 4, adaptive trigger is in weapon mode, the trigger has fired, and a resistive load is no longer being applied.
 * vibrationNotVibrating = 5, adaptive trigger is in vibration mode, and the trigger is not vibrating.
 * vibrationIsVibrating = 6, adaptive trigger is in vibration mode, and the trigger is currently vibrating.

Hardware Revisions
There are at this point at least 3 hardware revisions that have been seen in the wild. The first is the original hardware, or Mass Production model, and the second and third are Revision 1 models. When processing the `ReportFeatureInVersion` structure, note the HardwareInfo's Generation and Trial values.

Generation 0x03, Trial 0x13
This hardware revision operates as expected.

Generation 0x04, Trial 0x13/0x14
This hardware revision has made a 'breaking change' to the player LED handling. Now the two pairs PlayerLight1+PlayerLight5 and PlayerLight2+PlayerLight4 are wired together. This change makes it impossible to separately control these LEDs but does not disrupt the intended player light configurations. This change was likely made to save 2 lines on the cable that attaches the touch board to the main board but this is not confirmed. If interfacing with a controller of this hardware revision, note that only symmetrical player LED configurations are possible.