From 2ee9e04ff61023818c626179535f732e133cfa21 Mon Sep 17 00:00:00 2001 From: m_thread Date: Thu, 23 Oct 2014 12:42:27 +0200 Subject: [PATCH] OP-1567 Fixed some defaults in wizard. If CC or CC3D disable GPS. --- .../src/plugins/setupwizard/pages/controllerpage.cpp | 3 +++ ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp | 1 + 2 files changed, 4 insertions(+) diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/controllerpage.cpp b/ground/openpilotgcs/src/plugins/setupwizard/pages/controllerpage.cpp index 1aaca405d..6384ef239 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/pages/controllerpage.cpp +++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/controllerpage.cpp @@ -80,6 +80,9 @@ bool ControllerPage::isComplete() const bool ControllerPage::validatePage() { getWizard()->setControllerType((SetupWizard::CONTROLLER_TYPE)ui->boardTypeCombo->itemData(ui->boardTypeCombo->currentIndex()).toInt()); + if (getWizard()->getControllerType() == SetupWizard::CONTROLLER_CC || getWizard()->getControllerType() == SetupWizard::CONTROLLER_CC3D) { + getWizard()->setGpsType(SetupWizard::GPS_DISABLED); + } return true; } diff --git a/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp b/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp index 29ec8bae3..63cee784a 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp +++ b/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp @@ -58,6 +58,7 @@ SetupWizard::SetupWizard(QWidget *parent) : QWizard(parent), VehicleConfiguratio m_controllerType(CONTROLLER_UNKNOWN), m_vehicleType(VEHICLE_UNKNOWN), m_inputType(INPUT_UNKNOWN), m_escType(ESC_UNKNOWN), m_servoType(SERVO_UNKNOWN), m_vehicleTemplate(NULL), + m_gpsType(GPS_DISABLED), m_airspeedType(AIRSPEED_DISABLED), m_calibrationPerformed(false), m_restartNeeded(false), m_connectionManager(0) { setWindowTitle(tr("OpenPilot Setup Wizard"));