Windows API for the PS5 DualSense controller. Written in C++ for C++
First Release coming soon!
Reading the input state from the controller using USB. DONE!Reading input via bluetooth. DONE!Writing Output state to the controller using USB. DONE!Controlling and reading the adaptive triggers.DONE!Writing Output state via bluetooth.DONE!- Addition input / output parameters. Work in progress
- Calibrating the gyroscope Work in progress
- Documenting the API Work in progress
- Updating the github repo and publish release
First preview should be released before 28.11.2020 (The hard work is done - The USB and BT protocol is, at least partially, reverse engineered)
- Reading all buttons and analog values (triggers and sticks) which are on the controller
- Reading the two finger touch positions
- Reading the accelerometer
- Reading the gyroscope (Currently only raw / uncalibrated values)
- Reading the connection state of the headphone jack
- Setting the rumble motors speed
- Setting various effects to the force feedback triggers
- Retrieving force feedback triggers feedback
- controlling the RGB-Leds, Microphone Led and User Leds
Fully working over USB and Bluetooth!
- Using the haptic feedback
- Internal speaker and mic
- When the controller being shut down while connected via Bluetooth (Holding the PS button). The lib will encounter a dead lock within
getDeviceInputState(...)
call. The function will return as soon as the controller is getting reconnected. Not encountering over USB, over USB the expectedDS5W_E_DEVICE_REMOVED
error is returned.
I have partially used the following sources to implement the functionality:
- The GitHub community on this project and Ryochan7/DS4Windows#1545
- https://gist.github.com/dogtopus/894da226d73afb3bdd195df41b3a26aa
- https://gist.github.com/Ryochan7/ef8fabae34c0d8b30e2ab057f3e6e039
- https://gist.github.com/Ryochan7/91a9759deb5dff3096fc5afd50ba19e2
- https://github.com/Ryochan7/DS4Windows/tree/dualsense-integration (Copyright (c) 2019 Travis Nickles - MIT License)
- https://www.reddit.com/r/gamedev/comments/jumvi5/dualsense_haptics_leds_and_more_hid_output_report/