It's free to join Gamasutra!|Have a question? Want to know who runs this site? Here you go.|Targeting the game development market with your product or service? Get info on advertising here.||For altering your contact information or changing email subscription preferences.
Registered members can log in here.Back to the home page.

Search articles, jobs, buyers guide, and more.

Gamasutra
June 20 2007

Where's the Wiimote? Using Kalman Filtering To Extract Accelerometer Data

arrowrightPage 1
arrowrightPage 2
arrowrightPage 3
arrowrightPage 4


Printer Friendly Version



Sign up for the Gamasutra Daily Newsletter!

Plastic Wax Animation : Senior Producer [05.15.08]
Blue Castle Games Inc : Technical Animator (Character Rigger) [05.15.08]
Spin Master Ltd. : LEAD / SENIOR SOFTWARE ENGINEER FOR THE FASTEST GROWING GAMING AND TOY COMPANY!!! [05.15.08]
Spin Master Ltd. : LEAD DESIGNER / ART DIRECTOR FOR THE FASTEST GROWING GAMING AND TOY COMPANY!!! [05.15.08]
Treyarch / Activision : In Game Lighter [05.15.08]
Snowblind Studios : Concept Artist [05.15.08]
MTV Networks : Director, Human Resources: Harmonix/MTV Networks [05.15.08]
Microsoft : Senior Games Producers [05.15.08]
Trion World Network Inc. : Senior Server Engineer [05.15.08]
Mock Science Inc : Artist [05.15.08]
Mock Science Inc : Software Engineer [05.15.08]
Vicious Cycle Software, Inc : Gameplay Programmers [05.15.08]
Vicious Cycle Software, Inc : Sound Designer [05.15.08]
Helixe Studios : Project Manager [05.15.08]
NCsoft : Database Programmer [05.14.08]

View All    Post A Job

Post Resume


Upcoming Events:
CoGames 2008: The 1st International Workshop on Collaborative Games
Irvine, United States
05.19.08

Vancouver International Games Summit
Vancouver, Canada
05.21.08

Game Institute Challenge #7
, United States
05.30.08

DevStation
, United Kingdom
06.10.08

Interfaces Conference
Troy, United States
06.14.08

Submit Event

View All


Where's the Wiimote? Using Kalman Filtering To Extract Accelerometer Data

(Page 1/4)
Next arrow


There are two issues that I have noticed while playing Wii Sports. One involves bowling and one involves golf. In the bowling game I have been soundly defeated by a 7 year old. While that in and of itself is not an issue, he usually beats me by swinging his arm in a random convulsive fashion behind his back. Last time I checked, his high score was 217. The issue with the golf game is when the golf club swings backwards with respect to the motion of the Wiimote. This happens most often while putting.

These kind of issues hint at large errors interpreting the outputs of the accelerometer, estimating the Wiimote orientation, or perhaps a low battery in the Wiimote. Or all three. This article shows a useful way to improve the outputs of the accelerometers. A more complete version of this method can be used to improve the estimate of the orientation of the Wiimote. Sadly this method will not help too much with a low battery.

Inexpensive accelerometers are known for fuzzy input. An error of 5% in acceleration is enough to throw position and velocity estimates off quickly. I wager to guess that the accelerometers in the Wiimote are neither the most expensive nor the most accurate versions available. But can one get anything useful out of cheap accelerometers? Absolutely. Some good information is already pulled from the accelerometer in the Wii Sports and the Wii Play games. But can more accurate information be extracted? Definitely. But how can it be done?

One way to eke out better information from accelerometers is to use a complicated form of time dependent probability theory. This is known as Kalman Filtering. Kalman Filtering is commonly used in the navigation systems of airplanes, where knowing the location accurately, and precisely if possible, is important. Versions of the Kalman Filter are also used to estimate spacecraft and satellite trajectories.

The description, justification, and general use of the Kalman Filter is challenging, so I will merely state the results that are relevant and then go through an example. There are a few good, and more so-so books and web pages on Kalman Filtering. I list in the references only what I consider good pages, so please realize that it is a subjective list. Good luck with them [1,2,3,4]. Familiarity with differential equations, some statistics, and matrix mechanics is assumed throughout this article.

After the basic Kalman Filter equations, this article discusses a 'simple' Kalman Filter example. The 'simple' example is a one dimensional motion of an accelerometer and with ideally fairly accurate position measurements. I use the word simple only because this is as uncomplicated as Kalman Filtering gets. It does not describe the example as something that is necessarily easily understood. This example has nothing in it that explains how to extract the orientation of the Wiimote, that is the next level up in complexity of a Kalman Filter design. This example is perfect for estimating the motion of an object in one dimension, like the motion of a pool cue before it strikes the cue ball.


(Page 1/4)
Next arrow






join | contact us | advertise | write | my profile
news | features | contract work | jobs | resumes | education | product guide | store