Questions about Modern Device and JeeLabs Sensors
- Posts: 15
- Joined: Thu Jul 17, 2008 7:59 pm
3-axis accererometer MMA7361
What are the final "units of measurement" of the MMA7361 in the demo program?
I am just a novice.
tiltx = atan2( sqrt((y*y) + (z*z)), x);
tilty = atan2( sqrt((x*x) + (z*z)), y);
tiltz = atan2( sqrt((y*y) + (x*x)), z);
- Site Admin
- Posts: 734
- Joined: Mon May 12, 2008 4:19 pm
atan2 (and all the trig functions) return numbers in radians.
there are 2 pi radians in a circle so your data probably goes from either 3.14 to -3.14 or 0 to 6.28
Does that synch with values you're getting?
You have to be a math head (not me!) to love radians, and then it all makes perfect sense, according to my math teacher buddy.
Hope that helps,
ps When calibrating the accelerometer with the sketch it is important to be as gentle as possible in the calibration phase of things, to not add extra acceleration to the mix.