MPU6050_light icon indicating copy to clipboard operation
MPU6050_light copied to clipboard

GetAngle works fine alone but "hangs" up when embedded in other sketch

Open drbrodie opened this issue 2 years ago • 2 comments

Using the GetAngle code I have no problems but when the same code is embedded in a much larger sketch which calls mpu.update about every 12 ms the program freezes after a minute +-. Does mpu.update need to be called more frequently? Can you suggest anything else which might be happening?

drbrodie avatar Dec 17 '21 14:12 drbrodie

Dear drbrodie,

Are the angular values diverging? It could be a memory overflow. Clean calibration might be needed to avoid gyroscopic drift, but I am not completely sure this is your issue.

Kind regards,

Romain

rfetick avatar Jan 04 '22 10:01 rfetick

Romain, Thanks for your reply. It is not that the angles are diverging, it is that the MPU6050 freezes up, halting the program into which it is embedded. I changed to the Adafruit library but the problem continues to occur although not as often. This seems to be happening to others as well. I am changing to the BNO055 instead of the MPU6050 with which I have had no such problems in the past. Thanks for your effort.

On Tue, Jan 4, 2022 at 5:40 AM Romain JL. FETICK @.***> wrote:

Dear drbrodie,

Are the angular values diverging? It could be a memory overflow. Clean calibration might be needed to avoid gyroscopic drift, but I am not completely sure this is your issue.

Kind regards,

Romain

— Reply to this email directly, view it on GitHub https://github.com/rfetick/MPU6050_light/issues/24#issuecomment-1004699606, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACEZ4WTK4XSM3ZEWVWBTEY3UULFATANCNFSM5KJBCW7A . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>

drbrodie avatar Jan 05 '22 21:01 drbrodie