mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-30 15:52:12 +01:00
LP-245: config: all buttons (help, apply, save, ...) are now handled through autobinding
This commit is contained in:
parent
a9e3e91f92
commit
f930e85175
@ -218,7 +218,7 @@
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="airframeHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -250,26 +250,35 @@
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveAircraftToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="toolTip">
|
||||
<string>Send to board, but don't save permanently (flash or SD).</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Apply</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveAircraftToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="toolTip">
|
||||
<string>Applies and Saves all settings to flash or SD depending on board.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
@ -287,9 +296,9 @@
|
||||
<tabstops>
|
||||
<tabstop>nameEdit</tabstop>
|
||||
<tabstop>vehicleSetupWizardButton</tabstop>
|
||||
<tabstop>airframeHelp</tabstop>
|
||||
<tabstop>saveAircraftToRAM</tabstop>
|
||||
<tabstop>saveAircraftToSD</tabstop>
|
||||
<tabstop>helpButton</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../coreplugin/core.qrc"/>
|
||||
|
@ -23,7 +23,16 @@
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<item>
|
||||
@ -36,11 +45,38 @@
|
||||
<string>Pre-Autotune</string>
|
||||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout_5">
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<item row="3" column="0" colspan="3">
|
||||
<widget class="QTextEdit" name="textEdit">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>QFrame::StyledPanel</enum>
|
||||
</property>
|
||||
@ -51,9 +87,9 @@
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;">
|
||||
</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;">
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:20pt; font-weight:600; color:#ff0000;">WARNING:</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Lucida Grande'; font-size:13pt;"></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Lucida Grande'; font-size:13pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:13pt;"><br /></span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:13pt;"><br /></span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:13pt;">This is an experimental plugin for the GCS that is going to make your aircraft shake, etc, so test with lots of space and be </span><span style=" font-family:'Lucida Grande'; font-size:13pt; font-weight:600;">very very wary</span><span style=" font-family:'Lucida Grande'; font-size:13pt;"> for it creating bad tuning values. Basically there is no reason to think this will work at all.<br /><br />To use autotuning, here are the steps:<br /></span></p>
|
||||
@ -99,7 +135,16 @@ p, li { white-space: pre-wrap; }
|
||||
<string>Autotune Setup</string>
|
||||
</attribute>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
@ -182,8 +227,8 @@ p, li { white-space: pre-wrap; }
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>709</width>
|
||||
<height>605</height>
|
||||
<width>526</width>
|
||||
<height>510</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
@ -199,7 +244,16 @@ p, li { white-space: pre-wrap; }
|
||||
<property name="spacing">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<property name="leftMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>12</number>
|
||||
</property>
|
||||
<item>
|
||||
@ -601,7 +655,45 @@ will alter settings for the next autotuning flight</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="stabilizationReloadBoardData_6">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>25</width>
|
||||
<height>25</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>25</width>
|
||||
<height>25</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../coreplugin/core.qrc">
|
||||
<normaloff>:/core/images/helpicon.svg</normaloff>:/core/images/helpicon.svg</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
<size>
|
||||
<width>25</width>
|
||||
<height>25</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="reloadButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -627,7 +719,7 @@ Useful if you have accidentally changed some settings.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveStabilizationToRAM_6">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -651,7 +743,7 @@ Useful if you have accidentally changed some settings.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveStabilizationToSD_6">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -678,6 +770,8 @@ Useful if you have accidentally changed some settings.</string>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources/>
|
||||
<resources>
|
||||
<include location="../coreplugin/core.qrc"/>
|
||||
</resources>
|
||||
<connections/>
|
||||
</ui>
|
||||
|
@ -72,7 +72,7 @@
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>-103</y>
|
||||
<y>0</y>
|
||||
<width>748</width>
|
||||
<height>811</height>
|
||||
</rect>
|
||||
@ -1321,7 +1321,7 @@ The same value is used for all axes.</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QPushButton" name="camerastabilizationHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1369,7 +1369,7 @@ The same value is used for all axes.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="2">
|
||||
<widget class="QPushButton" name="camerastabilizationResetToDefaults">
|
||||
<widget class="QPushButton" name="defaultButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1400,7 +1400,7 @@ Apply or Save button afterwards.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="3">
|
||||
<widget class="QPushButton" name="pushButton">
|
||||
<widget class="QPushButton" name="reloadButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1433,7 +1433,7 @@ Apply or Save button afterwards.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="4">
|
||||
<widget class="QPushButton" name="camerastabilizationSaveRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1460,7 +1460,7 @@ Apply or Save button afterwards.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="5">
|
||||
<widget class="QPushButton" name="camerastabilizationSaveSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1528,10 +1528,10 @@ Apply or Save button afterwards.</string>
|
||||
<tabstop>yawDecelTime</tabstop>
|
||||
<tabstop>gimbalType</tabstop>
|
||||
<tabstop>maxAccel</tabstop>
|
||||
<tabstop>camerastabilizationResetToDefaults</tabstop>
|
||||
<tabstop>pushButton</tabstop>
|
||||
<tabstop>camerastabilizationSaveRAM</tabstop>
|
||||
<tabstop>camerastabilizationSaveSD</tabstop>
|
||||
<tabstop>defaultButton</tabstop>
|
||||
<tabstop>reloadButton</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../coreplugin/core.qrc"/>
|
||||
|
@ -456,7 +456,7 @@
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="cchwHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -494,10 +494,13 @@
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -596,10 +599,13 @@ Beware of not locking yourself out!</string>
|
||||
<property name="checkable">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -625,6 +631,9 @@ Beware of not locking yourself out!</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
|
@ -117,7 +117,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>758</width>
|
||||
<height>486</height>
|
||||
<height>480</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
@ -550,7 +550,7 @@ A setting of 0.00 disables the filter.</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="ccAttitudeHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -582,6 +582,9 @@ A setting of 0.00 disables the filter.</string>
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
@ -595,6 +598,9 @@ A setting of 0.00 disables the filter.</string>
|
||||
<property name="text">
|
||||
<string>Apply</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
@ -611,6 +617,9 @@ A setting of 0.00 disables the filter.</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
|
@ -29,6 +29,9 @@
|
||||
|
||||
#include "ui_airframe_ccpm.h"
|
||||
|
||||
#include <extensionsystem/pluginmanager.h>
|
||||
#include <uavobjectutilmanager.h>
|
||||
|
||||
#include "mixersettings.h"
|
||||
#include "systemsettings.h"
|
||||
#include "actuatorcommand.h"
|
||||
@ -1417,6 +1420,16 @@ void ConfigCcpmWidget::SwashLvlFinishButtonPressed()
|
||||
ccpmSwashplateUpdate();
|
||||
}
|
||||
|
||||
void ConfigCcpmWidget::saveObjectToSD(UAVObject *obj)
|
||||
{
|
||||
// saveObjectToSD is now handled by the UAVUtils plugin in one
|
||||
// central place (and one central queue)
|
||||
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
|
||||
UAVObjectUtilManager *utilMngr = pm->getObject<UAVObjectUtilManager>();
|
||||
|
||||
utilMngr->saveObjectToSD(obj);
|
||||
}
|
||||
|
||||
int ConfigCcpmWidget::ShowDisclaimer(int messageID)
|
||||
{
|
||||
QMessageBox msgBox;
|
||||
|
@ -112,6 +112,8 @@ private:
|
||||
|
||||
QString updateConfigObjects();
|
||||
|
||||
void saveObjectToSD(UAVObject *obj);
|
||||
|
||||
private slots:
|
||||
virtual void setupUI(QString airframeType);
|
||||
virtual bool throwConfigError(int typeInt);
|
||||
|
@ -31,17 +31,14 @@
|
||||
#include "ui_cc_hw_settings.h"
|
||||
|
||||
#include <extensionsystem/pluginmanager.h>
|
||||
#include <uavobjectutilmanager.h>
|
||||
|
||||
#include "hwsettings.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <QStringList>
|
||||
#include <QWidget>
|
||||
#include <QTextEdit>
|
||||
#include <QVBoxLayout>
|
||||
#include <QPushButton>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QSvgRenderer>
|
||||
|
||||
ConfigCCHWWidget::ConfigCCHWWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
{
|
||||
@ -49,16 +46,10 @@ ConfigCCHWWidget::ConfigCCHWWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
m_telemetry->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("CC+Hardware+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
connect(m_telemetry->cchwHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_telemetry->saveTelemetryToRAM, m_telemetry->saveTelemetryToSD);
|
||||
|
||||
m_telemetry->saveTelemetryToRAM->setVisible(expertMode());
|
||||
|
||||
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
|
||||
UAVObjectUtilManager *utilMngr = pm->getObject<UAVObjectUtilManager>();
|
||||
int id = utilMngr->getBoardModel();
|
||||
@ -101,8 +92,6 @@ ConfigCCHWWidget::ConfigCCHWWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
} else {
|
||||
addWidgetBinding("GPSSettings", "DataProtocol", m_telemetry->gpsProtocol);
|
||||
}
|
||||
|
||||
enableSaveButtons(false);
|
||||
}
|
||||
|
||||
ConfigCCHWWidget::~ConfigCCHWWidget()
|
||||
@ -145,17 +134,6 @@ void ConfigCCHWWidget::widgetsContentsChanged()
|
||||
|
||||
void ConfigCCHWWidget::enableSaveButtons(bool enable)
|
||||
{
|
||||
m_telemetry->saveTelemetryToRAM->setEnabled(enable);
|
||||
m_telemetry->saveTelemetryToSD->setEnabled(enable);
|
||||
m_telemetry->applyButton->setEnabled(enable);
|
||||
m_telemetry->saveButton->setEnabled(enable);
|
||||
}
|
||||
|
||||
void ConfigCCHWWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("CC+Hardware+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
||||
/**
|
||||
* @}
|
||||
* @}
|
||||
*/
|
||||
|
@ -29,16 +29,10 @@
|
||||
#define CONFIGCCHWWIDGET_H
|
||||
|
||||
#include "../uavobjectwidgetutils/configtaskwidget.h"
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
#include "uavobjectmanager.h"
|
||||
#include "uavobject.h"
|
||||
#include "smartsavebutton.h"
|
||||
|
||||
#include <QWidget>
|
||||
#include <QList>
|
||||
#include <QSvgRenderer>
|
||||
|
||||
class Ui_CC_HW_Widget;
|
||||
class QWidget;
|
||||
class QSvgRenderer;
|
||||
|
||||
class ConfigCCHWWidget : public ConfigTaskWidget {
|
||||
Q_OBJECT
|
||||
@ -47,7 +41,6 @@ public:
|
||||
ConfigCCHWWidget(QWidget *parent = 0);
|
||||
~ConfigCCHWWidget();
|
||||
private slots:
|
||||
void openHelp();
|
||||
void refreshValues();
|
||||
void widgetsContentsChanged();
|
||||
void enableSaveButtons(bool enable);
|
||||
|
@ -55,10 +55,6 @@ ConfigCameraStabilizationWidget::ConfigCameraStabilizationWidget(QWidget *parent
|
||||
|
||||
disableMouseWheelEvents();
|
||||
|
||||
addApplySaveButtons(ui->camerastabilizationSaveRAM, ui->camerastabilizationSaveSD);
|
||||
|
||||
ui->camerastabilizationSaveRAM->setVisible(expertMode());
|
||||
|
||||
// These widgets don't have direct relation to UAVObjects
|
||||
// and need special processing
|
||||
QComboBox *outputs[] = { ui->rollChannel, ui->pitchChannel, ui->yawChannel, };
|
||||
@ -163,8 +159,7 @@ void ConfigCameraStabilizationWidget::refreshWidgetsValuesImpl(UAVObject *obj)
|
||||
void ConfigCameraStabilizationWidget::updateObjectsFromWidgetsImpl()
|
||||
{
|
||||
// Save state of the module enable checkbox first.
|
||||
// Do not use setData() member on whole object, if possible, since it triggers
|
||||
// unnessesary UAVObect update.
|
||||
// Do not use setData() member on whole object, if possible, since it triggers unnecessary UAVObect update.
|
||||
quint8 enableModule = ui->enableCameraStabilization->isChecked() ?
|
||||
HwSettings::OPTIONALMODULES_ENABLED : HwSettings::OPTIONALMODULES_DISABLED;
|
||||
HwSettings *hwSettings = HwSettings::GetInstance(getObjectManager());
|
||||
|
@ -28,8 +28,7 @@
|
||||
#define CONFIGCAMERASTABILIZATIONWIDGET_H
|
||||
|
||||
#include "../uavobjectwidgetutils/configtaskwidget.h"
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
#include "uavobjectmanager.h"
|
||||
|
||||
#include "uavobject.h"
|
||||
|
||||
#include "camerastabsettings.h"
|
||||
|
@ -29,7 +29,7 @@
|
||||
|
||||
#include "ui_ccattitude.h"
|
||||
|
||||
#include "utils/coordinateconversions.h"
|
||||
#include <utils/coordinateconversions.h>
|
||||
#include <calibration/calibrationutils.h>
|
||||
|
||||
#include "attitudesettings.h"
|
||||
@ -37,11 +37,8 @@
|
||||
#include "accelgyrosettings.h"
|
||||
#include "gyrostate.h"
|
||||
|
||||
#include <QMutexLocker>
|
||||
#include <QMessageBox>
|
||||
#include <QDebug>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
|
||||
ConfigCCAttitudeWidget::ConfigCCAttitudeWidget(QWidget *parent) :
|
||||
ConfigTaskWidget(parent), accelUpdates(0), gyroUpdates(0)
|
||||
@ -50,16 +47,10 @@ ConfigCCAttitudeWidget::ConfigCCAttitudeWidget(QWidget *parent) :
|
||||
ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("CC+Attitude+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
connect(ui->ccAttitudeHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(ui->applyButton, ui->saveButton);
|
||||
|
||||
ui->applyButton->setVisible(expertMode());
|
||||
|
||||
addUAVObject("AttitudeSettings");
|
||||
addUAVObject("AccelGyroSettings");
|
||||
|
||||
@ -218,12 +209,6 @@ void ConfigCCAttitudeWidget::startAccelCalibration()
|
||||
connect(&timer, SIGNAL(timeout()), this, SLOT(timeout()));
|
||||
}
|
||||
|
||||
void ConfigCCAttitudeWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("CC+Attitude+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
||||
void ConfigCCAttitudeWidget::setAccelFiltering(bool active)
|
||||
{
|
||||
Q_UNUSED(active);
|
||||
|
@ -28,8 +28,7 @@
|
||||
#define CCATTITUDEWIDGET_H
|
||||
|
||||
#include "../uavobjectwidgetutils/configtaskwidget.h"
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
#include "uavobjectmanager.h"
|
||||
|
||||
#include "uavobject.h"
|
||||
|
||||
#include <QWidget>
|
||||
@ -51,7 +50,6 @@ private slots:
|
||||
void sensorsUpdated(UAVObject *obj);
|
||||
void timeout();
|
||||
void startAccelCalibration();
|
||||
void openHelp();
|
||||
void setAccelFiltering(bool active);
|
||||
|
||||
private:
|
||||
@ -67,6 +65,7 @@ private:
|
||||
QList<double> x_gyro_accum, y_gyro_accum, z_gyro_accum;
|
||||
|
||||
static const int NUM_SENSOR_UPDATES = 300;
|
||||
|
||||
protected:
|
||||
virtual void enableControls(bool enable);
|
||||
};
|
||||
|
@ -37,21 +37,15 @@
|
||||
#include "failsafechannelform.h"
|
||||
#include "ui_failsafechannelform.h"
|
||||
|
||||
#include <utils/stylehelper.h>
|
||||
#include <uavobjectmanager.h>
|
||||
#include <uavobjecthelper.h>
|
||||
#include <utils/stylehelper.h>
|
||||
|
||||
#include <systemalarms.h>
|
||||
|
||||
#include <QDebug>
|
||||
#include <QStringList>
|
||||
#include <QWidget>
|
||||
#include <QTextEdit>
|
||||
#include <QVBoxLayout>
|
||||
#include <QPushButton>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QMessageBox>
|
||||
#include <QEventLoop>
|
||||
#include <QGraphicsSvgItem>
|
||||
#include <QSvgRenderer>
|
||||
|
||||
@ -87,15 +81,10 @@ ConfigInputWidget::ConfigInputWidget(QWidget *parent) :
|
||||
ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("Input+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
connect(ui->inputHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(ui->saveRCInputToRAM, ui->saveRCInputToSD);
|
||||
ui->saveRCInputToRAM->setVisible(expertMode());
|
||||
|
||||
connect(this, SIGNAL(enableControlsChanged(bool)), this, SLOT(enableControlsChanged(bool)));
|
||||
|
||||
manualCommandObj = ManualControlCommand::GetInstance(getObjectManager());
|
||||
@ -493,12 +482,6 @@ void ConfigInputWidget::resizeEvent(QResizeEvent *event)
|
||||
wizardUi->graphicsView->fitInView(m_txBackground, Qt::KeepAspectRatio);
|
||||
}
|
||||
|
||||
void ConfigInputWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Input+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
||||
void ConfigInputWidget::goToWizard()
|
||||
{
|
||||
QMessageBox msgBox;
|
||||
@ -1953,8 +1936,8 @@ void ConfigInputWidget::simpleCalibration(bool enable)
|
||||
{
|
||||
if (enable) {
|
||||
ui->configurationWizard->setEnabled(false);
|
||||
ui->saveRCInputToRAM->setEnabled(false);
|
||||
ui->saveRCInputToSD->setEnabled(false);
|
||||
ui->applyButton->setEnabled(false);
|
||||
ui->saveButton->setEnabled(false);
|
||||
ui->runCalibration->setText(tr("Stop Manual Calibration"));
|
||||
throttleError = false;
|
||||
|
||||
@ -2031,8 +2014,8 @@ void ConfigInputWidget::simpleCalibration(bool enable)
|
||||
actuatorSettingsObj->setData(memento.actuatorSettingsData);
|
||||
|
||||
ui->configurationWizard->setEnabled(true);
|
||||
ui->saveRCInputToRAM->setEnabled(true);
|
||||
ui->saveRCInputToSD->setEnabled(true);
|
||||
ui->applyButton->setEnabled(true);
|
||||
ui->saveButton->setEnabled(true);
|
||||
ui->runCalibration->setText(tr("Start Manual Calibration"));
|
||||
|
||||
disconnect(manualCommandObj, SIGNAL(objectUnpacked(UAVObject *)), this, SLOT(updateCalibration()));
|
||||
|
@ -29,8 +29,7 @@
|
||||
#define CONFIGINPUTWIDGET_H
|
||||
|
||||
#include "uavobjectwidgetutils/configtaskwidget.h"
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
#include "uavobjectmanager.h"
|
||||
|
||||
#include "uavobject.h"
|
||||
|
||||
#include "manualcontrolcommand.h"
|
||||
@ -212,7 +211,6 @@ private slots:
|
||||
void wzCancel();
|
||||
void goToWizard();
|
||||
void disableWizardButton(int);
|
||||
void openHelp();
|
||||
void identifyControls();
|
||||
void identifyLimits();
|
||||
void moveTxControls();
|
||||
|
@ -56,9 +56,6 @@ ConfigOPLinkWidget::ConfigOPLinkWidget(QWidget *parent) : ConfigTaskWidget(paren
|
||||
|
||||
disableMouseWheelEvents();
|
||||
|
||||
addApplySaveButtons(m_oplink->Apply, m_oplink->Save);
|
||||
m_oplink->Apply->setVisible(expertMode());
|
||||
|
||||
connect(this, SIGNAL(connected()), this, SLOT(connected()));
|
||||
|
||||
oplinkStatusObj = dynamic_cast<OPLinkStatus *>(getObject("OPLinkStatus"));
|
||||
|
@ -49,11 +49,7 @@
|
||||
#include <QStringList>
|
||||
#include <QWidget>
|
||||
#include <QTextEdit>
|
||||
#include <QVBoxLayout>
|
||||
#include <QPushButton>
|
||||
#include <QMessageBox>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
|
||||
ConfigOutputWidget::ConfigOutputWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
{
|
||||
@ -61,16 +57,10 @@ ConfigOutputWidget::ConfigOutputWidget(QWidget *parent) : ConfigTaskWidget(paren
|
||||
m_ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("Output+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
// Connect the help button
|
||||
connect(m_ui->outputHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_ui->saveRCOutputToRAM, m_ui->saveRCOutputToSD);
|
||||
m_ui->saveRCOutputToRAM->setVisible(expertMode());
|
||||
|
||||
m_ui->gvFrame->setVisible(false);
|
||||
|
||||
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
|
||||
@ -490,12 +480,6 @@ void ConfigOutputWidget::updateAlwaysStabilizeStatus()
|
||||
}
|
||||
}
|
||||
|
||||
void ConfigOutputWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Output+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
||||
void ConfigOutputWidget::onBankTypeChange()
|
||||
{
|
||||
QComboBox *bankModeCombo = qobject_cast<QComboBox *>(sender());
|
||||
|
@ -112,7 +112,6 @@ private slots:
|
||||
void stopTests();
|
||||
void runChannelTests(bool state);
|
||||
void sendChannelTest(int index, int value);
|
||||
void openHelp();
|
||||
void onBankTypeChange();
|
||||
};
|
||||
|
||||
|
@ -34,9 +34,6 @@
|
||||
#include "hwsettings.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QMessageBox>
|
||||
|
||||
ConfigRevoHWWidget::ConfigRevoHWWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
{
|
||||
@ -44,14 +41,11 @@ ConfigRevoHWWidget::ConfigRevoHWWidget(QWidget *parent) : ConfigTaskWidget(paren
|
||||
m_ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("Revolution+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
connect(m_ui->cchwHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_ui->saveTelemetryToRAM, m_ui->saveTelemetryToSD);
|
||||
m_ui->saveTelemetryToRAM->setVisible(expertMode());
|
||||
addUAVObject("HwSettings");
|
||||
|
||||
addWidgetBinding("HwSettings", "RM_FlexiPort", m_ui->cbFlexi);
|
||||
addWidgetBinding("HwSettings", "RM_MainPort", m_ui->cbMain);
|
||||
@ -476,9 +470,3 @@ void ConfigRevoHWWidget::rcvrPortChanged(int index)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void ConfigRevoHWWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Revolution+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
@ -58,7 +58,6 @@ private slots:
|
||||
void flexiPortChanged(int index);
|
||||
void mainPortChanged(int index);
|
||||
void rcvrPortChanged(int index);
|
||||
void openHelp();
|
||||
};
|
||||
|
||||
#endif // CONFIGREVOHWWIDGET_H
|
||||
|
@ -121,9 +121,9 @@
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>-148</y>
|
||||
<y>0</y>
|
||||
<width>796</width>
|
||||
<height>804</height>
|
||||
<height>807</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_3">
|
||||
@ -548,7 +548,7 @@
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="configgadget.qrc">:/configgadget/images/revolution_top.png</pixmap>
|
||||
<pixmap>:/configgadget/images/revolution_top.png</pixmap>
|
||||
</property>
|
||||
<property name="scaledContents">
|
||||
<bool>false</bool>
|
||||
@ -739,7 +739,7 @@
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="cchwHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -777,10 +777,13 @@
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -879,10 +882,13 @@ Beware of not locking yourself out!</string>
|
||||
<property name="checkable">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -908,6 +914,9 @@ Beware of not locking yourself out!</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
|
@ -34,9 +34,6 @@
|
||||
#include "hwsettings.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QMessageBox>
|
||||
|
||||
ConfigRevoNanoHWWidget::ConfigRevoNanoHWWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
{
|
||||
@ -44,14 +41,11 @@ ConfigRevoNanoHWWidget::ConfigRevoNanoHWWidget(QWidget *parent) : ConfigTaskWidg
|
||||
m_ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("Revo+Nano+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
connect(m_ui->cchwHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_ui->saveTelemetryToRAM, m_ui->saveTelemetryToSD);
|
||||
m_ui->saveTelemetryToRAM->setVisible(expertMode());
|
||||
addUAVObject("HwSettings");
|
||||
|
||||
addWidgetBinding("HwSettings", "RM_FlexiPort", m_ui->cbFlexi);
|
||||
addWidgetBinding("HwSettings", "RM_MainPort", m_ui->cbMain);
|
||||
@ -266,9 +260,3 @@ void ConfigRevoNanoHWWidget::rcvrPortChanged(int index)
|
||||
Q_UNUSED(index);
|
||||
/* Nano has no USART at rcvrPort */
|
||||
}
|
||||
|
||||
void ConfigRevoNanoHWWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Revo+Nano+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
@ -58,7 +58,6 @@ private slots:
|
||||
void flexiPortChanged(int index);
|
||||
void mainPortChanged(int index);
|
||||
void rcvrPortChanged(int index);
|
||||
void openHelp();
|
||||
};
|
||||
|
||||
#endif // CONFIGREVONANOHWWIDGET_H
|
||||
|
@ -254,7 +254,7 @@
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="configgadget.qrc">:/configgadget/images/nano_top.png</pixmap>
|
||||
<pixmap>:/configgadget/images/nano_top.png</pixmap>
|
||||
</property>
|
||||
<property name="scaledContents">
|
||||
<bool>false</bool>
|
||||
@ -459,7 +459,7 @@
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="cchwHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -497,10 +497,13 @@
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -599,10 +602,13 @@ Beware of not locking yourself out!</string>
|
||||
<property name="checkable">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -628,6 +634,9 @@ Beware of not locking yourself out!</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
|
@ -29,7 +29,9 @@
|
||||
|
||||
#include "ui_revosensors.h"
|
||||
|
||||
#include <uavobjectmanager.h>
|
||||
#include <uavobjecthelper.h>
|
||||
|
||||
#include <attitudestate.h>
|
||||
#include <attitudesettings.h>
|
||||
#include <revocalibration.h>
|
||||
@ -42,22 +44,13 @@
|
||||
#include "calibration.h"
|
||||
#include "calibration/calibrationutils.h"
|
||||
|
||||
#include "math.h"
|
||||
#include <QDebug>
|
||||
#include <QTimer>
|
||||
#include <QStringList>
|
||||
#include <QWidget>
|
||||
#include <QTextEdit>
|
||||
#include <QVBoxLayout>
|
||||
#include <QPushButton>
|
||||
#include <QMessageBox>
|
||||
#include <QThread>
|
||||
#include <QErrorMessage>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <math.h>
|
||||
#include <iostream>
|
||||
|
||||
#include <math.h>
|
||||
#include <QDebug>
|
||||
#include <QStringList>
|
||||
#include <QWidget>
|
||||
#include <QThread>
|
||||
|
||||
// #define DEBUG
|
||||
|
||||
@ -82,16 +75,10 @@ ConfigRevoWidget::ConfigRevoWidget(QWidget *parent) :
|
||||
m_ui->tabWidget->setCurrentIndex(0);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("Revo+Attitude+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
// Connect the help button
|
||||
connect(m_ui->attitudeHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_ui->revoCalSettingsSaveRAM, m_ui->revoCalSettingsSaveSD);
|
||||
m_ui->revoCalSettingsSaveRAM->setVisible(expertMode());
|
||||
|
||||
// Initialization of the visual help
|
||||
m_ui->calibrationVisualHelp->setScene(new QGraphicsScene(this));
|
||||
m_ui->calibrationVisualHelp->setRenderHint(QPainter::HighQualityAntialiasing, true);
|
||||
@ -701,9 +688,3 @@ void ConfigRevoWidget::updateMagStatus()
|
||||
m_ui->magStatusSource->setToolTip("");
|
||||
}
|
||||
}
|
||||
|
||||
void ConfigRevoWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Revo+Attitude+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
@ -29,8 +29,7 @@
|
||||
#define CONFIGREVOWIDGET_H
|
||||
|
||||
#include "configtaskwidget.h"
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
#include "uavobjectmanager.h"
|
||||
|
||||
#include "uavobject.h"
|
||||
|
||||
#include "calibration/thermal/thermalcalibrationmodel.h"
|
||||
@ -102,7 +101,6 @@ private slots:
|
||||
float getMagError(float mag[3]);
|
||||
|
||||
void updateVisualHelp();
|
||||
void openHelp();
|
||||
|
||||
protected:
|
||||
void showEvent(QShowEvent *event);
|
||||
|
@ -34,9 +34,6 @@
|
||||
#include "hwsettings.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QMessageBox>
|
||||
|
||||
ConfigSparky2HWWidget::ConfigSparky2HWWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
{
|
||||
@ -44,14 +41,11 @@ ConfigSparky2HWWidget::ConfigSparky2HWWidget(QWidget *parent) : ConfigTaskWidget
|
||||
m_ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
// setWikiURL("");
|
||||
setWikiURL("Sparky2+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
connect(m_ui->cchwHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_ui->saveTelemetryToRAM, m_ui->saveTelemetryToSD);
|
||||
m_ui->saveTelemetryToRAM->setVisible(expertMode());
|
||||
addUAVObject("HwSettings");
|
||||
|
||||
addWidgetBinding("HwSettings", "SPK2_FlexiPort", m_ui->cbFlexi);
|
||||
addWidgetBinding("HwSettings", "SPK2_MainPort", m_ui->cbMain);
|
||||
@ -263,9 +257,3 @@ void ConfigSparky2HWWidget::mainPortChanged(int index)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void ConfigSparky2HWWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Sparky2+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
@ -57,7 +57,6 @@ private slots:
|
||||
void usbHIDPortChanged(int index);
|
||||
void flexiPortChanged(int index);
|
||||
void mainPortChanged(int index);
|
||||
void openHelp();
|
||||
};
|
||||
|
||||
#endif // CONFIGSPARKY2HWWIDGET_H
|
||||
|
@ -121,9 +121,9 @@
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>-258</y>
|
||||
<width>794</width>
|
||||
<height>927</height>
|
||||
<y>0</y>
|
||||
<width>796</width>
|
||||
<height>731</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_3">
|
||||
@ -434,7 +434,7 @@
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="configgadget.qrc">:/configgadget/images/sparky2_top.png</pixmap>
|
||||
<pixmap>:/configgadget/images/sparky2_top.png</pixmap>
|
||||
</property>
|
||||
<property name="scaledContents">
|
||||
<bool>false</bool>
|
||||
@ -555,7 +555,7 @@
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="cchwHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -593,10 +593,13 @@
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -695,10 +698,13 @@ Beware of not locking yourself out!</string>
|
||||
<property name="checkable">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveTelemetryToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -724,6 +730,9 @@ Beware of not locking yourself out!</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
|
@ -29,7 +29,9 @@
|
||||
|
||||
#include "ui_stabilization.h"
|
||||
|
||||
#include <uavobjectmanager.h>
|
||||
#include "objectpersistence.h"
|
||||
|
||||
#include "altitudeholdsettings.h"
|
||||
#include "stabilizationsettings.h"
|
||||
|
||||
@ -41,14 +43,8 @@
|
||||
#include <QDebug>
|
||||
#include <QStringList>
|
||||
#include <QWidget>
|
||||
#include <QTextEdit>
|
||||
#include <QVBoxLayout>
|
||||
#include <QPushButton>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
#include <QList>
|
||||
#include <QTabBar>
|
||||
#include <QMessageBox>
|
||||
#include <QToolButton>
|
||||
#include <QMenu>
|
||||
#include <QAction>
|
||||
@ -60,15 +56,14 @@ ConfigStabilizationWidget::ConfigStabilizationWidget(QWidget *parent) : ConfigTa
|
||||
ui->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
setupStabBanksGUI();
|
||||
setWikiURL("Stabilization+Configuration");
|
||||
|
||||
setupStabBanksGUI();
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
disableMouseWheelEvents();
|
||||
|
||||
ui->saveStabilizationToRAM_6->setVisible(expertMode());
|
||||
|
||||
connect(this, SIGNAL(enableControlsChanged(bool)), this, SLOT(enableControlsChanged(bool)));
|
||||
|
||||
setupExpoPlot();
|
||||
@ -113,7 +108,6 @@ ConfigStabilizationWidget::ConfigStabilizationWidget(QWidget *parent) : ConfigTa
|
||||
addWidget(ui->pushButton_20);
|
||||
addWidget(ui->pushButton_21);
|
||||
addWidget(ui->pushButton_22);
|
||||
addWidget(ui->pushButton_23);
|
||||
|
||||
addWidget(ui->basicResponsivenessGroupBox);
|
||||
addWidget(ui->basicResponsivenessCheckBox);
|
||||
|
@ -29,11 +29,8 @@
|
||||
#define CONFIGSTABILIZATIONWIDGET_H
|
||||
|
||||
#include "../uavobjectwidgetutils/configtaskwidget.h"
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
#include "uavobjectmanager.h"
|
||||
#include "uavobject.h"
|
||||
|
||||
#include "stabilizationsettings.h"
|
||||
#include "uavobject.h"
|
||||
|
||||
#include "qwt/src/qwt_plot_curve.h"
|
||||
#include "qwt/src/qwt_plot_grid.h"
|
||||
|
@ -50,19 +50,7 @@ ConfigTxPIDWidget::ConfigTxPIDWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
|
||||
disableMouseWheelEvents();
|
||||
|
||||
addApplySaveButtons(m_txpid->Apply, m_txpid->Save);
|
||||
m_txpid->Apply->setVisible(expertMode());
|
||||
|
||||
// Cannot use addUAVObjectToWidgetRelation() for OptionaModules enum because
|
||||
// QCheckBox returns bool (0 or -1) and this value is then set to enum instead
|
||||
// or enum options
|
||||
connect(HwSettings::GetInstance(getObjectManager()), SIGNAL(objectUpdated(UAVObject *)), this, SLOT(refreshValues()));
|
||||
connect(m_txpid->Apply, SIGNAL(clicked()), this, SLOT(applySettings()));
|
||||
connect(m_txpid->Save, SIGNAL(clicked()), this, SLOT(saveSettings()));
|
||||
|
||||
connect(m_txpid->PID1, SIGNAL(currentIndexChanged(int)), this, SLOT(updateSpinBoxProperties(int)));
|
||||
connect(m_txpid->PID2, SIGNAL(currentIndexChanged(int)), this, SLOT(updateSpinBoxProperties(int)));
|
||||
connect(m_txpid->PID3, SIGNAL(currentIndexChanged(int)), this, SLOT(updateSpinBoxProperties(int)));
|
||||
addUAVObject("HwSettings");
|
||||
|
||||
addWidgetBinding("TxPIDSettings", "BankNumber", m_txpid->pidBank, 0, 1, true);
|
||||
|
||||
@ -92,10 +80,14 @@ ConfigTxPIDWidget::ConfigTxPIDWidget(QWidget *parent) : ConfigTaskWidget(parent)
|
||||
|
||||
addWidgetBinding("TxPIDSettings", "UpdateMode", m_txpid->UpdateMode);
|
||||
|
||||
connect(this, SIGNAL(widgetContentsChanged(QWidget *)), this, SLOT(processLinkedWidgets(QWidget *)));
|
||||
|
||||
addWidget(m_txpid->TxPIDEnable);
|
||||
addWidget(m_txpid->enableAutoCalcYaw);
|
||||
|
||||
connect(m_txpid->PID1, SIGNAL(currentIndexChanged(int)), this, SLOT(updateSpinBoxProperties(int)));
|
||||
connect(m_txpid->PID2, SIGNAL(currentIndexChanged(int)), this, SLOT(updateSpinBoxProperties(int)));
|
||||
connect(m_txpid->PID3, SIGNAL(currentIndexChanged(int)), this, SLOT(updateSpinBoxProperties(int)));
|
||||
|
||||
connect(this, SIGNAL(widgetContentsChanged(QWidget *)), this, SLOT(processLinkedWidgets(QWidget *)));
|
||||
}
|
||||
|
||||
ConfigTxPIDWidget::~ConfigTxPIDWidget()
|
||||
@ -103,6 +95,41 @@ ConfigTxPIDWidget::~ConfigTxPIDWidget()
|
||||
// Do nothing
|
||||
}
|
||||
|
||||
/*
|
||||
* This overridden function refreshes widgets which have no direct relation
|
||||
* to any of UAVObjects. It saves their dirty state first because update comes
|
||||
* from UAVObjects, and then restores it.
|
||||
*/
|
||||
void ConfigTxPIDWidget::refreshWidgetsValuesImpl(UAVObject *obj)
|
||||
{
|
||||
Q_UNUSED(obj);
|
||||
|
||||
// Set module enable checkbox from OptionalModules UAVObject item.
|
||||
// It needs special processing because ConfigTaskWidget uses TRUE/FALSE
|
||||
// for QCheckBox, but OptionalModules uses Enabled/Disabled enum values.
|
||||
HwSettings *hwSettings = HwSettings::GetInstance(getObjectManager());
|
||||
HwSettings::DataFields hwSettingsData = hwSettings->getData();
|
||||
|
||||
m_txpid->TxPIDEnable->setChecked(
|
||||
hwSettingsData.OptionalModules[HwSettings::OPTIONALMODULES_TXPID] == HwSettings::OPTIONALMODULES_ENABLED);
|
||||
}
|
||||
|
||||
/*
|
||||
* This overridden function updates UAVObjects which have no direct relation
|
||||
* to any of widgets.
|
||||
*/
|
||||
void ConfigTxPIDWidget::updateObjectsFromWidgetsImpl()
|
||||
{
|
||||
// Save state of the module enable checkbox first.
|
||||
// Do not use setData() member on whole object, if possible, since it triggers unnecessary UAVObect update.
|
||||
quint8 enableModule = m_txpid->TxPIDEnable->isChecked() ?
|
||||
HwSettings::OPTIONALMODULES_ENABLED : HwSettings::OPTIONALMODULES_DISABLED;
|
||||
HwSettings *hwSettings = HwSettings::GetInstance(getObjectManager());
|
||||
|
||||
hwSettings->setOptionalModules(HwSettings::OPTIONALMODULES_TXPID, enableModule);
|
||||
}
|
||||
|
||||
|
||||
static bool isResponsivenessOption(int pidOption)
|
||||
{
|
||||
switch (pidOption) {
|
||||
@ -437,32 +464,6 @@ void ConfigTxPIDWidget::updateSpinBoxProperties(int selectedPidOption)
|
||||
maxPID->setValue(value);
|
||||
}
|
||||
|
||||
void ConfigTxPIDWidget::refreshValues()
|
||||
{
|
||||
HwSettings *hwSettings = HwSettings::GetInstance(getObjectManager());
|
||||
HwSettings::DataFields hwSettingsData = hwSettings->getData();
|
||||
|
||||
m_txpid->TxPIDEnable->setChecked(
|
||||
hwSettingsData.OptionalModules[HwSettings::OPTIONALMODULES_TXPID] == HwSettings::OPTIONALMODULES_ENABLED);
|
||||
}
|
||||
|
||||
void ConfigTxPIDWidget::applySettings()
|
||||
{
|
||||
HwSettings *hwSettings = HwSettings::GetInstance(getObjectManager());
|
||||
HwSettings::DataFields hwSettingsData = hwSettings->getData();
|
||||
|
||||
hwSettingsData.OptionalModules[HwSettings::OPTIONALMODULES_TXPID] =
|
||||
m_txpid->TxPIDEnable->isChecked() ? HwSettings::OPTIONALMODULES_ENABLED : HwSettings::OPTIONALMODULES_DISABLED;
|
||||
hwSettings->setData(hwSettingsData);
|
||||
}
|
||||
|
||||
void ConfigTxPIDWidget::saveSettings()
|
||||
{
|
||||
applySettings();
|
||||
UAVObject *obj = HwSettings::GetInstance(getObjectManager());
|
||||
saveObjectToSD(obj);
|
||||
}
|
||||
|
||||
void ConfigTxPIDWidget::processLinkedWidgets(QWidget *widget)
|
||||
{
|
||||
Q_UNUSED(widget);
|
||||
|
@ -37,15 +37,18 @@ class ConfigTxPIDWidget : public ConfigTaskWidget {
|
||||
public:
|
||||
ConfigTxPIDWidget(QWidget *parent = 0);
|
||||
~ConfigTxPIDWidget();
|
||||
|
||||
protected:
|
||||
virtual void refreshWidgetsValuesImpl(UAVObject *obj);
|
||||
virtual void updateObjectsFromWidgetsImpl();
|
||||
|
||||
private:
|
||||
Ui_TxPIDWidget *m_txpid;
|
||||
|
||||
private slots:
|
||||
void processLinkedWidgets(QWidget *widget);
|
||||
void updateSpinBoxProperties(int selectedPidOption);
|
||||
float getDefaultValueForPidOption(int pidOption);
|
||||
void refreshValues();
|
||||
void applySettings();
|
||||
void saveSettings();
|
||||
};
|
||||
|
||||
#endif // CONFIGTXPIDWIDGET_H
|
||||
|
@ -46,11 +46,7 @@
|
||||
#include <QTimer>
|
||||
#include <QWidget>
|
||||
#include <QTextEdit>
|
||||
#include <QVBoxLayout>
|
||||
#include <QPushButton>
|
||||
#include <math.h>
|
||||
#include <QDesktopServices>
|
||||
#include <QUrl>
|
||||
|
||||
/**
|
||||
Static function to get currently assigned channelDescriptions
|
||||
@ -120,17 +116,12 @@ ConfigVehicleTypeWidget::ConfigVehicleTypeWidget(QWidget *parent) : ConfigTaskWi
|
||||
m_aircraft->setupUi(this);
|
||||
|
||||
// must be done before auto binding !
|
||||
setWikiURL("TxPID");
|
||||
setWikiURL("Vehicle+Configuration");
|
||||
|
||||
addAutoBindings();
|
||||
|
||||
disableMouseWheelEvents();
|
||||
|
||||
connect(m_aircraft->airframeHelp, SIGNAL(clicked()), this, SLOT(openHelp()));
|
||||
|
||||
addApplySaveButtons(m_aircraft->saveAircraftToRAM, m_aircraft->saveAircraftToSD);
|
||||
m_aircraft->saveAircraftToRAM->setVisible(expertMode());
|
||||
|
||||
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
|
||||
ConfigGadgetFactory *configGadgetFactory = pm->getObject<ConfigGadgetFactory>();
|
||||
connect(m_aircraft->vehicleSetupWizardButton, SIGNAL(clicked()), configGadgetFactory, SIGNAL(onOpenVehicleConfigurationWizard()));
|
||||
@ -351,12 +342,3 @@ VehicleConfig *ConfigVehicleTypeWidget::createVehicleConfigWidget(int frameCateg
|
||||
}
|
||||
return vehicleConfig;
|
||||
}
|
||||
|
||||
/**
|
||||
Opens the wiki from the user's default browser
|
||||
*/
|
||||
void ConfigVehicleTypeWidget::openHelp()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QString(WIKI_URL_ROOT) + QString("Vehicle+Configuration"),
|
||||
QUrl::StrictMode));
|
||||
}
|
||||
|
@ -80,7 +80,6 @@ private:
|
||||
|
||||
private slots:
|
||||
void switchAirframeType(int index);
|
||||
void openHelp();
|
||||
};
|
||||
|
||||
#endif // CONFIGVEHICLETYPEWIDGET_H
|
||||
|
@ -116,8 +116,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1220</width>
|
||||
<height>655</height>
|
||||
<width>1228</width>
|
||||
<height>669</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
@ -547,8 +547,8 @@ font:bold;</string>
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1220</width>
|
||||
<height>655</height>
|
||||
<width>773</width>
|
||||
<height>587</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_7" rowstretch="1,0,0,0">
|
||||
@ -2319,8 +2319,8 @@ font:bold;</string>
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1220</width>
|
||||
<height>655</height>
|
||||
<width>616</width>
|
||||
<height>351</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_5">
|
||||
@ -2591,8 +2591,8 @@ The failsafe is triggered differently for different receivers. Failsafe should a
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1220</width>
|
||||
<height>655</height>
|
||||
<width>564</width>
|
||||
<height>159</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
@ -2761,7 +2761,7 @@ Set to 0 to disable (recommended for soaring fixed wings).</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="inputHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -2793,10 +2793,13 @@ Set to 0 to disable (recommended for soaring fixed wings).</string>
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveRCInputToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -2819,10 +2822,13 @@ Be sure to set the Neutral position on all sliders before sending!</string>
|
||||
<property name="text">
|
||||
<string>Apply</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveRCInputToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -2845,6 +2851,9 @@ Applies and Saves all settings to SD</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
@ -2856,9 +2865,9 @@ Applies and Saves all settings to SD</string>
|
||||
<tabstop>deadband</tabstop>
|
||||
<tabstop>armControl</tabstop>
|
||||
<tabstop>armTimeout</tabstop>
|
||||
<tabstop>inputHelp</tabstop>
|
||||
<tabstop>saveRCInputToRAM</tabstop>
|
||||
<tabstop>saveRCInputToSD</tabstop>
|
||||
<tabstop>helpButton</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../coreplugin/core.qrc"/>
|
||||
|
@ -49,8 +49,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>947</width>
|
||||
<height>575</height>
|
||||
<width>949</width>
|
||||
<height>566</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
@ -1874,7 +1874,7 @@ Leave blank to use autogenerated Device ID.</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1917,17 +1917,20 @@ Leave blank to use autogenerated Device ID.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="Apply">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="toolTip">
|
||||
<string>Send settings to the board but do not save to the non-volatile memory.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Apply</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="Save">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="toolTip">
|
||||
<string>Send settings to the board and save to the non-volatile memory.</string>
|
||||
</property>
|
||||
@ -1937,6 +1940,9 @@ Leave blank to use autogenerated Device ID.</string>
|
||||
<property name="checked">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
@ -1946,8 +1952,8 @@ Leave blank to use autogenerated Device ID.</string>
|
||||
<tabstops>
|
||||
<tabstop>FirmwareVersion</tabstop>
|
||||
<tabstop>SerialNumber</tabstop>
|
||||
<tabstop>Apply</tabstop>
|
||||
<tabstop>Save</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../coreplugin/core.qrc"/>
|
||||
|
@ -123,7 +123,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>743</width>
|
||||
<height>662</height>
|
||||
<height>668</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3" stretch="0,0,0">
|
||||
@ -969,7 +969,7 @@
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="outputHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1007,10 +1007,13 @@
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveRCOutputToRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1033,10 +1036,13 @@ Be sure to set the Neutral position on all sliders before sending!</string>
|
||||
<property name="text">
|
||||
<string>Apply</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveRCOutputToSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1059,6 +1065,9 @@ Applies and Saves all settings to SD</string>
|
||||
<property name="text">
|
||||
<string>Save</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
@ -1066,8 +1075,8 @@ Applies and Saves all settings to SD</string>
|
||||
</layout>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>saveRCOutputToRAM</tabstop>
|
||||
<tabstop>saveRCOutputToSD</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../coreplugin/core.qrc"/>
|
||||
|
@ -6,7 +6,7 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>935</width>
|
||||
<width>954</width>
|
||||
<height>726</height>
|
||||
</rect>
|
||||
</property>
|
||||
@ -438,8 +438,8 @@
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-weight:600;"><br /></p></body></html></string>
|
||||
</style></head><body style=" font-family:'Ubuntu'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2'; font-weight:600;"><br /></p></body></html></string>
|
||||
</property>
|
||||
<property name="textInteractionFlags">
|
||||
<set>Qt::NoTextInteraction</set>
|
||||
@ -1157,10 +1157,10 @@ font:bold;</string>
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Cantarell'; font-size:11pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">The bargraphs show the difference between the onboard and auxiliary magnetometer measurements. </p>
|
||||
<p align="justify" style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">When the auxiliary magnetometer rotation is set correctlly, all bargraphs should show all zero (bargraph centered) <a name="result_box"></a>whatever the vehicle's orientation.</p>
|
||||
<p align="justify" style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">This assumes both magnetometers are calibrated and without alarm.</p></body></html></string>
|
||||
</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Cantarell';">The bargraphs show the difference between the onboard and auxiliary magnetometer measurements. </span></p>
|
||||
<p align="justify" style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Cantarell';">When the auxiliary magnetometer rotation is set correctlly, all bargraphs should show all zero (bargraph centered) </span><a name="result_box"></a><span style=" font-family:'Cantarell';">w</span><span style=" font-family:'Cantarell';">hatever the vehicle's orientation.</span></p>
|
||||
<p align="justify" style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Cantarell';">This assumes both magnetometers are calibrated and without alarm.</span></p></body></html></string>
|
||||
</property>
|
||||
<property name="textInteractionFlags">
|
||||
<set>Qt::LinksAccessibleByKeyboard|Qt::LinksAccessibleByMouse|Qt::TextBrowserInteraction|Qt::TextSelectableByKeyboard|Qt::TextSelectableByMouse</set>
|
||||
@ -1707,38 +1707,38 @@ font:bold;</string>
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:14pt; font-weight:600;">Help</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Steps 1, 2 and 3 are necessary.</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Step 4 is optional but may help achieve the best possible results.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:12pt; font-weight:600; font-style:italic;">Step 1: Accelerometer and Magnetometer calibration</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">This step will calibrate the scale for the Magnetometer and the Accelerometer sensors. </span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Press </span><span style=" font-size:11pt; font-style:italic;">Start</span><span style=" font-size:11pt;"> to begin, and follow the instructions for each step. </span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">For best results with the accelerometer calibration, it is advised that it be performed with a free unmounted flight controller as this allows one to accurately position the board for each orientation in the sequence.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">The magnetometer calibration must be performed with the board mounted in the airframe in order for the measurements to incorporate any bias produced by local onboard metal/magnetic elements.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Note 1: Before the magnetometer or the accelerometer calibration is performed your Home Location must be set. This step is needed in order to determine the local magnetic field vector (Be) and acceleration due to gravity (g_e).</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">Note 2: There is no need to align the airframe exactly south, north, east or west during the individual steps. The directions indicated serve only to tell you in which direction the airframe should be positioned relative to some point. One can simply assume that North is in front of you, East is to the right, West is to the left and South is pointing at you.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:12pt; font-weight:600; font-style:italic;">Step 2: Board level calibration</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">This step will ensure that board leveling is accurate. Place the airframe as horizontally as possible (use a spirit level if necessary), then press </span><span style=" font-size:11pt; font-style:italic;">Start</span><span style=" font-size:11pt;">. Do not move the airframe at all until the end of the calibration.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:12pt; font-weight:600; font-style:italic;">Step 3: Gyro bias calculation</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">This step will allow you to calibrate the gyro measured value when the board is steady. To perform the calibration leave the board/airframe completely stationary and press </span><span style=" font-size:11pt; font-style:italic;">Start</span><span style=" font-size:11pt;">. </span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:12pt; font-weight:600; font-style:italic;">Step 4: Thermal calibration</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">The calibration will compute sensors bias variations at different temperatures while the board warms up.</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">This allows a certain amount of correction of those bias variations against temperature changes. It improves altitude hold accuracy and reduces yaw drift.</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-size:11pt;">To perform this calibration disconnect any power from the board and leave it to cool down at room temperature for 15-20 minutes. Then attach the usb connector to the board and press </span><span style=" font-size:11pt; font-style:italic;">Start</span><span style=" font-size:11pt;">, leaving the board completely stationary. Wait until complete.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><br /></p></body></html></string>
|
||||
</style></head><body style=" font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:14pt; font-weight:600;">Help</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">Steps 1, 2 and 3 are necessary.</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">Step 4 is optional but may help achieve the best possible results.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:12pt; font-weight:600; font-style:italic;">Step 1: Accelerometer and Magnetometer calibration</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">This step will calibrate the scale for the Magnetometer and the Accelerometer sensors. </span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">Press </span><span style=" font-family:'MS Shell Dlg 2'; font-style:italic;">Start</span><span style=" font-family:'MS Shell Dlg 2';"> to begin, and follow the instructions for each step. </span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">For best results with the accelerometer calibration, it is advised that it be performed with a free unmounted flight controller as this allows one to accurately position the board for each orientation in the sequence.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">The magnetometer calibration must be performed with the board mounted in the airframe in order for the measurements to incorporate any bias produced by local onboard metal/magnetic elements.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">Note 1: Before the magnetometer or the accelerometer calibration is performed your Home Location must be set. This step is needed in order to determine the local magnetic field vector (Be) and acceleration due to gravity (g_e).</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">Note 2: There is no need to align the airframe exactly south, north, east or west during the individual steps. The directions indicated serve only to tell you in which direction the airframe should be positioned relative to some point. One can simply assume that North is in front of you, East is to the right, West is to the left and South is pointing at you.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:12pt; font-weight:600; font-style:italic;">Step 2: Board level calibration</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">This step will ensure that board leveling is accurate. Place the airframe as horizontally as possible (use a spirit level if necessary), then press </span><span style=" font-family:'MS Shell Dlg 2'; font-style:italic;">Start</span><span style=" font-family:'MS Shell Dlg 2';">. Do not move the airframe at all until the end of the calibration.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:12pt; font-weight:600; font-style:italic;">Step 3: Gyro bias calculation</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">This step will allow you to calibrate the gyro measured value when the board is steady. To perform the calibration leave the board/airframe completely stationary and press </span><span style=" font-family:'MS Shell Dlg 2'; font-style:italic;">Start</span><span style=" font-family:'MS Shell Dlg 2';">. </span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:12pt; font-weight:600; font-style:italic;">Step 4: Thermal calibration</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">The calibration will compute sensors bias variations at different temperatures while the board warms up.</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">This allows a certain amount of correction of those bias variations against temperature changes. It improves altitude hold accuracy and reduces yaw drift.</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2';">To perform this calibration disconnect any power from the board and leave it to cool down at room temperature for 15-20 minutes. Then attach the usb connector to the board and press </span><span style=" font-family:'MS Shell Dlg 2'; font-style:italic;">Start</span><span style=" font-family:'MS Shell Dlg 2';">, leaving the board completely stationary. Wait until complete.</span></p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2';"><br /></p></body></html></string>
|
||||
</property>
|
||||
<property name="textInteractionFlags">
|
||||
<set>Qt::LinksAccessibleByKeyboard|Qt::LinksAccessibleByMouse|Qt::TextBrowserInteraction|Qt::TextSelectableByKeyboard|Qt::TextSelectableByMouse</set>
|
||||
@ -1768,7 +1768,7 @@ p, li { white-space: pre-wrap; }
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="attitudeHelp">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1808,10 +1808,13 @@ p, li { white-space: pre-wrap; }
|
||||
<property name="flat">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="revoCalSettingsSaveRAM">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="toolTip">
|
||||
<string>Save settings to the board (RAM only).
|
||||
|
||||
@ -1827,7 +1830,7 @@ specific calibration button on top of the screen.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="revoCalSettingsSaveSD">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="toolTip">
|
||||
<string>Send settings to the board, and save to the non-volatile memory.</string>
|
||||
</property>
|
||||
|
@ -136,8 +136,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>877</width>
|
||||
<height>764</height>
|
||||
<width>863</width>
|
||||
<height>821</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
@ -7932,8 +7932,8 @@ border-radius: 5;</string>
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>877</width>
|
||||
<height>765</height>
|
||||
<width>776</width>
|
||||
<height>706</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_29">
|
||||
@ -17354,8 +17354,8 @@ border-radius: 5;</string>
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>877</width>
|
||||
<height>671</height>
|
||||
<width>797</width>
|
||||
<height>604</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_8" stretch="0,0,0,0,0,0">
|
||||
@ -23200,8 +23200,8 @@ font:bold;</string>
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>877</width>
|
||||
<height>671</height>
|
||||
<width>500</width>
|
||||
<height>600</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_18">
|
||||
@ -26214,7 +26214,7 @@ border-radius: 5;</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_23">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -26263,7 +26263,7 @@ border-radius: 5;</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="stabilizationReloadBoardData_6">
|
||||
<widget class="QPushButton" name="reloadButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -26307,7 +26307,7 @@ Useful if you have accidentally changed some settings.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveStabilizationToRAM_6">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -26343,7 +26343,7 @@ Useful if you have accidentally changed some settings.</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="saveStabilizationToSD_6">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
@ -26520,10 +26520,10 @@ Useful if you have accidentally changed some settings.</string>
|
||||
<tabstop>AltThrRateSlider_2</tabstop>
|
||||
<tabstop>AltThrRate_2</tabstop>
|
||||
<tabstop>realTimeUpdates_7</tabstop>
|
||||
<tabstop>pushButton_23</tabstop>
|
||||
<tabstop>stabilizationReloadBoardData_6</tabstop>
|
||||
<tabstop>saveStabilizationToRAM_6</tabstop>
|
||||
<tabstop>saveStabilizationToSD_6</tabstop>
|
||||
<tabstop>helpButton</tabstop>
|
||||
<tabstop>reloadButton</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
<tabstop>checkBoxLinkAcroFactors</tabstop>
|
||||
<tabstop>tabWidget</tabstop>
|
||||
<tabstop>AttitudeResponsivenessSlider</tabstop>
|
||||
|
@ -118,9 +118,9 @@
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>-317</y>
|
||||
<width>748</width>
|
||||
<height>724</height>
|
||||
<y>0</y>
|
||||
<width>751</width>
|
||||
<height>768</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
@ -1426,7 +1426,7 @@ font:bold;</string>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton">
|
||||
<widget class="QPushButton" name="helpButton">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
@ -1484,7 +1484,7 @@ font:bold;</string>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="Apply">
|
||||
<widget class="QPushButton" name="applyButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1500,10 +1500,13 @@ font:bold;</string>
|
||||
<property name="text">
|
||||
<string>Apply</string>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:apply</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="Save">
|
||||
<widget class="QPushButton" name="saveButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
@ -1522,6 +1525,9 @@ font:bold;</string>
|
||||
<property name="checked">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="objrelation" stdset="0">
|
||||
<string>button:save</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
@ -1529,8 +1535,8 @@ font:bold;</string>
|
||||
</layout>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>Apply</tabstop>
|
||||
<tabstop>Save</tabstop>
|
||||
<tabstop>applyButton</tabstop>
|
||||
<tabstop>saveButton</tabstop>
|
||||
<tabstop>scrollArea</tabstop>
|
||||
<tabstop>PID1</tabstop>
|
||||
<tabstop>Input1</tabstop>
|
||||
|
@ -60,6 +60,12 @@ ConfigTaskWidget::ConfigTaskWidget(QWidget *parent, bool autopilot) : QWidget(pa
|
||||
UAVSettingsImportExportFactory *importexportplugin = m_pluginManager->getObject<UAVSettingsImportExportFactory>();
|
||||
connect(importexportplugin, SIGNAL(importAboutToBegin()), this, SLOT(invalidateObjects()));
|
||||
|
||||
m_saveButton = new SmartSaveButton(this);
|
||||
connect(m_saveButton, SIGNAL(preProcessOperations()), this, SLOT(updateObjectsFromWidgets()));
|
||||
connect(m_saveButton, SIGNAL(saveSuccessfull()), this, SLOT(clearDirty()));
|
||||
connect(m_saveButton, SIGNAL(beginOp()), this, SLOT(disableObjectUpdates()));
|
||||
connect(m_saveButton, SIGNAL(endOp()), this, SLOT(enableObjectUpdates()));
|
||||
|
||||
if (m_autopilot) {
|
||||
// connect to telemetry manager
|
||||
TelemetryManager *tm = m_pluginManager->getObject<TelemetryManager>();
|
||||
@ -286,20 +292,9 @@ void ConfigTaskWidget::enableComboBoxOptionItem(QComboBox *combo, int optionValu
|
||||
!enable ? QVariant(0) : QVariant(1 | 32), Qt::UserRole - 1);
|
||||
}
|
||||
|
||||
void ConfigTaskWidget::saveObjectToSD(UAVObject *obj)
|
||||
{
|
||||
// saveObjectToSD is now handled by the UAVUtils plugin in one
|
||||
// central place (and one central queue)
|
||||
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
|
||||
UAVObjectUtilManager *utilMngr = pm->getObject<UAVObjectUtilManager>();
|
||||
|
||||
utilMngr->saveObjectToSD(obj);
|
||||
}
|
||||
|
||||
UAVObjectManager *ConfigTaskWidget::getObjectManager()
|
||||
{
|
||||
ExtensionSystem::PluginManager *pm = ExtensionSystem::PluginManager::instance();
|
||||
UAVObjectManager *objMngr = pm->getObject<UAVObjectManager>();
|
||||
UAVObjectManager *objMngr = m_pluginManager->getObject<UAVObjectManager>();
|
||||
|
||||
Q_ASSERT(objMngr);
|
||||
return objMngr;
|
||||
@ -409,27 +404,15 @@ void ConfigTaskWidget::helpButtonPressed()
|
||||
}
|
||||
}
|
||||
|
||||
void ConfigTaskWidget::addApplySaveButtons(QPushButton *update, QPushButton *save)
|
||||
void ConfigTaskWidget::addApplyButton(QPushButton *button)
|
||||
{
|
||||
if (!m_saveButton) {
|
||||
m_saveButton = new SmartSaveButton(this);
|
||||
connect(m_saveButton, SIGNAL(preProcessOperations()), this, SLOT(updateObjectsFromWidgets()));
|
||||
connect(m_saveButton, SIGNAL(saveSuccessfull()), this, SLOT(clearDirty()));
|
||||
connect(m_saveButton, SIGNAL(beginOp()), this, SLOT(disableObjectUpdates()));
|
||||
connect(m_saveButton, SIGNAL(endOp()), this, SLOT(enableObjectUpdates()));
|
||||
}
|
||||
if (update && save) {
|
||||
m_saveButton->addButtons(save, update);
|
||||
} else if (update) {
|
||||
m_saveButton->addApplyButton(update);
|
||||
} else if (save) {
|
||||
m_saveButton->addSaveButton(save);
|
||||
}
|
||||
foreach(WidgetBinding * binding, m_widgetBindingsPerWidget) {
|
||||
if (binding->object()) {
|
||||
m_saveButton->addObject((UAVDataObject *)binding->object());
|
||||
}
|
||||
}
|
||||
m_saveButton->addApplyButton(button);
|
||||
button->setVisible(expertMode());
|
||||
}
|
||||
|
||||
void ConfigTaskWidget::addSaveButton(QPushButton *button)
|
||||
{
|
||||
m_saveButton->addSaveButton(button);
|
||||
}
|
||||
|
||||
void ConfigTaskWidget::enableControls(bool enable)
|
||||
@ -636,9 +619,6 @@ void ConfigTaskWidget::addAutoBindings()
|
||||
{
|
||||
// qDebug() << "ConfigTaskWidget::addAutoBindings() - auto binding" << this;
|
||||
|
||||
QPushButton *saveButtonWidget = NULL;
|
||||
QPushButton *applyButtonWidget = NULL;
|
||||
|
||||
foreach(QWidget * widget, this->findChildren<QWidget *>()) {
|
||||
QVariant info = widget->property("objrelation");
|
||||
|
||||
@ -697,15 +677,15 @@ void ConfigTaskWidget::addAutoBindings()
|
||||
QPushButton *button = NULL;
|
||||
switch (uiRelation.buttonType) {
|
||||
case save_button:
|
||||
saveButtonWidget = qobject_cast<QPushButton *>(widget);
|
||||
if (saveButtonWidget) {
|
||||
addApplySaveButtons(NULL, saveButtonWidget);
|
||||
button = qobject_cast<QPushButton *>(widget);
|
||||
if (button) {
|
||||
addSaveButton(button);
|
||||
}
|
||||
break;
|
||||
case apply_button:
|
||||
applyButtonWidget = qobject_cast<QPushButton *>(widget);
|
||||
if (applyButtonWidget) {
|
||||
addApplySaveButtons(applyButtonWidget, NULL);
|
||||
button = qobject_cast<QPushButton *>(widget);
|
||||
if (button) {
|
||||
addApplyButton(button);
|
||||
}
|
||||
break;
|
||||
case default_button:
|
||||
@ -741,6 +721,11 @@ void ConfigTaskWidget::addAutoBindings()
|
||||
}
|
||||
}
|
||||
}
|
||||
foreach(WidgetBinding * binding, m_widgetBindingsPerWidget) {
|
||||
if (binding->object()) {
|
||||
m_saveButton->addObject((UAVDataObject *)binding->object());
|
||||
}
|
||||
}
|
||||
}
|
||||
// qDebug() << "ConfigTaskWidget::addAutoBindings() - auto binding done for" << this;
|
||||
}
|
||||
|
@ -29,12 +29,13 @@
|
||||
|
||||
#include "uavobjectwidgetutils_global.h"
|
||||
|
||||
#include "extensionsystem/pluginmanager.h"
|
||||
|
||||
#include <QWidget>
|
||||
#include <QList>
|
||||
#include <QVariant>
|
||||
|
||||
namespace ExtensionSystem {
|
||||
class PluginManager;
|
||||
}
|
||||
class UAVObject;
|
||||
class UAVObjectField;
|
||||
class UAVObjectManager;
|
||||
@ -120,7 +121,6 @@ protected:
|
||||
void disableMouseWheelEvents();
|
||||
bool eventFilter(QObject *obj, QEvent *evt);
|
||||
|
||||
void saveObjectToSD(UAVObject *obj);
|
||||
UAVObjectManager *getObjectManager();
|
||||
|
||||
void addUAVObject(QString objectName, QList<int> *reloadGroups = NULL);
|
||||
@ -146,10 +146,6 @@ protected:
|
||||
void addWidgetBinding(QString objectName, QString fieldName, QWidget *widget, QString elementName);
|
||||
void addWidgetBinding(UAVObject *object, UAVObjectField *field, QWidget *widget, QString elementName);
|
||||
|
||||
void addApplySaveButtons(QPushButton *update, QPushButton *save);
|
||||
void addReloadButton(QPushButton *button, int buttonGroup);
|
||||
void addDefaultButton(QPushButton *button, int buttonGroup);
|
||||
|
||||
void addWidgetToReloadGroups(QWidget *widget, QList<int> *reloadGroupIDs);
|
||||
|
||||
bool addShadowWidgetBinding(QString objectName, QString fieldName, QWidget *widget, int index = 0, double scale = 1,
|
||||
@ -259,8 +255,10 @@ private:
|
||||
|
||||
ExtensionSystem::PluginManager *m_pluginManager;
|
||||
UAVObjectUtilManager *m_objectUtilManager;
|
||||
SmartSaveButton *m_saveButton;
|
||||
|
||||
QHash<UAVObject *, bool> m_updatedObjects;
|
||||
|
||||
SmartSaveButton *m_saveButton;
|
||||
QHash<QPushButton *, QString> m_helpButtons;
|
||||
QList<QPushButton *> m_reloadButtons;
|
||||
|
||||
@ -287,6 +285,11 @@ private:
|
||||
|
||||
void doAddWidgetBinding(QString objectName, QString fieldName, QWidget *widget, int index = 0, double scale = 1,
|
||||
bool isLimited = false, QList<int> *reloadGroupIDs = 0, quint32 instID = 0);
|
||||
|
||||
void addApplyButton(QPushButton *button);
|
||||
void addSaveButton(QPushButton *button);
|
||||
void addReloadButton(QPushButton *button, int buttonGroup);
|
||||
void addDefaultButton(QPushButton *button, int buttonGroup);
|
||||
};
|
||||
|
||||
#endif // CONFIGTASKWIDGET_H
|
||||
|
@ -30,13 +30,6 @@
|
||||
SmartSaveButton::SmartSaveButton(ConfigTaskWidget *configTaskWidget) : configWidget(configTaskWidget)
|
||||
{}
|
||||
|
||||
void SmartSaveButton::addButtons(QPushButton *save, QPushButton *apply)
|
||||
{
|
||||
buttonList.insert(save, save_button);
|
||||
buttonList.insert(apply, apply_button);
|
||||
connect(save, SIGNAL(clicked()), this, SLOT(processClick()));
|
||||
connect(apply, SIGNAL(clicked()), this, SLOT(processClick()));
|
||||
}
|
||||
void SmartSaveButton::addApplyButton(QPushButton *apply)
|
||||
{
|
||||
buttonList.insert(apply, apply_button);
|
||||
|
@ -46,7 +46,6 @@ public:
|
||||
|
||||
public:
|
||||
SmartSaveButton(ConfigTaskWidget *configTaskWidget);
|
||||
void addButtons(QPushButton *save, QPushButton *apply);
|
||||
void setObjects(QList<UAVDataObject *>);
|
||||
void addObject(UAVDataObject *);
|
||||
void clearObjects();
|
||||
|
Loading…
x
Reference in New Issue
Block a user