Writing a sensor driver for the Wiimote on Windows 7
Ever since I saw Johnny Chung Lee's demos of the innovative ways in which the Nintendo Wiimote can be used as an input device for the PC, I've been hooked! The Wiimote is a surprisingly self-contained piece of hardware that is able to operate independently apart from the Wii console. Among other things, the Wiimote features a 3-axis accelerometer which is the primary enabler for letting you do things like wave a virtual tennis racquet or roll a bowling ball down the alley.
When Microsoft released Windows 7, one of the new things that they added to the system was a brand new platform for managing a certain class of hardware devices known as "sensors". Sensors are basically devices that, well, sense things! A GPS device for example is a sensor that can provide geographical location information. Another example is an ambient light sensor that lets the system know how bright the ambient light is. Now, these kinds of devices could be written and used even before Windows 7, just that now we have standard ways of exposing and consuming sensor data so that device vendors and application developers are able to communicate with each other in non-proprietary ways.
So, putting the two together, I figured it'd be kind of neat to come up with a sensor driver that exposed the accelerometer data from the Wiimote to the sensor platform. After some bit of head-scratching I managed to put something together. I've written up an article about it and posted it over at CodeProject.com. If you're interested, you can head over there and read all about it! Here's the link: