Reverse Engineering the XUSB Protocol Research

Started by
3 comments, last by philm002 5 years, 7 months ago

Hello all,

I was not sure where to place this so I decided to place this in the general forum. Please note, that I have not developed anything at this time. I am currently doing some research and scouting.

I have been considering to develop a game controller. I was thinking that it would be nice if the controller registered as a Xbox 360 controller when connected to a windows PC. I could go out and get an actual 360 controller but I am redesigning the case and the electronics. So, I was thinking about utilizing the XUSB protocol.

After doing some research, it appears that I am not able to find information regarding this protocol. I am starting to have concerns that the XUSB is proprietary to Microsoft. Is this the case? Are approved Microsoft accessories only allowed to use the XUSB? If so, then how do I become "approved" so that I can develop XUSB controllers?

If this is not the case, then where would I be able to find documentation on XUSB communications?Or would i be able to use a USB Sniffer and basically reverse engineer the communications protocol between the controller and the PC?

Note:

Yes, I am aware that windows supports the DirectInput method. This is my fall back in the event that I can't get the XUSB protocol to move forward.

Thank you

Advertisement

You should start understanding the USB standard and usage on certain platforms before start developing something. I found this on a really quick google search and it mentions

Quote

The driver for the Xbox 360 Common Controller class (XUSB) on Windows implements the kernel-mode interface for the XINPUT DLL

But as I worked a lot using the HID interface myself, anything you need to provide is the protocol pattern for your device so HID API understands what states do indicate input kind and data.

If your device should be recognized just as an XBox controller, you can handle this by it's vendor and product IDs. Those are used to identify devices in the OS

Hello Shaarigan,
Thank you for your reply. I appreciate your feedback. I have been looking into this for a few days now. I am aware of the VID and PID requirement. I would like the controller to not just be viewed as an Xbox 360 controller but to function as one too. I am not worried about the functioning part. I am only concerned about the communications aspect.So far, the following site is the best resource that I have found regarding XUSB implementation on the 360 controller:

https://computerquip.wordpress.com/2013/12/16/i-hate-microsoft-but-for-the-better-good/

After doing research for a few days, my understanding is that the Xbox 360 controller doesn't quite function as a HID device. Or the controller does not fully implement the HID standard. which, the above site confirms:

"So, I’ve come to learn the controller is only partially HID compliant. On Windows, it sits behind a userspace driver formally known as XInput which sits in front of a kernel-driver called XUSB. We can think of XInput of a quasi-HID driver that deals with quirks from Microsoft. Most likely, the XInput driver is a filter driver that uses HID and parses non-HID packets otherwise. The devices are tailored to the XInput interface rather than HID."

It sounds to me that the XUSB is a propriety communication standard Microsoft developed for the 360 controller. In the event that this is not the case, I have been looking to see if there is documentation describing the communication protocol so that I know what byte values to send, how to send the values, the formatting of the values, etc. Along with what the VID and PID should be so that the computer can register the device as a XUSB device.

The resource that I posted above only stratches the surface on the contents of the data packets that the controller uses to communicate. I am hoping to find something more complete

BTW: This is for a wired controller.

Has anyone every worked with XUSB? Am I able to get a license with Microsoft to implement a XUSB device?

This topic is closed to new replies.

Advertisement