Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Steam controller handling
Rust library to work with the Steam controller.
Protocol
There's a script in support/ to help out with reversing the protocol, the
following is what I know so far.
Header
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| | Status |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Status
It's a 16 bit flag, the values below are in big endian.
0x0301means the device is sending power events.0x040bmeans the device is idle.0x013cmeans the device is sending input.
Power
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Event | Garbage? | |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Event
It's an unsigned char.
0x01means power off.0x02means power on.
Garbage?
Seems to be a monotonically increasing value after the controller has been turned on.
Can't find a pattern in it so far.
Idle
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Sequence |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Garbage? |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Sequence
It's a little endian unsigned int, it's increased by one with every read.
Input
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Sequence |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Buttons | Left Trigger |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Right Trigger | |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Left Pad X | Left Pad Y |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Right Pad X | Right Pad Y |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| | |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Orientation Roll | Orientation Yaw |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Orientation Pitch | Acceleration Roll |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Acceleration Yaw | Acceleration Pitch |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Unknown |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Unknown |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Sequence
It's a little endian unsigned int, it's increased by one with every read.
Buttons
It's a 24 bit set, the values below are in big endian.
0b100000000000000000000000the A button has been pressed.0b001000000000000000000000the B button has been pressed.0b010000000000000000000000the X button has been pressed.0b000100000000000000000000the Y button has been pressed.0b000000000000000000000010the pad is being pressed.0b000000000000000000001000the pad is being touched.0b000000000000000001000000the analog has been pressed.0b000000000000100000000000the pad down side has been pressed.0b000000000000010000000000the pad left side has been pressed.0b000000000000001000000000the pad right side has been pressed.0b000000000000000100000000the pad up side has been pressed.0b000000000000000000000100the trackpad has been pressed.0b000000000000000000010000the trackpad has been touched.0b000000000001000000000000the back button has been pressed.0b000000000010000000000000the home button has been pressed.0b000000000100000000000000the forward button has been pressed.0b000010000000000000000000the left bumper has been pressed.0b000001000000000000000000the right bumper has been pressed.0b00000001000000000000000the left grip has been pressed.0b00000000000000000000001the right grip has been pressed.0b000000100000000000000000the left trigger has been fully pressed.0b000000010000000000000000the right trigger has been fully pressed.
Left trigger
It's an unsigned byte for the pressure applied to the trigger.
Right trigger
It's an unsigned byte for the pressure applied to the trigger.
Left Pad X
It's a little endian signed short.
Left Pad Y
It's a little endian signed short.
Right Pad X
It's a little endian signed short.
Right Pad Y
It's a little endian signed short.
Orientation Roll
It's a little endian signed short.
Orientation Yawl
It's a little endian signed short.
Orientation Pitch
It's a little endian signed short.
Acceleration Roll
It's a little endian signed short.
Acceleration Yaw
It's a little endian signed short.
Acceleration Pitch
It's a little endian signed short.