9DOF Sensor Stick

Hello Everyone

I am new to this so take it easy on me.

I have a 9DOF Sensor Stick with an Accelerometer(ADXL345) , Magnetometer(HMC5883L) and Gyroscope(ITG3200).

I wrote a code that would read the raw data out of the 9DOF Sensor Stick.

Now i wanna use this data in order to track the Orientation in space.

Can anyone provide me with references how to do so ???

I need to do something like this

http://www.youtube.com/watch?v=P8PzENkOX3A

I need to know what should i do with the raw data i have …

Thanks

Look up FreeIMU, I think it works with that stick.

i need to understand the theory behind it … any suggestions

Try this website:

http://www.electronic-engineering.ch/study/ins/ins.html