DualSense
Rust programmatic wrapper over HID messages sent and received by the PS5 DualSense controller. Allows support for simultaneous key presses or combos that require consecutive presses in a given time interval(wip).
Usage
Read
Add callback functions to detect when properties change.
Log details about the left and right sticks' positions:
use DualSense;
Write
Output values are stored in an internal cache and will be sent in the following read/write cycle. Packets will not be sent if nothing changed.
use DualSense;
Examples
Try examples for:
- log_all -> log values for all buttons, analog sticks and touchpad
- sensors -> log values for the gyroscope and accelerometer
- triggers -> log values for the triggers and change their modes
Roadmap
Currently the following features are of priority:
- bluetooth support
- CRC creation and validation
- charging status
- improve API:
- make callbacks return structs with utilitary methods
- fix borrow issue when trying to update local variable in callback
- combos:
- add the possibility to detect when multiple keys are pressed in a time frame