From 488a359d85ffc47293c1a81ed7d65fa4b7bdb8e1 Mon Sep 17 00:00:00 2001 From: Fredrik Larson Date: Sun, 28 Sep 2014 22:46:01 +1000 Subject: [PATCH] add the page --- .../src/plugins/setupwizard/pages/esccalibrationpage.cpp | 1 + .../src/plugins/setupwizard/pages/esccalibrationpage.h | 1 - .../src/plugins/setupwizard/pages/esccalibrationpage.ui | 8 +++----- .../openpilotgcs/src/plugins/setupwizard/setupwizard.cpp | 5 +++++ ground/openpilotgcs/src/plugins/setupwizard/setupwizard.h | 2 +- 5 files changed, 10 insertions(+), 7 deletions(-) diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.cpp b/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.cpp index a2c6b29f0..bd66d55b9 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.cpp +++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.cpp @@ -32,6 +32,7 @@ EscCalibrationPage::EscCalibrationPage(SetupWizard *wizard, QWidget *parent) : AbstractWizardPage(wizard, parent), + ui(new Ui::EscCalibrationPage) { ui->setupUi(this); diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.h b/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.h index c546270ba..f1dd57f0d 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.h +++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.h @@ -26,7 +26,6 @@ */ - #ifndef ESCCALIBRATIONPAGE_H #define ESCCALIBRATIONPAGE_H diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.ui b/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.ui index e00a9fe94..e87e9113c 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.ui +++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/esccalibrationpage.ui @@ -1,7 +1,7 @@ - BiasCalibrationPage - + EscCalibrationPage + 0 @@ -66,8 +66,6 @@ p, li { white-space: pre-wrap; } - - - + diff --git a/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp b/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp index f19c6fd51..dbcc9b534 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp +++ b/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.cpp @@ -40,6 +40,7 @@ #include "pages/escpage.h" #include "pages/servopage.h" #include "pages/biascalibrationpage.h" +#include "pages/esccalibrationpage.h" #include "pages/summarypage.h" #include "pages/savepage.h" #include "pages/notyetimplementedpage.h" @@ -167,6 +168,9 @@ int SetupWizard::nextId() const } case PAGE_BIAS_CALIBRATION: + return PAGE_ESC_CALIBRATION; + + case PAGE_ESC_CALIBRATION: return PAGE_OUTPUT_CALIBRATION; case PAGE_OUTPUT_CALIBRATION: @@ -441,6 +445,7 @@ void SetupWizard::createPages() setPage(PAGE_ESC, new EscPage(this)); setPage(PAGE_SERVO, new ServoPage(this)); setPage(PAGE_BIAS_CALIBRATION, new BiasCalibrationPage(this)); + setPage(PAGE_ESC_CALIBRATION, new EscCalibrationPage(this)); setPage(PAGE_OUTPUT_CALIBRATION, new OutputCalibrationPage(this)); setPage(PAGE_SUMMARY, new SummaryPage(this)); setPage(PAGE_SAVE, new SavePage(this)); diff --git a/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.h b/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.h index 894710ab9..3a641d54d 100644 --- a/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.h +++ b/ground/openpilotgcs/src/plugins/setupwizard/setupwizard.h @@ -186,7 +186,7 @@ private slots: private: enum { PAGE_START, PAGE_CONTROLLER, PAGE_VEHICLES, PAGE_MULTI, PAGE_FIXEDWING, PAGE_AIRSPEED, PAGE_GPS, PAGE_HELI, PAGE_SURFACE, PAGE_INPUT, PAGE_ESC, PAGE_SERVO, - PAGE_BIAS_CALIBRATION, PAGE_REVO_CALIBRATION, PAGE_OUTPUT_CALIBRATION, + PAGE_BIAS_CALIBRATION, PAGE_ESC_CALIBRATION, PAGE_REVO_CALIBRATION, PAGE_OUTPUT_CALIBRATION, PAGE_SAVE, PAGE_SUMMARY, PAGE_NOTYETIMPLEMENTED, PAGE_AIRFRAME_INITIAL_TUNING, PAGE_REBOOT, PAGE_END, PAGE_UPDATE }; void createPages();