From 4e49e89b33afa577dde9efb42146f624bcde2266 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Sat, 2 Mar 2019 11:08:01 +1100 Subject: [PATCH] Tracker: move base_mode and frame_type into GCS from GCS_MAVLink --- AntennaTracker/GCS_Mavlink.cpp | 4 ++-- AntennaTracker/GCS_Mavlink.h | 2 -- AntennaTracker/GCS_Tracker.h | 3 +++ 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/AntennaTracker/GCS_Mavlink.cpp b/AntennaTracker/GCS_Mavlink.cpp index 01517b87a5..db83031811 100644 --- a/AntennaTracker/GCS_Mavlink.cpp +++ b/AntennaTracker/GCS_Mavlink.cpp @@ -12,7 +12,7 @@ * pattern below when adding any new messages */ -MAV_TYPE GCS_MAVLINK_Tracker::frame_type() const +MAV_TYPE GCS_Tracker::frame_type() const { return MAV_TYPE_ANTENNA_TRACKER; } @@ -60,7 +60,7 @@ MAV_MODE GCS_MAVLINK_Tracker::base_mode() const return (MAV_MODE)_base_mode; } -uint32_t GCS_MAVLINK_Tracker::custom_mode() const +uint32_t GCS_Tracker::custom_mode() const { return tracker.control_mode; } diff --git a/AntennaTracker/GCS_Mavlink.h b/AntennaTracker/GCS_Mavlink.h index c249512fdc..43ae73a720 100644 --- a/AntennaTracker/GCS_Mavlink.h +++ b/AntennaTracker/GCS_Mavlink.h @@ -44,9 +44,7 @@ private: void handle_change_alt_request(AP_Mission::Mission_Command &cmd) override; void send_global_position_int() override; - MAV_TYPE frame_type() const override; MAV_MODE base_mode() const override; - uint32_t custom_mode() const override; MAV_STATE system_status() const override; }; diff --git a/AntennaTracker/GCS_Tracker.h b/AntennaTracker/GCS_Tracker.h index 4dfe55e1c2..c86c393377 100644 --- a/AntennaTracker/GCS_Tracker.h +++ b/AntennaTracker/GCS_Tracker.h @@ -19,6 +19,9 @@ public: void update_sensor_status_flags() override; + uint32_t custom_mode() const override; + MAV_TYPE frame_type() const override; + private: void request_datastream_position(uint8_t sysid, uint8_t compid);