So everything shows just 0 but the temperature which is corrected by the constand value 36.53
Which also is a zero reading for the temperature.
How did you wire the module to the Arduino? Post a wiring diagram or describe every wire you connected to the MPU-6050 breakout. Maybe there's a line floating that should be connected.
I wired everything as shon in every tutorial I've found ^^.
First of all.. I bougth an original Arduino Uno R3... so no clone, and the sensor as shown in my first post.
The wiring:
MPU6050 GY-521 | Arduino Uno R3
VCC -------------------->----------------- 5V
GND -------------------->----------------- GND
SCL --------------------->----------------- A5
SDA --------------------->----------------- A4
This was my basic wiring for the raw-data demo.
BTW... I now bougth another MPU6050 for comparison from another company and this one runs without any error in the same wiring.
For me it's just the point of understanding what's going wrong with this sensor unit to gain a little more knowledge.
Same problem here, hope someone can help me!
I have chinese mpu6050 and arduino nano.
I have connected: GND to GND SCL to A5 SDA to A4
When I connected VCC to 5V I had this running the i2c scanner code:
I2C Scanner
Scanning...
Unknow error at address 0x02
I2C device found at address 0x68 !
done
When I connected VCC to 3.3 instead I got this:
I2C Scanner
Scanning...
I2C device found at address 0x68 !
done
Wake up of MPU failed: 2
Setting register number failed: 2
Read registers not complete, read 0 bytes.
AcX = -1 | AcY = -1 | AcZ = -1 | Tmp = 36.53 | GyX = -1 | GyY = -1 | GyZ = -1
EDIT:
I solved! I have connected GND to the other GND pin (the one between the RST and VIN pin) on arduino nano and now it is working. What is the difference between the 2 pins?
You should use a level converter for this module as the GY-521 is running on 3V3 and the UNO is running on 5V. The Wire library activates the internal pullups for SDA and SCL so the MPU-6050 gets a to high voltage on these lines. It might work for some time but it also might destroy your chip.
I have tried 3 codes so far. When i try the above code by pylon what i get in Serial Monitor is a blank screen and nothing. I have also tried the code by Jeff Rowberg and when i see the Serial Monitor the only thing i see is "Initializing I2C devices..." and it is stuck there for ever. I even tried running I2C Scanners code, what i see on Serial Monitor is "I2C Scanner
Scanning..." and only that. I have not altered any code or anything.
@HarzSR: Did you read my last reply? You read that a level converter should be used with that model but connect it directly to the UNO? It might be worse in your case because your sensor already died from the higher voltage.