Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] MPU6050 returns large gyroscope readings on power up

Status
Not open for further replies.

ernpao

Full Member level 1
Full Member level 1
Joined
Sep 16, 2010
Messages
98
Helped
26
Reputation
52
Reaction score
22
Trophy points
1,298
Activity points
2,043
I am using an mpu6050 accelerometer+gyroscope sensor with a pic32 and I am getting large readings from the gyroscope whenever I plug in the power to my system.

The sensor readings are in 16 bit signed format and I get readings towards the far ends of the range (around -20k or 20k) when my device is static. The gyro readings seem to fluctuate accordingly when the system moves, just that the gyro returns these large values when it is supposed to be returning zero.

I would also like to add that this only happens when I disconnect and reconnect power. Whenever I reprogram my mcu, the gyro readings are correct, even when I reset the mcu. The accelerometer readings i obtain are correct, and only the gyro behaves like this. I have also tried my system with another module and it behaves the same.

Any ideas on what may be causing this? Many thanks.
 

I think I have partially solved my problem. I'm actually using the 10 DOF IMU sensor from Waveshare (as well as their C code for the module).

https://www.amazon.com/Waveshare-HMC5883L-Gyroscope-Accelerometer-Barometric/dp/B00NYYPGAS

The initialization sequence for the sensors includes a small routine for obtaining offsets for the gyroscope readings. These offset values are then subtracted from future readings. I temporarily set the offsets to 0 to prevent anything from being subtracted to sensor readings.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top