Page 1 of 1

3-axis accererometer MMA7361

Posted: Thu Aug 15, 2013 5:47 pm
by mdAndy
@Paul Badger

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);

Re: 3-axis accererometer MMA7361

Posted: Fri Aug 16, 2013 1:00 pm
by oz
mdAndy,

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,

Paul

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.