|
本帖最后由 trj221 于 2012-11-19 09:13 编辑
传感器都校准了的话,先别忙着起飞,用手小心的抓牢四轴离地,解锁稍加油,用手把四轴往各方向压、抬、转动,看是否感觉到四轴有相应的反作用力保持平衡和保持方向,如果没有明显的反作用力,就尝试按照自己飞控传感器配置修改下方向代码吧。如:
#define ACC_ORIENTATION(X, Y, Z) {accADC[ROLL] = -X; accADC[PITCH] = -Y; accADC[YAW] = Z;}
#define GYRO_ORIENTATION(X, Y, Z) {gyroADC[ROLL] = Y; gyroADC[PITCH] = -X; gyroADC[YAW] = -Z;}
#define MAG_ORIENTATION(X, Y, Z) {magADC[ROLL] = X; magADC[PITCH] = Y; magADC[YAW] = -Z;}
|
|