note: due to the discontinuation of the MMA7260QT chip, we redesigned a new version of the 3-axis accelerometer.
The 3-axis accelerometer module carries an MMA7260QT chip from Freescale. The MMA7260QT operates in 4 selectable sensitivity modes, +/- 1.5g, 2g, 4g, and 6g. It also offers a 1-pole low pass filter as well as temperature compensation. Furthermore, the MMA7260QT has a Sleep Mode function, ideal for use in portable, battery powered devices.
The accelerometer operates between 2.2 and 3.6V. Because of the low-voltage chips that have been damaged by 5V standard Arduino outputs, this board is equipped with built-in 5V tolerance protection.
The 3-axis accelerometer module comes as a kit with two 4-pin male headers, and is especially handy for determining sensitive changes in orientation.
Link to the cheatsheet as a PDF...
void setup() {
Serial.begin(9600);
}
int x0;
int y0;
int z0;
void loop () {
x0 = analogRead(0);
y0 = analogRead(1);
z0 = analogRead(2);
Serial.print(x0);
delay(5);
Serial.print(" : ");
delay(5);
Serial.print(y0);
delay(5);
Serial.print(" : ");
delay(5);
Serial.println(z0);
delay(5);
}