Go Down

Topic: Accelerometer MMA3761 (Read 2259 times) previous topic - next topic


I have found in the forum the scetch included below , but gets the following error :
"AcceleroMMA7361 does not name a type"
This inspite of having installed the correponding library ...what´s wrong ??

Code: [Select]

#include <AcceleroMMA7361.h>
AcceleroMMA7361 accelero;
int x;
int y;
int z;
void setup()
accelero.begin(13, 12, 11, 10, A0, A1, A2);
accelero.setARefVoltage(5); //sets the AREF voltage to 3.3V
accelero.setSensitivity(HIGH); //sets the sensitivity to +/-6G
// accelero.calibrate();
void loop()
// x = accelero.getXAccel();
y = accelero.getYAccel();
// z = accelero.getZAccel();

// Serial.print("\nx: ");
// Serial.print(x);
Serial.print(" \ty: ");
delay(1000); //make it readable


Generally, it either means you haven't restarted the IDE since you installed the library, or you installed it in the wrong place.


Effectively , the library was installed under Arduino 1.03 instead of 1.05...

thanks for your answer  :)

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131