DsHidMini icon indicating copy to clipboard operation
DsHidMini copied to clipboard

Implement "turn off" behavior of the console on USB

Open nefarius opened this issue 1 month ago • 0 comments

When the "turn off controller" option is used on supported models while the DS3 is wired connected to the PS3, it can be "turned off", meaning it is still connected via USB and - possibly? - charging but the LEDs will be off and it will stop sending input reports. There appear to be two control requests involved sent by the PS3:

"LEDs off" packet

Frame 64977: 51 bytes on wire (408 bits), 51 bytes captured (408 bits)
USB Link Layer
USB URB
Setup Data
    bmRequestType: 0x21
    bRequest: 9
    wValue: 0x0201
    wIndex: 0 (0x0000)
    wLength: 48
    Data Fragment: 000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

The wValue and wLength hint about a zero'ed out output report sent over the control EP instead of INT OUT.

"turn off" packet

Frame 65136: 7 bytes on wire (56 bits), 7 bytes captured (56 bits)
USB Link Layer
USB URB
Setup Data
    bmRequestType: 0x21
    bRequest: 9
    wValue: 0x03f4
    wIndex: 0 (0x0000)
    wLength: 4
    Data Fragment: 420b0000

The wValue hint at a specific SET_REPORT/SET_FEATURE request, the payload appears to be the same across all models I could test. This request is not issued to models that do not report support for it to the console on initial handshake.

nefarius avatar Jun 01 '24 14:06 nefarius