12 changed files with 178 additions and 12 deletions
@ -1 +1 @@
@@ -1 +1 @@
|
||||
Subproject commit 3cac6a5bc5826d7ac495827a46b63f476d82ba86 |
||||
Subproject commit 381061af5aa2ab7a2b1fcf243d01fcd721caebae |
@ -0,0 +1,22 @@
@@ -0,0 +1,22 @@
|
||||
[ |
||||
{ |
||||
"name": "SurveyInAccuracyLimit", |
||||
"shortDescription": "Survey in accuracy limit", |
||||
"longDescription": "The maximum accuracy allowed prior to completing survey in.", |
||||
"type": "double", |
||||
"defaultValue": 2.0, |
||||
"min": 0.5, |
||||
"units": "m", |
||||
"decimalPlaces": 1 |
||||
}, |
||||
{ |
||||
"name": "SurveyInMinObservationDuration", |
||||
"shortDescription": "Minimum observation time", |
||||
"longDescription": "Defines the minimum amount of observation time for the position calculation.", |
||||
"type": "Uint32", |
||||
"defaultValue": 180, |
||||
"min": 1, |
||||
"units": "secs", |
||||
"decimalPlaces": 0 |
||||
} |
||||
] |
@ -0,0 +1,44 @@
@@ -0,0 +1,44 @@
|
||||
/****************************************************************************
|
||||
* |
||||
* (c) 2009-2016 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
* |
||||
* QGroundControl is licensed according to the terms in the file |
||||
* COPYING.md in the root of the source code directory. |
||||
* |
||||
****************************************************************************/ |
||||
|
||||
#include "RTKSettings.h" |
||||
|
||||
#include <QQmlEngine> |
||||
#include <QtQml> |
||||
|
||||
const char* RTKSettings::RTKSettingsGroupName = "RTK"; |
||||
const char* RTKSettings::surveyInAccuracyLimitName = "SurveyInAccuracyLimit"; |
||||
const char* RTKSettings::surveyInMinObservationDurationName = "SurveyInMinObservationDuration"; |
||||
|
||||
RTKSettings::RTKSettings(QObject* parent) |
||||
: SettingsGroup(RTKSettingsGroupName, QString(RTKSettingsGroupName), parent) |
||||
, _surveyInAccuracyLimitFact(NULL) |
||||
, _surveyInMinObservationDurationFact(NULL) |
||||
{ |
||||
QQmlEngine::setObjectOwnership(this, QQmlEngine::CppOwnership); |
||||
qmlRegisterUncreatableType<RTKSettings>("QGroundControl.SettingsManager", 1, 0, "RTKSettings", "Reference only"); |
||||
} |
||||
|
||||
Fact* RTKSettings::surveyInAccuracyLimit(void) |
||||
{ |
||||
if (!_surveyInAccuracyLimitFact) { |
||||
_surveyInAccuracyLimitFact = _createSettingsFact(surveyInAccuracyLimitName); |
||||
} |
||||
|
||||
return _surveyInAccuracyLimitFact; |
||||
} |
||||
|
||||
Fact* RTKSettings::surveyInMinObservationDuration(void) |
||||
{ |
||||
if (!_surveyInMinObservationDurationFact) { |
||||
_surveyInMinObservationDurationFact = _createSettingsFact(surveyInMinObservationDurationName); |
||||
} |
||||
|
||||
return _surveyInMinObservationDurationFact; |
||||
} |
@ -0,0 +1,35 @@
@@ -0,0 +1,35 @@
|
||||
/****************************************************************************
|
||||
* |
||||
* (c) 2009-2016 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
* |
||||
* QGroundControl is licensed according to the terms in the file |
||||
* COPYING.md in the root of the source code directory. |
||||
* |
||||
****************************************************************************/ |
||||
|
||||
#pragma once |
||||
|
||||
#include "SettingsGroup.h" |
||||
|
||||
class RTKSettings : public SettingsGroup |
||||
{ |
||||
Q_OBJECT |
||||
|
||||
public: |
||||
RTKSettings(QObject* parent = NULL); |
||||
|
||||
Q_PROPERTY(Fact* surveyInAccuracyLimit READ surveyInAccuracyLimit CONSTANT) |
||||
Q_PROPERTY(Fact* surveyInMinObservationDuration READ surveyInMinObservationDuration CONSTANT) |
||||
|
||||
Fact* surveyInAccuracyLimit (void); |
||||
Fact* surveyInMinObservationDuration(void); |
||||
|
||||
static const char* RTKSettingsGroupName; |
||||
|
||||
static const char* surveyInAccuracyLimitName; |
||||
static const char* surveyInMinObservationDurationName; |
||||
|
||||
private: |
||||
SettingsFact* _surveyInAccuracyLimitFact; |
||||
SettingsFact* _surveyInMinObservationDurationFact; |
||||
}; |
Loading…
Reference in new issue