From 58d45ef04ab0c385690f4ad4bdbf8c09ab057efc Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Tue, 28 Jan 2020 12:35:40 +1100 Subject: [PATCH] Plane: let AP_Vehicle handle loop() --- ArduPlane/ArduPlane.cpp | 6 ------ ArduPlane/Plane.h | 11 ----------- 2 files changed, 17 deletions(-) diff --git a/ArduPlane/ArduPlane.cpp b/ArduPlane/ArduPlane.cpp index b6b03df1b7..8fff7e2818 100644 --- a/ArduPlane/ArduPlane.cpp +++ b/ArduPlane/ArduPlane.cpp @@ -123,12 +123,6 @@ void Plane::get_scheduler_tasks(const AP_Scheduler::Task *&tasks, constexpr int8_t Plane::_failsafe_priorities[7]; -void Plane::loop() -{ - scheduler.loop(); - G_Dt = scheduler.get_loop_period_s(); -} - // update AHRS system void Plane::ahrs_update() { diff --git a/ArduPlane/Plane.h b/ArduPlane/Plane.h index 3ddc8833b7..a102f216a7 100644 --- a/ArduPlane/Plane.h +++ b/ArduPlane/Plane.h @@ -160,9 +160,6 @@ public: Plane(void); - // HAL::Callbacks implementation. - void loop() override; - private: // key aircraft parameters passed to multiple libraries @@ -172,9 +169,6 @@ private: Parameters g; ParametersG2 g2; - // main loop scheduler - AP_Scheduler scheduler; - // mapping between input channels RCMapper rcmap; @@ -726,11 +720,6 @@ private: float relative_altitude; - // INS variables - // The main loop execution time. Seconds - // This is the time between calls to the DCM algorithm and is the Integration time for the gyros. - float G_Dt = 0.02f; - // loop performance monitoring: AP::PerfInfo perf_info; struct {