Unverified Commit 4d0fd52a authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #6972 from DonLakeFlyer/RoverModes

ArduPilot: Update Rover flight modes
parents 77a65e60 12609df7
......@@ -18,11 +18,14 @@ APMRoverMode::APMRoverMode(uint32_t mode, bool settable)
{
QMap<uint32_t,QString> enumToString;
enumToString.insert(MANUAL, "Manual");
enumToString.insert(LEARNING, "Learning");
enumToString.insert(ACRO, "Acro");
enumToString.insert(STEERING, "Steering");
enumToString.insert(HOLD, "Hold");
enumToString.insert(LOITER, "Loiter");
enumToString.insert(SIMPLE, "Simple");
enumToString.insert(AUTO, "Auto");
enumToString.insert(RTL, "RTL");
enumToString.insert(SMART_RTL, "Smart RTL");
enumToString.insert(GUIDED, "Guided");
enumToString.insert(INITIALIZING, "Initializing");
......@@ -33,11 +36,14 @@ ArduRoverFirmwarePlugin::ArduRoverFirmwarePlugin(void)
{
QList<APMCustomMode> supportedFlightModes;
supportedFlightModes << APMRoverMode(APMRoverMode::MANUAL ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::LEARNING ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::ACRO ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::STEERING ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::HOLD ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::LOITER ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::SIMPLE ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::AUTO ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::RTL ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::SMART_RTL ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::GUIDED ,true);
supportedFlightModes << APMRoverMode(APMRoverMode::INITIALIZING ,false);
setSupportedModes(supportedFlightModes);
......
......@@ -20,23 +20,17 @@ class APMRoverMode : public APMCustomMode
{
public:
enum Mode {
MANUAL = 0,
RESERVED_1 = 1, // RESERVED FOR FUTURE USE
LEARNING = 2,
STEERING = 3,
HOLD = 4,
RESERVED_5 = 5, // RESERVED FOR FUTURE USE
RESERVED_6 = 6, // RESERVED FOR FUTURE USE
RESERVED_7 = 7, // RESERVED FOR FUTURE USE
RESERVED_8 = 8, // RESERVED FOR FUTURE USE
RESERVED_9 = 9, // RESERVED FOR FUTURE USE
AUTO = 10,
RTL = 11,
RESERVED_12 = 12, // RESERVED FOR FUTURE USE
RESERVED_13 = 13, // RESERVED FOR FUTURE USE
RESERVED_14 = 14, // RESERVED FOR FUTURE USE
GUIDED = 15,
INITIALIZING = 16,
MANUAL = 0,
ACRO = 1,
STEERING = 3,
HOLD = 4,
LOITER = 5,
SIMPLE = 7,
AUTO = 10,
RTL = 11,
SMART_RTL = 12,
GUIDED = 15,
INITIALIZING = 16,
};
static const int modeCount = 17;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment