solaESKF_EIGEN
Dependencies: mbed LPS25HB_I2C LSM9DS1 PIDcontroller LoopTicker GPSUBX_UART_Eigen SBUS_without_mainfile MedianFilter Eigen UsaPack solaESKF_Eigen Vector3 CalibrateMagneto FastPWM
Diff: global.cpp
- Revision:
- 61:c05353850017
- Parent:
- 58:a7947322db87
- Child:
- 62:ef10fd919f7b
--- a/global.cpp Wed Jun 02 06:14:47 2021 +0000 +++ b/global.cpp Thu Jun 03 11:28:13 2021 +0000 @@ -11,6 +11,7 @@ // sensor MPU6050 accelgyro; MAG3110 mag_sensor(PB_9,PB_8); +CalibrateMagneto magCalibrator; // io DigitalIn userButton(USER_BUTTON); @@ -51,13 +52,16 @@ float servoOut[1] = {1500.0f}; float val_thmg = 0.0f; +float sigma_thmg = 0.0f; float th_mg = 0.0f; float accnormerr = 0.0f; +float sigma_accnorm = 0.0f; int calibrationFlag = 0; int pos_tail = 0; // 0:left 1:center 2:right int agoffset[6] = {0, 0, 0, 386, -450, 48}; -float magbias[4] = {0.0f, 0.0f, 0.0f, 50.0f}; +float magbiasMin[3] = {0.0f, 0.0f, 0.0f}; +float magbiasMax[3] = {0.0f, 0.0f, 0.0f}; Vector3 rpy_align(0.0f*M_PI/180.0f, 0.0f*M_PI/180.0f, 0.0f);