Files
AnyPS5/docs/dev/debt/libSceKeyboard.md
T
Dean 78976e2657 Merge pull request #15924 from zaryabzip/fix/keyboard-open-user-codes
fix(libSceKeyboard): return the console's user codes from sceKeyboardOpen
2026-11-08 17:54:01 +13:00

4.7 KiB

libSceKeyboard technical debt

Functional

  • sceKeyboardDebugGetDeviceId - validation and the -1 sentinel follow the retail 11.00 dump decode: not-initialized, null output, -1 written up front, no device match returns INVALID_HANDLE, a match writes the device record's id. The decode binds the handle to a live device record, so an unopened or detached handle is the no-match case; whether firmware also has the mouse-style empty-slot success path is not decoded. The reported device id is a model constant for the single emulated device.
  • sceDbgKeyboardReadState - the retail 11.00 dump decode recovers its two-argument signature and shows it calls sceKeyboardReadState's shared path with a third argument of 1 instead of 0; the flag's semantic effect inside that path is not decoded, so the export stays unimplemented until the flag is understood.
  • sceKeyboardGetKey2Char: initialization, output length and reserved bytes remain unverified on a console; unconverted keys retain the host's length of 0. One title (PPSA15246) disassembled for this entry calls it after clearing the first 20 bytes of its output buffer (16-byte store 0x69942d, 32-bit store 0x699435; no size argument), uses a character only when the result is 0 and the first output byte is nonzero, and then reads the 16-bit value at offset 8. Which other output fields it reads and what its other arguments mean are not shown.
  • sceKeyboardOpen: a PS5 on system software 12.40 returned 0x809B0001 for user -1 and 0x809B0081 for user 0, with type and index 0 after sceKeyboardInit. Every other id that is not a registered user gets 0x809B0081 too, and other negative ids keep INVALID_ARG; neither was probed, nor was the order of the user check against a bad type or index.

Unknown function info