MPU9250自检失败

2019-07-21 03:16发布

MPU9250自检一直失败,目前硬件原因已经排除,也用过多种方向和倾角来开启自检,都始终失败,现在完全不知道该怎么办了,希望大神们看到可以指点一二,万分感激,失败LOG如下。
Starting MPU6500 HWST!//开启MPU6500 hardware self test(硬件自检)
Retrieving Biases//准备获取零位偏移(Z轴朝上,XY垂直于重力的方式)
Starting Bias Loop Reads//开始循环读取零位偏移
Samples: 200//获取次数为200次
Accel offset data HWST bit=0: -0.0073  0.0023 -0.7748//对200次零位偏移值求平均,得到平均加速度XYZ轴的零位偏移为-0.0073  0.0023 -0.7748
Gyro offset data HWST bit=0: -0.0678 19.4022  0.1907//对200次零位偏移值求平均,得到平均陀螺仪XYZ轴的零位偏移为-0.0073  0.0023 -0.7748
Retrieving ST Biases//准备获取开启自检模式的零位偏移,自检模式是芯片内部自己产生一定值得加速度和科里奥利力信息,以观察MPU9250能否输出差不多的值
Starting Bias Loop Reads//开始循环读取零位偏移
Samples: 200//获取次数为200次
Accel offset data HWST bit=1:  0.2298  0.3527 -0.6055//对200次零位偏移值求平均,得到平均加速度XYZ轴的零位偏移为 0.2298  0.3527 -0.6055
Gyro offset data HWST bit=1: 31.9056 57.1416 56.9990//对200次零位偏移值求平均,得到平均陀螺仪XYZ轴的零位偏移为31.9056 57.1416 56.9990
Accel OTP:86, 86, 107//加速度出厂XYZ的OTP修正值为86, 86, 107
ACCEL:CRITERIA A
Bias_Shift=15540.0000, Bias_Reg=-480.0000, Bias_HWST=15060.0000//加速度X轴自检偏移值为15540,加速度X轴偏移寄存器值为-480,加速度X轴自建偏移值为15060,Bias_Shift=Bias_HWST-Bias_Reg
OTP value: 24416.0000//更新加速度X轴的OTP修正值为24416.0000
ratio=-0.3635, threshold= 0.5000//自检偏移的倍率绝对值为0.3635,小于0.5,加速度X轴自检成功
Bias_Shift=22962.0000, Bias_Reg=151.0000, Bias_HWST=23113.0000//Y
OTP value: 24416.0000
ratio=-0.0596, threshold= 0.5000
Bias_Shift=11096.0000, Bias_Reg=-50776.0000, Bias_HWST=-39680.0000//Z
OTP value: 30088.0000
ratio=-0.6312, threshold= 0.5000//自检偏移的倍率绝对值为0.6312,大于0.5,加速度Z轴自检失败
ACCEL Fail Axis = 2//加速度第二轴失败(第二轴是Z轴)
Accel Self Test Results: 4//返回加速度失败代码4
Gyro OTP:189, 199, 226//陀螺,同加速度原理,但是陀螺的自检便宜倍率绝对值要大于0.5才算自检成功
GYRO:CRITERIA A
Bias_Shift=2095410.0000, Bias_Reg=-4442.0000, Bias_HWST=2090968.0000
OTP value: 8509675.0000
ratio= 0.2462, threshold= 0.5000
Gyro Fail Axis = 0//X轴失败
Bias_Shift=2473289.0000, Bias_Reg=1271540.0000, Bias_HWST=3744829.0000
OTP value: 9400164.0000
ratio= 0.2631, threshold= 0.5000
Gyro Fail Axis = 1//Y轴失败
Bias_Shift=3722985.0000, Bias_Reg=12499.0000, Bias_HWST=3735484.0000
OTP value: 12297255.0000
ratio= 0.3027, threshold= 0.5000
Gyro Fail Axis = 2//Z轴失败
Gyro Self Test Results: 7//返回陀螺仪失败代码7
Compass Self Test Results: 0//指南针自检成功
Exiting HWST


友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
34条回答
way7539512
2019-07-24 13:21
我来挖坟,楼主我和你的失败log基本一样,我用的是微库,不然放不进STM32F103C8T6,有可能就是这里出的问题,我准备那一块最小系统换成STM32F103CB来试试,下载完整库进去。
而且我读0x75寄存器值是0x73,手册上面写的应该是0x71,我怀疑这个模块是MPU9255,不是9250,不知道能不能兼容使用,但是不自检能读出数据,移动模块后数据都是很缓慢的增减。
下面是我的自检失败log

Starting MPU6500 HWST!

Retrieving Biases

Starting Bias Loop Reads
Samples: 200
Accel offset data HWST bit=0:  0.2553  0.0946 -0.6670

Gyro offset data HWST bit=0:  2.8824 17.6259  8.9984

Retrieving ST Biases
Starting Bias Loop Reads
Samples: 200
Accel offset data HWST bit=1:  0.6043  0.5947 -0.1439

Gyro offset data HWST bit=1: 96.8342 81.1205 89.9066

Accel OTP:91, 89, 119
ACCEL:CRITERIA A
Bias_Shift=22868.0000, Bias_Reg=16733.0000, Bias_HWST=39601.0000

OTP value: 25660.0000

ratio=-0.1088, threshold= 0.5000

Bias_Shift=32770.0000, Bias_Reg=6201.0000, Bias_HWST=38971.0000

OTP value: 25156.0000

ratio= 0.3027, threshold= 0.5000

Bias_Shift=34281.0000, Bias_Reg=-43712.0000, Bias_HWST=-9431.0000

OTP value: 33904.0000

ratio= 0.0111, threshold= 0.5000

Accel:CRITERIA C: bias less than 32768.0000
FAILED: Accel axis:2 = -43712 > 500mg
Accel Self Test Results: 4
Gyro OTP:193, 205, 224

GYRO:CRITERIA A
Bias_Shift=6157227.0000, Bias_Reg=188901.0000, Bias_HWST=6346128.0000

OTP value: 8855364.0000

ratio= 0.6953, threshold= 0.5000

Bias_Shift=4161176.0000, Bias_Reg=1155134.0000, Bias_HWST=5316310.0000

OTP value: 9978481.0000

ratio= 0.4170, threshold= 0.5000

Gyro Fail Axis = 1
Bias_Shift=5302403.0000, Bias_Reg=589716.0000, Bias_HWST=5892119.0000

OTP value: 12055122.0000

ratio= 0.4398, threshold= 0.5000

Gyro Fail Axis = 2
Gyro Self Test Results: 6
Compass Self Test Results: 0
Exiting HWST

楼主现在解决了嘛,还是换了大容量的芯片

一周热门 更多>