From 22d3ab344cfbf3a8d8031fd9eac0cefa02197ac3 Mon Sep 17 00:00:00 2001 From: Randy Mackay Date: Fri, 24 Aug 2018 14:38:28 +0900 Subject: [PATCH] AP_Motors: add override keyword to get_motor_mask --- libraries/AP_Motors/AP_MotorsCoax.h | 2 +- libraries/AP_Motors/AP_MotorsMatrix.h | 2 +- libraries/AP_Motors/AP_MotorsSingle.h | 2 +- libraries/AP_Motors/AP_MotorsTailsitter.h | 2 +- libraries/AP_Motors/AP_MotorsTri.h | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/libraries/AP_Motors/AP_MotorsCoax.h b/libraries/AP_Motors/AP_MotorsCoax.h index fd7de528ca..400b4df2c7 100644 --- a/libraries/AP_Motors/AP_MotorsCoax.h +++ b/libraries/AP_Motors/AP_MotorsCoax.h @@ -47,7 +47,7 @@ public: // get_motor_mask - returns a bitmask of which outputs are being used for motors or servos (1 means being used) // this can be used to ensure other pwm outputs (i.e. for servos) do not conflict - virtual uint16_t get_motor_mask(); + uint16_t get_motor_mask() override; protected: // output - sends commands to the motors diff --git a/libraries/AP_Motors/AP_MotorsMatrix.h b/libraries/AP_Motors/AP_MotorsMatrix.h index 65cab404fc..5270ef1627 100644 --- a/libraries/AP_Motors/AP_MotorsMatrix.h +++ b/libraries/AP_Motors/AP_MotorsMatrix.h @@ -39,7 +39,7 @@ public: // get_motor_mask - returns a bitmask of which outputs are being used for motors (1 means being used) // this can be used to ensure other pwm outputs (i.e. for servos) do not conflict - uint16_t get_motor_mask(); + uint16_t get_motor_mask() override; protected: // output - sends commands to the motors diff --git a/libraries/AP_Motors/AP_MotorsSingle.h b/libraries/AP_Motors/AP_MotorsSingle.h index 85e5716572..af250fa841 100644 --- a/libraries/AP_Motors/AP_MotorsSingle.h +++ b/libraries/AP_Motors/AP_MotorsSingle.h @@ -47,7 +47,7 @@ public: // get_motor_mask - returns a bitmask of which outputs are being used for motors or servos (1 means being used) // this can be used to ensure other pwm outputs (i.e. for servos) do not conflict - virtual uint16_t get_motor_mask(); + uint16_t get_motor_mask() override; protected: // output - sends commands to the motors diff --git a/libraries/AP_Motors/AP_MotorsTailsitter.h b/libraries/AP_Motors/AP_MotorsTailsitter.h index 13dfd63718..d38c9ca1f1 100644 --- a/libraries/AP_Motors/AP_MotorsTailsitter.h +++ b/libraries/AP_Motors/AP_MotorsTailsitter.h @@ -27,7 +27,7 @@ public: void output_to_motors(); // return 0 motor mask - uint16_t get_motor_mask() { return 0; } + uint16_t get_motor_mask() override { return 0; } protected: // calculate motor outputs diff --git a/libraries/AP_Motors/AP_MotorsTri.h b/libraries/AP_Motors/AP_MotorsTri.h index f572f9207f..60972202fb 100644 --- a/libraries/AP_Motors/AP_MotorsTri.h +++ b/libraries/AP_Motors/AP_MotorsTri.h @@ -42,7 +42,7 @@ public: // get_motor_mask - returns a bitmask of which outputs are being used for motors or servos (1 means being used) // this can be used to ensure other pwm outputs (i.e. for servos) do not conflict - virtual uint16_t get_motor_mask(); + uint16_t get_motor_mask() override; // output a thrust to all motors that match a given motor // mask. This is used to control tiltrotor motors in forward