Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some API and project structure refactoring #8

Open
1 of 9 tasks
dogtopus opened this issue Feb 16, 2020 · 0 comments
Open
1 of 9 tasks

Some API and project structure refactoring #8

dogtopus opened this issue Feb 16, 2020 · 0 comments
Labels
api API related

Comments

@dogtopus
Copy link
Member

dogtopus commented Feb 16, 2020

  • Make auth-related stuff controller specific since they are rarely reused due to the 3 big companies does things a lot differently (PS4: RSA-2048 based authentication, Xbox: (in house?) challenge-response, Switch: None)
  • Convert some of the Transport CRTP mixins back to object-based
  • One more layer of HID transport abstraction. Moving platform/link dependent Transport classes away from core code (e.g. rds4::platform) and base HID transport to rds4::api so e.g PS3/pokken controller can use the same HID transport as PS4. New transports like XInput should follow the same pattern. (Refer to USBHID spec, TinyUSB and libusbgx for roughly what to expect.)
    • Feature callbacks
    • Get/set HID features/descriptor
    • Endpoint TX
    • Endpoint RX
  • (Somewhat redundant but more elaborated than above) Change the transport to be more callback-based ("EndpointResponder"?)
    • Move unrelated handling code (e.g. feature management, auth handling, etc.) to Controller/separate class maybe as a callback (like onReport(report_type, report_id) then read out the actual payload via recv()). This will be an object-based callback rather than functional.
@dogtopus dogtopus added the api API related label Feb 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api API related
Projects
None yet
Development

No branches or pull requests

1 participant