Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed MatrixMath LPS25HB_I2C LSM9DS1 Matrix2 PIDcontroller LoopTicker SBUS_without_mainfile UsaPack solaESKF_wind Vector3 CalibrateMagneto FastPWM
Diff: global.cpp
- Revision:
- 106:36458fb9b5b7
- Parent:
- 104:f81befbc5ab7
- Child:
- 107:78e6f7bee68e
--- a/global.cpp Tue Mar 01 09:19:27 2022 +0000
+++ b/global.cpp Wed Mar 02 09:23:39 2022 +0000
@@ -32,7 +32,7 @@
float att_dt = 0.01f;
float tstart = 0.0f;
float tgps = 0.0f;
-float theading = 0.0f;
+float tsensors = 0.0f;
float rc[16];
int16_t ax, ay, az;
@@ -57,26 +57,21 @@
float palt;
float palt0;
bool gpsUpdateFlag = false;
-bool headingUpdateFlag = false;
+bool sensorUpdateFlag = false;
+int sensorUpdateID = 1;
bool prefligt_finished = false;
float dynaccnorm2;
-float opt_vx;
-float opt_vy;
-const float theta_px = 42.0f * M_PI / 180.0f;
-const float theta_py = 42.0f * M_PI / 180.0f;
-const int pixel_x = 35;
-const int pixel_y = 35;
+//float opt_vx;
+//float opt_vy;
+//const float theta_px = 42.0f * M_PI / 180.0f;
+//const float theta_py = 42.0f * M_PI / 180.0f;
+//const int pixel_x = 35;
+//const int pixel_y = 35;
int out1, out2;
float scaledServoOut[1] = {0.0f};
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
float agoffset[6] = {0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f};