Pages: [1]   Go Down
Author Topic: mma7260q?  (Read 490 times)
0 Members and 1 Guest are viewing this topic.
INDONESIA
Offline Offline
Newbie
*
Karma: 0
Posts: 15
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

how to calibrate tilt accelerometer mma7260q???  smiley
Logged

Portugal
Offline Offline
God Member
*****
Karma: 5
Posts: 962
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Another account?
Read it some 64 times, avaerage, X and Y should read 0, so calculate the offset, and Y should read 1G, consult the datasheet to see what value means 1g, then its done.
Logged

INDONESIA
Offline Offline
Newbie
*
Karma: 0
Posts: 15
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i have read the code from this site
http://rubenlaguna.com/wp/2008/11/03/arduino-tilt-sensor-using-mma7260q/
but it just 90 degrees, can i measure the tilt until 360 degrees??
I use arduino mega 2560.
 smiley
Logged

Portugal
Offline Offline
God Member
*****
Karma: 5
Posts: 962
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You cant, because when you tilt more than 90 degrees you are in fact inversing the chip, so your gravity values become negative, so it becomes the same tilt, but you just have the board/acc inverted.
Logged

INDONESIA
Offline Offline
Newbie
*
Karma: 0
Posts: 15
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You cant, because when you tilt more than 90 degrees you are in fact inversing the chip, so your gravity values become negative, so it becomes the same tilt, but you just have the board/acc inverted.
so what can i do to measure it become 360 degrees?
is this accelerometer only measure 90 degrees?
 smiley
Logged

Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 238
Posts: 24322
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
and Y should read 1G
sp. "Z"
Logged

"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

Portugal
Offline Offline
God Member
*****
Karma: 5
Posts: 962
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes Z, thanks for the correction.

The accel can read 360 for sure, but its a matter of checking if Z is +1g or -1g, the rest is just the typical trigonometry .
Logged

Pages: [1]   Go Up
Jump to: