From f9238f7e97a9e0e5b2d89352382c21f70a204a05 Mon Sep 17 00:00:00 2001 From: Lorenz Meier Date: Tue, 19 May 2015 13:15:11 +0200 Subject: [PATCH] UAS: Add ability to calibrate horizon to level --- src/uas/UAS.cc | 3 +++ src/uas/UASInterface.h | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/uas/UAS.cc b/src/uas/UAS.cc index 8f148a517..95622e68e 100644 --- a/src/uas/UAS.cc +++ b/src/uas/UAS.cc @@ -1472,6 +1472,9 @@ void UAS::startCalibration(UASInterface::StartCalibrationType calType) case StartCalibrationAccel: accelCal = 1; break; + case StartCalibrationLevel: + accelCal = 2; + break; } mavlink_message_t msg; diff --git a/src/uas/UASInterface.h b/src/uas/UASInterface.h index 4ad625df3..ecdf0683a 100644 --- a/src/uas/UASInterface.h +++ b/src/uas/UASInterface.h @@ -243,7 +243,8 @@ public: StartCalibrationGyro, StartCalibrationMag, StartCalibrationAirspeed, - StartCalibrationAccel + StartCalibrationAccel, + StartCalibrationLevel }; /// Starts the specified calibration -- 2.22.0