Recently, I came across a pretty cool little device called the “Cronus controller adapter“. Basically, it’s a USB dongle that can be plugged into your Xbox 360 or Playstation 3, allowing you to use any controller you want no matter what console it was originally designed for as long as it works over USB. For example, using the Cronus adapter, you can use your Xbox 360 controller on your Playstation 3, your Playstation 3 controller on your Xbox 360, or your mouse and keyboard on both. Since I (used to) do a lot of computer vision programming (and have been looking for an excuse to get back into it), I felt like this little device would be a great way for me to create some new computer vision applications. Since I’ve already written several computer vision apps that can detect and track objects, I would like to test my skills at automating some video games by using OpenCV for the processing. Since the Cronus controller adapter allows you to feed commands to your Xbox 360 and Playstation 3 from basically any other device, I think that the Cronus adapter will be a great way for me to send commands to my Xbox 360 based on objects detected and tracked by OpenCV using my computer.
The Cronus controller adapter has a file that can be downloaded from the Cronus website (http://www.cronusdevice.com) called “gcdapi.dll” which is an API that you can use to communicate with the Cronus adapter using your programming language of choice. Since I am working with C#, I have to write a DLL wrapper so that I can invoke the API calls from my C# application. I have already started working on the wrapper and already have the basic commands supported (gcapi_IsConnected, gcapi_GetTimeVal, gcapi_CalcPressTime). As time permits, I will finish out all of the API’s commands. There are only about 6 commands, but I have only had about 5 minutes to work on the wrapper. Once I finish the wrapper and the example application, I will post both of them on this website for the rest of you to play with. I will also post the code I am working on that uses OpenCV for processing video input from the games and the Cronus device for sending commands to my Xbox 360. Currently, since it is probably the simplest game to automate using computer vision, I am creating a test app that can be used to automate Guitar Hero gameplay. Here’s a screenshot of the first test of the app where it identifies where the buttons are located on the screen and draws corresponding rectangles around them.
If you do not want to wait on me to finish my code, you can and should checkout the Gamepad Proxy website at http://www.gamepadproxy.com. There you will find all kinds of other useful tools and tutorials that teach you how to work with the Cronus device and how to work with the API. They even include a tool that helps automate Guitar Hero gameplay as well. Gamepad Proxy also has a link to download the Cronus Software Suite which you will need to define your controller settings when using the Cronus device.
For those of you that have already automated some video games, please share with us your success stories. For those of you that have not already automated any video games, please share with us your ideas for games you would like to see automated. Also, be sure to pickup your Cronus controller adapter from Amazon by clicking here.
Here is the Cronus controller adapter in action where I use it to automate Guitar Hero on my Xbox 360.
PayPal will open in a new tab.