libdriver / mpu6050

MPU6050 full function driver library for general MCU and Linux.
https://www.libdriver.com
MIT License
372 stars 154 forks source link

mpu6050_self_test自检失败 #19

Open MagicPrince666 opened 9 months ago

MagicPrince666 commented 9 months ago

Description of the issues

代码移植到ros2 c++发现在mpu6050_dmp_init() 函数里面报了 gyro self test failed.,这个问题怎么排查

Additional context

No response

libdriver commented 9 months ago

Thank you very much for using the LibDriver MPU6050. The error 'gyro self test failed' indicates that the MPU6050 gyroscope self test has failed. Generally, there are several reasons for this error:

1.During self inspection, move MPU6050. Due to the self inspection requirements of MPU6050 itself, it is not allowed to move significantly during the self inspection period, otherwise the self inspection calculation will fail. Please do not move MPU6050 during the self inspection.

  1. The delay function error is too large. The MPU6050 self check requires the use of a delay to wait for the self check to generate data. The drive delay has great conservatism. Generally speaking, there is a certain error that is not a problem, but a large delay error can seriously interfere with the verification process. Please ensure the accuracy of the delay.
  2. IIC communication is unstable and requires at least running the /test/register_test to test the stability of IIC communication.
  3. If there are issues with the chip itself, including refurbishment, false chips, or chip defects, a replacement MPU6050 can be used for retesting.

非常感谢您使用LibDriver驱动,出现“gyro self test failed”的错误表示MPU6050陀螺仪自检失败,出现这种错误一般而言有以下几个原因: 1.自检的时候移动MPU6050。因为MPU6050本身自检的要求,MPU6050在自检期间不允许较大移动,否则自检计算会校验失败,自检时请不要移动MPU6050。 2.延时函数误差太大,MPU6050自检需要使用延时等待自检产生数据,驱动延时有很大的保守性一般而言存在一定误差没有问题,但是延时误差太大也会严重干扰校验过程,请确保延时的准确性。 3.IIC通信不稳定,需要至少运行/test中的register_test检测IIC通信的稳定性。 4.芯片本身问题,包括翻新、虚假芯片或者芯片自身缺陷等问题,可以更换一个MPU6050再次测试。