mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-04-06 19:48:35 -04:00
REST API: GLScope settings
This commit is contained in:
parent
ae9322479e
commit
524326de6d
91
plugins/channelrx/chanalyzer/chanalyzerwebapiadapter.cpp
Normal file
91
plugins/channelrx/chanalyzer/chanalyzerwebapiadapter.cpp
Normal file
@ -0,0 +1,91 @@
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
// Copyright (C) 2019 Edouard Griffiths, F4EXB. //
|
||||
// //
|
||||
// This program is free software; you can redistribute it and/or modify //
|
||||
// it under the terms of the GNU General Public License as published by //
|
||||
// the Free Software Foundation as version 3 of the License, or //
|
||||
// (at your option) any later version. //
|
||||
// //
|
||||
// This program is distributed in the hope that it will be useful, //
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
|
||||
// GNU General Public License V3 for more details. //
|
||||
// //
|
||||
// You should have received a copy of the GNU General Public License //
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "SWGChannelSettings.h"
|
||||
#include "chanalyzerwebapiadapter.h"
|
||||
|
||||
ChannelAnalyzerWebAPIAdapter::ChannelAnalyzerWebAPIAdapter()
|
||||
{
|
||||
m_settings.setScopeGUI(&m_glScopeSettings);
|
||||
m_settings.setSpectrumGUI(&m_glSpectrumSettings);
|
||||
}
|
||||
|
||||
ChannelAnalyzerWebAPIAdapter::~ChannelAnalyzerWebAPIAdapter()
|
||||
{}
|
||||
|
||||
void ChannelAnalyzerWebAPIAdapter::webapiFormatChannelSettings(
|
||||
SWGSDRangel::SWGChannelSettings& response,
|
||||
const ChannelAnalyzerSettings& settings,
|
||||
const GLScopeSettings& scopeSettings,
|
||||
const GLSpectrumSettings& spectrumSettings)
|
||||
{
|
||||
response.getChannelAnalyzerSettings()->setFrequency(settings.m_frequency);
|
||||
response.getChannelAnalyzerSettings()->setDownSample(settings.m_downSample ? 1 : 0);
|
||||
response.getChannelAnalyzerSettings()->setDownSampleRate(settings.m_downSampleRate);
|
||||
response.getChannelAnalyzerSettings()->setBandwidth(settings.m_bandwidth);
|
||||
response.getChannelAnalyzerSettings()->setLowCutoff(settings.m_lowCutoff);
|
||||
response.getChannelAnalyzerSettings()->setSpanLog2(settings.m_spanLog2);
|
||||
response.getChannelAnalyzerSettings()->setSsb(settings.m_ssb ? 1 : 0);
|
||||
response.getChannelAnalyzerSettings()->setPll(settings.m_pll ? 1 : 0);
|
||||
response.getChannelAnalyzerSettings()->setFll(settings.m_fll ? 1 : 0);
|
||||
response.getChannelAnalyzerSettings()->setRrc(settings.m_rrc ? 1 : 0);
|
||||
response.getChannelAnalyzerSettings()->setRrcRolloff(settings.m_rrcRolloff);
|
||||
response.getChannelAnalyzerSettings()->setPllPskOrder(settings.m_pllPskOrder);
|
||||
response.getChannelAnalyzerSettings()->setInputType((int) settings.m_inputType);
|
||||
response.getChannelAnalyzerSettings()->setRgbColor(settings.m_rgbColor);
|
||||
response.getChannelAnalyzerSettings()->setTitle(new QString(settings.m_title));
|
||||
SWGSDRangel::SWGGLScope *swgScope = new SWGSDRangel::SWGGLScope();
|
||||
swgScope->init();
|
||||
response.getChannelAnalyzerSettings()->setScopeConfig(swgScope);
|
||||
swgScope->setDisplayMode(scopeSettings.m_displayMode);
|
||||
swgScope->setGridIntensity(scopeSettings.m_gridIntensity);
|
||||
swgScope->setTime(scopeSettings.m_time);
|
||||
swgScope->setTimeOfs(scopeSettings.m_timeOfs);
|
||||
swgScope->setTraceIntensity(scopeSettings.m_traceIntensity);
|
||||
swgScope->setTraceLen(scopeSettings.m_traceLen);
|
||||
swgScope->setTrigPre(scopeSettings.m_trigPre);
|
||||
// TODO array of traces
|
||||
// TODO array of triggers
|
||||
SWGSDRangel::SWGGLSpectrum *swgSpectrum = new SWGSDRangel::SWGGLSpectrum();
|
||||
swgSpectrum->init();
|
||||
response.getChannelAnalyzerSettings()->setSpectrumConfig(swgSpectrum);
|
||||
swgSpectrum->setAveragingMode((int) spectrumSettings.m_averagingMode);
|
||||
swgSpectrum->setAveragingValue(spectrumSettings.m_averagingNb);
|
||||
swgSpectrum->setDecay(spectrumSettings.m_decay);
|
||||
swgSpectrum->setDecayDivisor(spectrumSettings.m_decayDivisor);
|
||||
swgSpectrum->setDisplayCurrent(spectrumSettings.m_displayCurrent ? 1 : 0);
|
||||
swgSpectrum->setDisplayGrid(spectrumSettings.m_displayGrid ? 1 : 0);
|
||||
swgSpectrum->setDisplayGridIntensity(spectrumSettings.m_displayGridIntensity);
|
||||
swgSpectrum->setDisplayHistogram(spectrumSettings.m_displayHistogram ? 1 : 0);
|
||||
swgSpectrum->setDisplayMaxHold(spectrumSettings.m_displayMaxHold ? 1 : 0);
|
||||
swgSpectrum->setDisplayTraceIntensity(spectrumSettings.m_displayTraceIntensity);
|
||||
swgSpectrum->setDisplayWaterfall(spectrumSettings.m_displayWaterfall ? 1 : 0);
|
||||
swgSpectrum->setFftOverlap(spectrumSettings.m_fftOverlap);
|
||||
swgSpectrum->setFftSize(spectrumSettings.m_fftSize);
|
||||
|
||||
}
|
||||
|
||||
void ChannelAnalyzerWebAPIAdapter::webapiUpdateChannelSettings(
|
||||
ChannelAnalyzerSettings& settings,
|
||||
GLScopeSettings& scopeSettings,
|
||||
GLSpectrumSettings& spectrumSettings,
|
||||
const QStringList& channelSettingsKeys,
|
||||
SWGSDRangel::SWGChannelSettings& response)
|
||||
{
|
||||
|
||||
}
|
||||
|
66
plugins/channelrx/chanalyzer/chanalyzerwebapiadapter.h
Normal file
66
plugins/channelrx/chanalyzer/chanalyzerwebapiadapter.h
Normal file
@ -0,0 +1,66 @@
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
// Copyright (C) 2019 Edouard Griffiths, F4EXB. //
|
||||
// //
|
||||
// This program is free software; you can redistribute it and/or modify //
|
||||
// it under the terms of the GNU General Public License as published by //
|
||||
// the Free Software Foundation as version 3 of the License, or //
|
||||
// (at your option) any later version. //
|
||||
// //
|
||||
// This program is distributed in the hope that it will be useful, //
|
||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
|
||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
|
||||
// GNU General Public License V3 for more details. //
|
||||
// //
|
||||
// You should have received a copy of the GNU General Public License //
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef INCLUDE_CHANALYZER_WEBAPIADAPTER_H
|
||||
#define INCLUDE_CHANALYZER_WEBAPIADAPTER_H
|
||||
|
||||
#include "channel/channelwebapiadapter.h"
|
||||
#include "dsp/glscopesettings.h"
|
||||
#include "dsp/glspectrumsettings.h"
|
||||
#include "chanalyzersettings.h"
|
||||
|
||||
/**
|
||||
* Standalone API adapter only for the settings
|
||||
*/
|
||||
class ChannelAnalyzerWebAPIAdapter : public ChannelWebAPIAdapter {
|
||||
public:
|
||||
ChannelAnalyzerWebAPIAdapter();
|
||||
virtual ~ChannelAnalyzerWebAPIAdapter();
|
||||
|
||||
virtual QByteArray serialize() const { return m_settings.serialize(); }
|
||||
virtual bool deserialize(const QByteArray& data) { return m_settings.deserialize(data); }
|
||||
|
||||
virtual int webapiSettingsGet(
|
||||
SWGSDRangel::SWGChannelSettings& response,
|
||||
QString& errorMessage);
|
||||
|
||||
virtual int webapiSettingsPutPatch(
|
||||
bool force,
|
||||
const QStringList& channelSettingsKeys,
|
||||
SWGSDRangel::SWGChannelSettings& response,
|
||||
QString& errorMessage);
|
||||
|
||||
static void webapiFormatChannelSettings(
|
||||
SWGSDRangel::SWGChannelSettings& response,
|
||||
const ChannelAnalyzerSettings& settings,
|
||||
const GLScopeSettings& scopeSettings,
|
||||
const GLSpectrumSettings& spectrumSettings);
|
||||
|
||||
static void webapiUpdateChannelSettings(
|
||||
ChannelAnalyzerSettings& settings,
|
||||
GLScopeSettings& scopeSettings,
|
||||
GLSpectrumSettings& spectrumSettings,
|
||||
const QStringList& channelSettingsKeys,
|
||||
SWGSDRangel::SWGChannelSettings& response);
|
||||
|
||||
private:
|
||||
ChannelAnalyzerSettings m_settings;
|
||||
GLScopeSettings m_glScopeSettings;
|
||||
GLSpectrumSettings m_glSpectrumSettings;
|
||||
};
|
||||
|
||||
#endif // INCLUDE_CHANALYZER_WEBAPIADAPTER_H
|
@ -10,6 +10,7 @@
|
||||
<file>webapi/doc/swagger/include/BFMDemod.yaml</file>
|
||||
<file>webapi/doc/swagger/include/BladeRF1.yaml</file>
|
||||
<file>webapi/doc/swagger/include/BladeRF2.yaml</file>
|
||||
<file>webapi/doc/swagger/include/ChannelAnalyzer.yaml</file>
|
||||
<file>webapi/doc/swagger/include/ChannelSettings.yaml</file>
|
||||
<file>webapi/doc/swagger/include/Command.yaml</file>
|
||||
<file>webapi/doc/swagger/include/CWKeyer.yaml</file>
|
||||
@ -22,6 +23,7 @@
|
||||
<file>webapi/doc/swagger/include/FreeDVDemod.yaml</file>
|
||||
<file>webapi/doc/swagger/include/FreeDVMod.yaml</file>
|
||||
<file>webapi/doc/swagger/include/FreqTracker.yaml</file>
|
||||
<file>webapi/doc/swagger/include/GLScope.yaml</file>
|
||||
<file>webapi/doc/swagger/include/GLSpectrum.yaml</file>
|
||||
<file>webapi/doc/swagger/include/HackRF.yaml</file>
|
||||
<file>webapi/doc/swagger/include/LimeSdr.yaml</file>
|
||||
|
@ -1758,6 +1758,69 @@ margin-bottom: 20px;
|
||||
}
|
||||
},
|
||||
"description" : "Channel summarized information"
|
||||
};
|
||||
defs.ChannelAnalyzerSettings = {
|
||||
"properties" : {
|
||||
"frequency" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"downSample" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"downSampleRate" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"bandwidth" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"lowCutoff" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"spanLog2" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"ssb" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"pll" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"fll" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"rrc" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"rrcRolloff" : {
|
||||
"type" : "integer",
|
||||
"description" : "in 100ths"
|
||||
},
|
||||
"pllPskOrder" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"inputType" : {
|
||||
"type" : "integer",
|
||||
"description" : "see ChannelAnalyzer::InputType"
|
||||
},
|
||||
"rgbColor" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"title" : {
|
||||
"type" : "string"
|
||||
},
|
||||
"spectrumConfig" : {
|
||||
"$ref" : "#/definitions/GLSpectrum"
|
||||
},
|
||||
"scopeConfig" : {
|
||||
"$ref" : "#/definitions/GLScope"
|
||||
}
|
||||
},
|
||||
"description" : "ChannelAnalyzer"
|
||||
};
|
||||
defs.ChannelConfig = {
|
||||
"properties" : {
|
||||
@ -1901,6 +1964,9 @@ margin-bottom: 20px;
|
||||
"BFMDemodSettings" : {
|
||||
"$ref" : "#/definitions/BFMDemodSettings"
|
||||
},
|
||||
"ChannelAnalyzerSettings" : {
|
||||
"$ref" : "#/definitions/ChannelAnalyzerSettings"
|
||||
},
|
||||
"DSDDemodSettings" : {
|
||||
"$ref" : "#/definitions/DSDDemodSettings"
|
||||
},
|
||||
@ -3090,6 +3156,45 @@ margin-bottom: 20px;
|
||||
}
|
||||
},
|
||||
"description" : "An frequency range with 64 bit support for min and max"
|
||||
};
|
||||
defs.GLScope = {
|
||||
"properties" : {
|
||||
"displayMode" : {
|
||||
"type" : "integer",
|
||||
"description" : "see GLScopeSettings::DisplayMode"
|
||||
},
|
||||
"traceIntensity" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"gridIntensity" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"time" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"timeOfs" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"traceLen" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"trigPre" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"tracesData" : {
|
||||
"type" : "array",
|
||||
"items" : {
|
||||
"$ref" : "#/definitions/TraceData"
|
||||
}
|
||||
},
|
||||
"m_triggersData" : {
|
||||
"type" : "array",
|
||||
"items" : {
|
||||
"$ref" : "#/definitions/TriggerData"
|
||||
}
|
||||
}
|
||||
},
|
||||
"description" : "GLScopeGUI settings"
|
||||
};
|
||||
defs.GLSpectrum = {
|
||||
"properties" : {
|
||||
@ -5814,6 +5919,163 @@ margin-bottom: 20px;
|
||||
}
|
||||
},
|
||||
"description" : "TestSource"
|
||||
};
|
||||
defs.TraceData = {
|
||||
"properties" : {
|
||||
"projectionType" : {
|
||||
"type" : "integer",
|
||||
"description" : "Complex to real projection type. See Projector::ProjectionType"
|
||||
},
|
||||
"inputIndex" : {
|
||||
"type" : "integer",
|
||||
"description" : "Input or feed index this trace is associated with"
|
||||
},
|
||||
"amp" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Amplification factor"
|
||||
},
|
||||
"ampIndex" : {
|
||||
"type" : "integer",
|
||||
"description" : "Index in list of amplification factors"
|
||||
},
|
||||
"ofs" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Offset factor"
|
||||
},
|
||||
"ofsCoarse" : {
|
||||
"type" : "integer",
|
||||
"description" : "Coarse offset slider value"
|
||||
},
|
||||
"ofsFine" : {
|
||||
"type" : "integer",
|
||||
"description" : "Fine offset slider value"
|
||||
},
|
||||
"traceDelay" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trace delay in number of samples"
|
||||
},
|
||||
"traceDelayCoarse" : {
|
||||
"type" : "integer",
|
||||
"description" : "Coarse delay slider value"
|
||||
},
|
||||
"traceDelayFine" : {
|
||||
"type" : "integer",
|
||||
"description" : "Fine delay slider value"
|
||||
},
|
||||
"triggerDisplayLevel" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Displayable trigger display level in -1:+1 scale. Off scale if not displayable."
|
||||
},
|
||||
"traceColor" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trace display color. QColor"
|
||||
},
|
||||
"traceColorR" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trace display color - red shortcut"
|
||||
},
|
||||
"traceColorG" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trace display color - green shortcut"
|
||||
},
|
||||
"traceColorB" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trace display color - blue shortcut"
|
||||
},
|
||||
"hasTextOverlay" : {
|
||||
"type" : "integer",
|
||||
"description" : "True if a text overlay has to be displayed. Boolean"
|
||||
},
|
||||
"textOverlay" : {
|
||||
"type" : "string",
|
||||
"description" : "Text overlay to display"
|
||||
},
|
||||
"viewTrace" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trace visibility. Boolean"
|
||||
}
|
||||
},
|
||||
"description" : "see GLScopeSettings::TraceData"
|
||||
};
|
||||
defs.TriggerData = {
|
||||
"properties" : {
|
||||
"projectionType" : {
|
||||
"type" : "integer",
|
||||
"description" : "Complex to real projection type. See Projector::ProjectionType"
|
||||
},
|
||||
"inputIndex" : {
|
||||
"type" : "integer",
|
||||
"description" : "Input or feed index this trigger is associated with"
|
||||
},
|
||||
"triggerLevel" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Level in real units"
|
||||
},
|
||||
"triggerLevelCoarse" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerLevelFine" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerPositiveEdge" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger on the positive edge (else negative). Boolean"
|
||||
},
|
||||
"triggerBothEdges" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger on both edges (else only one). Boolean"
|
||||
},
|
||||
"triggerHoldoff" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger holdoff in number of samples"
|
||||
},
|
||||
"triggerDelay" : {
|
||||
"type" : "integer",
|
||||
"description" : "Delay before the trigger is kicked off in number of samples (trigger delay)"
|
||||
},
|
||||
"triggerDelayMult" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger delay as a multiplier of trace length"
|
||||
},
|
||||
"triggerDelayCoarse" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerDelayFine" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerRepeat" : {
|
||||
"type" : "integer",
|
||||
"description" : "Number of trigger conditions before the final decisive trigger"
|
||||
},
|
||||
"triggerColor" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger line display color. QColor"
|
||||
},
|
||||
"triggerColorR" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger line display color - red shortcut"
|
||||
},
|
||||
"triggerColorG" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger line display color - green shortcut"
|
||||
},
|
||||
"triggerColorB" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger line display color - blue shortcut"
|
||||
}
|
||||
},
|
||||
"description" : "see GLScopeSettings::TriggerData"
|
||||
};
|
||||
defs.UDPSinkReport = {
|
||||
"properties" : {
|
||||
@ -27345,7 +27607,7 @@ except ApiException as e:
|
||||
</div>
|
||||
<div id="generator">
|
||||
<div class="content">
|
||||
Generated 2019-08-05T18:13:15.915+02:00
|
||||
Generated 2019-08-07T23:30:36.250+02:00
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -0,0 +1,44 @@
|
||||
ChannelAnalyzerSettings:
|
||||
description: ChannelAnalyzer
|
||||
properties:
|
||||
frequency:
|
||||
type: integer
|
||||
downSample:
|
||||
description: Boolean
|
||||
type: integer
|
||||
downSampleRate:
|
||||
type: integer
|
||||
bandwidth:
|
||||
type: integer
|
||||
lowCutoff:
|
||||
type: integer
|
||||
spanLog2:
|
||||
type: integer
|
||||
ssb:
|
||||
description: Boolean
|
||||
type: integer
|
||||
pll:
|
||||
description: Boolean
|
||||
type: integer
|
||||
fll:
|
||||
description: Boolean
|
||||
type: integer
|
||||
rrc:
|
||||
description: Boolean
|
||||
type: integer
|
||||
rrcRolloff:
|
||||
description: in 100ths
|
||||
type: integer
|
||||
pllPskOrder:
|
||||
type: integer
|
||||
inputType:
|
||||
description: see ChannelAnalyzer::InputType
|
||||
type: integer
|
||||
rgbColor:
|
||||
type: integer
|
||||
title:
|
||||
type: string
|
||||
spectrumConfig:
|
||||
$ref: "/doc/swagger/include/GLSpectrum.yaml#/GLSpectrum"
|
||||
scopeConfig:
|
||||
$ref: "/doc/swagger/include/GLScope.yaml#/GLScope"
|
@ -25,6 +25,8 @@ ChannelSettings:
|
||||
$ref: "/doc/swagger/include/ATVMod.yaml#/ATVModSettings"
|
||||
BFMDemodSettings:
|
||||
$ref: "/doc/swagger/include/BFMDemod.yaml#/BFMDemodSettings"
|
||||
ChannelAnalyzerSettings:
|
||||
$ref: "/doc/swagger/include/ChannelAnalyzer.yaml#/ChannelAnalyzerSettings"
|
||||
DSDDemodSettings:
|
||||
$ref: "/doc/swagger/include/DSDDemod.yaml#/DSDDemodSettings"
|
||||
FileSourceSettings:
|
||||
|
146
sdrbase/resources/webapi/doc/swagger/include/GLScope.yaml
Normal file
146
sdrbase/resources/webapi/doc/swagger/include/GLScope.yaml
Normal file
@ -0,0 +1,146 @@
|
||||
TraceData:
|
||||
description: see GLScopeSettings::TraceData
|
||||
properties:
|
||||
projectionType:
|
||||
description: Complex to real projection type. See Projector::ProjectionType
|
||||
type: integer
|
||||
inputIndex:
|
||||
description: Input or feed index this trace is associated with
|
||||
type: integer
|
||||
amp:
|
||||
description: Amplification factor
|
||||
type: number
|
||||
format: float
|
||||
ampIndex:
|
||||
description: Index in list of amplification factors
|
||||
type: integer
|
||||
ofs:
|
||||
description: Offset factor
|
||||
type: number
|
||||
format: float
|
||||
ofsCoarse:
|
||||
description: Coarse offset slider value
|
||||
type: integer
|
||||
ofsFine:
|
||||
description: Fine offset slider value
|
||||
type: integer
|
||||
traceDelay:
|
||||
description: Trace delay in number of samples
|
||||
type: integer
|
||||
traceDelayCoarse:
|
||||
description: Coarse delay slider value
|
||||
type: integer
|
||||
traceDelayFine:
|
||||
description: Fine delay slider value
|
||||
type: integer
|
||||
triggerDisplayLevel:
|
||||
description: Displayable trigger display level in -1:+1 scale. Off scale if not displayable.
|
||||
type: number
|
||||
format: float
|
||||
traceColor:
|
||||
description: Trace display color. QColor
|
||||
type: integer
|
||||
traceColorR:
|
||||
description: Trace display color - red shortcut
|
||||
type: number
|
||||
format: float
|
||||
traceColorG:
|
||||
description: Trace display color - green shortcut
|
||||
type: number
|
||||
format: float
|
||||
traceColorB:
|
||||
description: Trace display color - blue shortcut
|
||||
type: number
|
||||
format: float
|
||||
hasTextOverlay:
|
||||
description: True if a text overlay has to be displayed. Boolean
|
||||
type: integer
|
||||
textOverlay:
|
||||
description: Text overlay to display
|
||||
type: string
|
||||
viewTrace:
|
||||
description: Trace visibility. Boolean
|
||||
type: integer
|
||||
|
||||
TriggerData:
|
||||
description: see GLScopeSettings::TriggerData
|
||||
properties:
|
||||
projectionType:
|
||||
description: Complex to real projection type. See Projector::ProjectionType
|
||||
type: integer
|
||||
inputIndex:
|
||||
description: Input or feed index this trigger is associated with
|
||||
type: integer
|
||||
triggerLevel:
|
||||
description: Level in real units
|
||||
type: number
|
||||
format: float
|
||||
triggerLevelCoarse:
|
||||
type: integer
|
||||
triggerLevelFine:
|
||||
type: integer
|
||||
triggerPositiveEdge:
|
||||
description: Trigger on the positive edge (else negative). Boolean
|
||||
type: integer
|
||||
triggerBothEdges:
|
||||
description: Trigger on both edges (else only one). Boolean
|
||||
type: integer
|
||||
triggerHoldoff:
|
||||
description: Trigger holdoff in number of samples
|
||||
type: integer
|
||||
triggerDelay:
|
||||
description: Delay before the trigger is kicked off in number of samples (trigger delay)
|
||||
type: integer
|
||||
triggerDelayMult:
|
||||
description: Trigger delay as a multiplier of trace length
|
||||
type: number
|
||||
format: float
|
||||
triggerDelayCoarse:
|
||||
type: integer
|
||||
triggerDelayFine:
|
||||
type: integer
|
||||
triggerRepeat:
|
||||
description: Number of trigger conditions before the final decisive trigger
|
||||
type: integer
|
||||
triggerColor:
|
||||
description: Trigger line display color. QColor
|
||||
type: integer
|
||||
triggerColorR:
|
||||
description: Trigger line display color - red shortcut
|
||||
type: number
|
||||
format: float
|
||||
triggerColorG:
|
||||
description: Trigger line display color - green shortcut
|
||||
type: number
|
||||
format: float
|
||||
triggerColorB:
|
||||
description: Trigger line display color - blue shortcut
|
||||
type: number
|
||||
format: float
|
||||
|
||||
GLScope:
|
||||
description: GLScopeGUI settings
|
||||
properties:
|
||||
displayMode:
|
||||
description: see GLScopeSettings::DisplayMode
|
||||
type: integer
|
||||
traceIntensity:
|
||||
type: integer
|
||||
gridIntensity:
|
||||
type: integer
|
||||
time:
|
||||
type: integer
|
||||
timeOfs:
|
||||
type: integer
|
||||
traceLen:
|
||||
type: integer
|
||||
trigPre:
|
||||
type: integer
|
||||
tracesData:
|
||||
type: array
|
||||
items:
|
||||
$ref: "/doc/swagger/include/GLScope.yaml#/TraceData"
|
||||
m_triggersData:
|
||||
type: array
|
||||
items:
|
||||
$ref: "/doc/swagger/include/GLScope.yaml#/TriggerData"
|
44
swagger/sdrangel/api/swagger/include/ChannelAnalyzer.yaml
Normal file
44
swagger/sdrangel/api/swagger/include/ChannelAnalyzer.yaml
Normal file
@ -0,0 +1,44 @@
|
||||
ChannelAnalyzerSettings:
|
||||
description: ChannelAnalyzer
|
||||
properties:
|
||||
frequency:
|
||||
type: integer
|
||||
downSample:
|
||||
description: Boolean
|
||||
type: integer
|
||||
downSampleRate:
|
||||
type: integer
|
||||
bandwidth:
|
||||
type: integer
|
||||
lowCutoff:
|
||||
type: integer
|
||||
spanLog2:
|
||||
type: integer
|
||||
ssb:
|
||||
description: Boolean
|
||||
type: integer
|
||||
pll:
|
||||
description: Boolean
|
||||
type: integer
|
||||
fll:
|
||||
description: Boolean
|
||||
type: integer
|
||||
rrc:
|
||||
description: Boolean
|
||||
type: integer
|
||||
rrcRolloff:
|
||||
description: in 100ths
|
||||
type: integer
|
||||
pllPskOrder:
|
||||
type: integer
|
||||
inputType:
|
||||
description: see ChannelAnalyzer::InputType
|
||||
type: integer
|
||||
rgbColor:
|
||||
type: integer
|
||||
title:
|
||||
type: string
|
||||
spectrumConfig:
|
||||
$ref: "http://localhost:8081/api/swagger/include/GLSpectrum.yaml#/GLSpectrum"
|
||||
scopeConfig:
|
||||
$ref: "http://localhost:8081/api/swagger/include/GLScope.yaml#/GLScope"
|
@ -25,6 +25,8 @@ ChannelSettings:
|
||||
$ref: "http://localhost:8081/api/swagger/include/ATVMod.yaml#/ATVModSettings"
|
||||
BFMDemodSettings:
|
||||
$ref: "http://localhost:8081/api/swagger/include/BFMDemod.yaml#/BFMDemodSettings"
|
||||
ChannelAnalyzerSettings:
|
||||
$ref: "http://localhost:8081/api/swagger/include/ChannelAnalyzer.yaml#/ChannelAnalyzerSettings"
|
||||
DSDDemodSettings:
|
||||
$ref: "http://localhost:8081/api/swagger/include/DSDDemod.yaml#/DSDDemodSettings"
|
||||
FileSourceSettings:
|
||||
|
146
swagger/sdrangel/api/swagger/include/GLScope.yaml
Normal file
146
swagger/sdrangel/api/swagger/include/GLScope.yaml
Normal file
@ -0,0 +1,146 @@
|
||||
TraceData:
|
||||
description: see GLScopeSettings::TraceData
|
||||
properties:
|
||||
projectionType:
|
||||
description: Complex to real projection type. See Projector::ProjectionType
|
||||
type: integer
|
||||
inputIndex:
|
||||
description: Input or feed index this trace is associated with
|
||||
type: integer
|
||||
amp:
|
||||
description: Amplification factor
|
||||
type: number
|
||||
format: float
|
||||
ampIndex:
|
||||
description: Index in list of amplification factors
|
||||
type: integer
|
||||
ofs:
|
||||
description: Offset factor
|
||||
type: number
|
||||
format: float
|
||||
ofsCoarse:
|
||||
description: Coarse offset slider value
|
||||
type: integer
|
||||
ofsFine:
|
||||
description: Fine offset slider value
|
||||
type: integer
|
||||
traceDelay:
|
||||
description: Trace delay in number of samples
|
||||
type: integer
|
||||
traceDelayCoarse:
|
||||
description: Coarse delay slider value
|
||||
type: integer
|
||||
traceDelayFine:
|
||||
description: Fine delay slider value
|
||||
type: integer
|
||||
triggerDisplayLevel:
|
||||
description: Displayable trigger display level in -1:+1 scale. Off scale if not displayable.
|
||||
type: number
|
||||
format: float
|
||||
traceColor:
|
||||
description: Trace display color. QColor
|
||||
type: integer
|
||||
traceColorR:
|
||||
description: Trace display color - red shortcut
|
||||
type: number
|
||||
format: float
|
||||
traceColorG:
|
||||
description: Trace display color - green shortcut
|
||||
type: number
|
||||
format: float
|
||||
traceColorB:
|
||||
description: Trace display color - blue shortcut
|
||||
type: number
|
||||
format: float
|
||||
hasTextOverlay:
|
||||
description: True if a text overlay has to be displayed. Boolean
|
||||
type: integer
|
||||
textOverlay:
|
||||
description: Text overlay to display
|
||||
type: string
|
||||
viewTrace:
|
||||
description: Trace visibility. Boolean
|
||||
type: integer
|
||||
|
||||
TriggerData:
|
||||
description: see GLScopeSettings::TriggerData
|
||||
properties:
|
||||
projectionType:
|
||||
description: Complex to real projection type. See Projector::ProjectionType
|
||||
type: integer
|
||||
inputIndex:
|
||||
description: Input or feed index this trigger is associated with
|
||||
type: integer
|
||||
triggerLevel:
|
||||
description: Level in real units
|
||||
type: number
|
||||
format: float
|
||||
triggerLevelCoarse:
|
||||
type: integer
|
||||
triggerLevelFine:
|
||||
type: integer
|
||||
triggerPositiveEdge:
|
||||
description: Trigger on the positive edge (else negative). Boolean
|
||||
type: integer
|
||||
triggerBothEdges:
|
||||
description: Trigger on both edges (else only one). Boolean
|
||||
type: integer
|
||||
triggerHoldoff:
|
||||
description: Trigger holdoff in number of samples
|
||||
type: integer
|
||||
triggerDelay:
|
||||
description: Delay before the trigger is kicked off in number of samples (trigger delay)
|
||||
type: integer
|
||||
triggerDelayMult:
|
||||
description: Trigger delay as a multiplier of trace length
|
||||
type: number
|
||||
format: float
|
||||
triggerDelayCoarse:
|
||||
type: integer
|
||||
triggerDelayFine:
|
||||
type: integer
|
||||
triggerRepeat:
|
||||
description: Number of trigger conditions before the final decisive trigger
|
||||
type: integer
|
||||
triggerColor:
|
||||
description: Trigger line display color. QColor
|
||||
type: integer
|
||||
triggerColorR:
|
||||
description: Trigger line display color - red shortcut
|
||||
type: number
|
||||
format: float
|
||||
triggerColorG:
|
||||
description: Trigger line display color - green shortcut
|
||||
type: number
|
||||
format: float
|
||||
triggerColorB:
|
||||
description: Trigger line display color - blue shortcut
|
||||
type: number
|
||||
format: float
|
||||
|
||||
GLScope:
|
||||
description: GLScopeGUI settings
|
||||
properties:
|
||||
displayMode:
|
||||
description: see GLScopeSettings::DisplayMode
|
||||
type: integer
|
||||
traceIntensity:
|
||||
type: integer
|
||||
gridIntensity:
|
||||
type: integer
|
||||
time:
|
||||
type: integer
|
||||
timeOfs:
|
||||
type: integer
|
||||
traceLen:
|
||||
type: integer
|
||||
trigPre:
|
||||
type: integer
|
||||
tracesData:
|
||||
type: array
|
||||
items:
|
||||
$ref: "http://localhost:8081/api/swagger/include/GLScope.yaml#/TraceData"
|
||||
m_triggersData:
|
||||
type: array
|
||||
items:
|
||||
$ref: "http://localhost:8081/api/swagger/include/GLScope.yaml#/TriggerData"
|
@ -1758,6 +1758,69 @@ margin-bottom: 20px;
|
||||
}
|
||||
},
|
||||
"description" : "Channel summarized information"
|
||||
};
|
||||
defs.ChannelAnalyzerSettings = {
|
||||
"properties" : {
|
||||
"frequency" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"downSample" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"downSampleRate" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"bandwidth" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"lowCutoff" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"spanLog2" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"ssb" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"pll" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"fll" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"rrc" : {
|
||||
"type" : "integer",
|
||||
"description" : "Boolean"
|
||||
},
|
||||
"rrcRolloff" : {
|
||||
"type" : "integer",
|
||||
"description" : "in 100ths"
|
||||
},
|
||||
"pllPskOrder" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"inputType" : {
|
||||
"type" : "integer",
|
||||
"description" : "see ChannelAnalyzer::InputType"
|
||||
},
|
||||
"rgbColor" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"title" : {
|
||||
"type" : "string"
|
||||
},
|
||||
"spectrumConfig" : {
|
||||
"$ref" : "#/definitions/GLSpectrum"
|
||||
},
|
||||
"scopeConfig" : {
|
||||
"$ref" : "#/definitions/GLScope"
|
||||
}
|
||||
},
|
||||
"description" : "ChannelAnalyzer"
|
||||
};
|
||||
defs.ChannelConfig = {
|
||||
"properties" : {
|
||||
@ -1901,6 +1964,9 @@ margin-bottom: 20px;
|
||||
"BFMDemodSettings" : {
|
||||
"$ref" : "#/definitions/BFMDemodSettings"
|
||||
},
|
||||
"ChannelAnalyzerSettings" : {
|
||||
"$ref" : "#/definitions/ChannelAnalyzerSettings"
|
||||
},
|
||||
"DSDDemodSettings" : {
|
||||
"$ref" : "#/definitions/DSDDemodSettings"
|
||||
},
|
||||
@ -3090,6 +3156,45 @@ margin-bottom: 20px;
|
||||
}
|
||||
},
|
||||
"description" : "An frequency range with 64 bit support for min and max"
|
||||
};
|
||||
defs.GLScope = {
|
||||
"properties" : {
|
||||
"displayMode" : {
|
||||
"type" : "integer",
|
||||
"description" : "see GLScopeSettings::DisplayMode"
|
||||
},
|
||||
"traceIntensity" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"gridIntensity" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"time" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"timeOfs" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"traceLen" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"trigPre" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"tracesData" : {
|
||||
"type" : "array",
|
||||
"items" : {
|
||||
"$ref" : "#/definitions/TraceData"
|
||||
}
|
||||
},
|
||||
"m_triggersData" : {
|
||||
"type" : "array",
|
||||
"items" : {
|
||||
"$ref" : "#/definitions/TriggerData"
|
||||
}
|
||||
}
|
||||
},
|
||||
"description" : "GLScopeGUI settings"
|
||||
};
|
||||
defs.GLSpectrum = {
|
||||
"properties" : {
|
||||
@ -5814,6 +5919,163 @@ margin-bottom: 20px;
|
||||
}
|
||||
},
|
||||
"description" : "TestSource"
|
||||
};
|
||||
defs.TraceData = {
|
||||
"properties" : {
|
||||
"projectionType" : {
|
||||
"type" : "integer",
|
||||
"description" : "Complex to real projection type. See Projector::ProjectionType"
|
||||
},
|
||||
"inputIndex" : {
|
||||
"type" : "integer",
|
||||
"description" : "Input or feed index this trace is associated with"
|
||||
},
|
||||
"amp" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Amplification factor"
|
||||
},
|
||||
"ampIndex" : {
|
||||
"type" : "integer",
|
||||
"description" : "Index in list of amplification factors"
|
||||
},
|
||||
"ofs" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Offset factor"
|
||||
},
|
||||
"ofsCoarse" : {
|
||||
"type" : "integer",
|
||||
"description" : "Coarse offset slider value"
|
||||
},
|
||||
"ofsFine" : {
|
||||
"type" : "integer",
|
||||
"description" : "Fine offset slider value"
|
||||
},
|
||||
"traceDelay" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trace delay in number of samples"
|
||||
},
|
||||
"traceDelayCoarse" : {
|
||||
"type" : "integer",
|
||||
"description" : "Coarse delay slider value"
|
||||
},
|
||||
"traceDelayFine" : {
|
||||
"type" : "integer",
|
||||
"description" : "Fine delay slider value"
|
||||
},
|
||||
"triggerDisplayLevel" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Displayable trigger display level in -1:+1 scale. Off scale if not displayable."
|
||||
},
|
||||
"traceColor" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trace display color. QColor"
|
||||
},
|
||||
"traceColorR" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trace display color - red shortcut"
|
||||
},
|
||||
"traceColorG" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trace display color - green shortcut"
|
||||
},
|
||||
"traceColorB" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trace display color - blue shortcut"
|
||||
},
|
||||
"hasTextOverlay" : {
|
||||
"type" : "integer",
|
||||
"description" : "True if a text overlay has to be displayed. Boolean"
|
||||
},
|
||||
"textOverlay" : {
|
||||
"type" : "string",
|
||||
"description" : "Text overlay to display"
|
||||
},
|
||||
"viewTrace" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trace visibility. Boolean"
|
||||
}
|
||||
},
|
||||
"description" : "see GLScopeSettings::TraceData"
|
||||
};
|
||||
defs.TriggerData = {
|
||||
"properties" : {
|
||||
"projectionType" : {
|
||||
"type" : "integer",
|
||||
"description" : "Complex to real projection type. See Projector::ProjectionType"
|
||||
},
|
||||
"inputIndex" : {
|
||||
"type" : "integer",
|
||||
"description" : "Input or feed index this trigger is associated with"
|
||||
},
|
||||
"triggerLevel" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Level in real units"
|
||||
},
|
||||
"triggerLevelCoarse" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerLevelFine" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerPositiveEdge" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger on the positive edge (else negative). Boolean"
|
||||
},
|
||||
"triggerBothEdges" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger on both edges (else only one). Boolean"
|
||||
},
|
||||
"triggerHoldoff" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger holdoff in number of samples"
|
||||
},
|
||||
"triggerDelay" : {
|
||||
"type" : "integer",
|
||||
"description" : "Delay before the trigger is kicked off in number of samples (trigger delay)"
|
||||
},
|
||||
"triggerDelayMult" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger delay as a multiplier of trace length"
|
||||
},
|
||||
"triggerDelayCoarse" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerDelayFine" : {
|
||||
"type" : "integer"
|
||||
},
|
||||
"triggerRepeat" : {
|
||||
"type" : "integer",
|
||||
"description" : "Number of trigger conditions before the final decisive trigger"
|
||||
},
|
||||
"triggerColor" : {
|
||||
"type" : "integer",
|
||||
"description" : "Trigger line display color. QColor"
|
||||
},
|
||||
"triggerColorR" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger line display color - red shortcut"
|
||||
},
|
||||
"triggerColorG" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger line display color - green shortcut"
|
||||
},
|
||||
"triggerColorB" : {
|
||||
"type" : "number",
|
||||
"format" : "float",
|
||||
"description" : "Trigger line display color - blue shortcut"
|
||||
}
|
||||
},
|
||||
"description" : "see GLScopeSettings::TriggerData"
|
||||
};
|
||||
defs.UDPSinkReport = {
|
||||
"properties" : {
|
||||
@ -27345,7 +27607,7 @@ except ApiException as e:
|
||||
</div>
|
||||
<div id="generator">
|
||||
<div class="content">
|
||||
Generated 2019-08-05T18:13:15.915+02:00
|
||||
Generated 2019-08-07T23:30:36.250+02:00
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
482
swagger/sdrangel/code/qt5/client/SWGChannelAnalyzerSettings.cpp
Normal file
482
swagger/sdrangel/code/qt5/client/SWGChannelAnalyzerSettings.cpp
Normal file
@ -0,0 +1,482 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
|
||||
#include "SWGChannelAnalyzerSettings.h"
|
||||
|
||||
#include "SWGHelpers.h"
|
||||
|
||||
#include <QJsonDocument>
|
||||
#include <QJsonArray>
|
||||
#include <QObject>
|
||||
#include <QDebug>
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
SWGChannelAnalyzerSettings::SWGChannelAnalyzerSettings(QString* json) {
|
||||
init();
|
||||
this->fromJson(*json);
|
||||
}
|
||||
|
||||
SWGChannelAnalyzerSettings::SWGChannelAnalyzerSettings() {
|
||||
frequency = 0;
|
||||
m_frequency_isSet = false;
|
||||
down_sample = 0;
|
||||
m_down_sample_isSet = false;
|
||||
down_sample_rate = 0;
|
||||
m_down_sample_rate_isSet = false;
|
||||
bandwidth = 0;
|
||||
m_bandwidth_isSet = false;
|
||||
low_cutoff = 0;
|
||||
m_low_cutoff_isSet = false;
|
||||
span_log2 = 0;
|
||||
m_span_log2_isSet = false;
|
||||
ssb = 0;
|
||||
m_ssb_isSet = false;
|
||||
pll = 0;
|
||||
m_pll_isSet = false;
|
||||
fll = 0;
|
||||
m_fll_isSet = false;
|
||||
rrc = 0;
|
||||
m_rrc_isSet = false;
|
||||
rrc_rolloff = 0;
|
||||
m_rrc_rolloff_isSet = false;
|
||||
pll_psk_order = 0;
|
||||
m_pll_psk_order_isSet = false;
|
||||
input_type = 0;
|
||||
m_input_type_isSet = false;
|
||||
rgb_color = 0;
|
||||
m_rgb_color_isSet = false;
|
||||
title = nullptr;
|
||||
m_title_isSet = false;
|
||||
spectrum_config = nullptr;
|
||||
m_spectrum_config_isSet = false;
|
||||
scope_config = nullptr;
|
||||
m_scope_config_isSet = false;
|
||||
}
|
||||
|
||||
SWGChannelAnalyzerSettings::~SWGChannelAnalyzerSettings() {
|
||||
this->cleanup();
|
||||
}
|
||||
|
||||
void
|
||||
SWGChannelAnalyzerSettings::init() {
|
||||
frequency = 0;
|
||||
m_frequency_isSet = false;
|
||||
down_sample = 0;
|
||||
m_down_sample_isSet = false;
|
||||
down_sample_rate = 0;
|
||||
m_down_sample_rate_isSet = false;
|
||||
bandwidth = 0;
|
||||
m_bandwidth_isSet = false;
|
||||
low_cutoff = 0;
|
||||
m_low_cutoff_isSet = false;
|
||||
span_log2 = 0;
|
||||
m_span_log2_isSet = false;
|
||||
ssb = 0;
|
||||
m_ssb_isSet = false;
|
||||
pll = 0;
|
||||
m_pll_isSet = false;
|
||||
fll = 0;
|
||||
m_fll_isSet = false;
|
||||
rrc = 0;
|
||||
m_rrc_isSet = false;
|
||||
rrc_rolloff = 0;
|
||||
m_rrc_rolloff_isSet = false;
|
||||
pll_psk_order = 0;
|
||||
m_pll_psk_order_isSet = false;
|
||||
input_type = 0;
|
||||
m_input_type_isSet = false;
|
||||
rgb_color = 0;
|
||||
m_rgb_color_isSet = false;
|
||||
title = new QString("");
|
||||
m_title_isSet = false;
|
||||
spectrum_config = new SWGGLSpectrum();
|
||||
m_spectrum_config_isSet = false;
|
||||
scope_config = new SWGGLScope();
|
||||
m_scope_config_isSet = false;
|
||||
}
|
||||
|
||||
void
|
||||
SWGChannelAnalyzerSettings::cleanup() {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if(title != nullptr) {
|
||||
delete title;
|
||||
}
|
||||
if(spectrum_config != nullptr) {
|
||||
delete spectrum_config;
|
||||
}
|
||||
if(scope_config != nullptr) {
|
||||
delete scope_config;
|
||||
}
|
||||
}
|
||||
|
||||
SWGChannelAnalyzerSettings*
|
||||
SWGChannelAnalyzerSettings::fromJson(QString &json) {
|
||||
QByteArray array (json.toStdString().c_str());
|
||||
QJsonDocument doc = QJsonDocument::fromJson(array);
|
||||
QJsonObject jsonObject = doc.object();
|
||||
this->fromJsonObject(jsonObject);
|
||||
return this;
|
||||
}
|
||||
|
||||
void
|
||||
SWGChannelAnalyzerSettings::fromJsonObject(QJsonObject &pJson) {
|
||||
::SWGSDRangel::setValue(&frequency, pJson["frequency"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&down_sample, pJson["downSample"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&down_sample_rate, pJson["downSampleRate"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&bandwidth, pJson["bandwidth"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&low_cutoff, pJson["lowCutoff"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&span_log2, pJson["spanLog2"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&ssb, pJson["ssb"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&pll, pJson["pll"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&fll, pJson["fll"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&rrc, pJson["rrc"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&rrc_rolloff, pJson["rrcRolloff"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&pll_psk_order, pJson["pllPskOrder"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&input_type, pJson["inputType"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&rgb_color, pJson["rgbColor"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&title, pJson["title"], "QString", "QString");
|
||||
|
||||
::SWGSDRangel::setValue(&spectrum_config, pJson["spectrumConfig"], "SWGGLSpectrum", "SWGGLSpectrum");
|
||||
|
||||
::SWGSDRangel::setValue(&scope_config, pJson["scopeConfig"], "SWGGLScope", "SWGGLScope");
|
||||
|
||||
}
|
||||
|
||||
QString
|
||||
SWGChannelAnalyzerSettings::asJson ()
|
||||
{
|
||||
QJsonObject* obj = this->asJsonObject();
|
||||
|
||||
QJsonDocument doc(*obj);
|
||||
QByteArray bytes = doc.toJson();
|
||||
delete obj;
|
||||
return QString(bytes);
|
||||
}
|
||||
|
||||
QJsonObject*
|
||||
SWGChannelAnalyzerSettings::asJsonObject() {
|
||||
QJsonObject* obj = new QJsonObject();
|
||||
if(m_frequency_isSet){
|
||||
obj->insert("frequency", QJsonValue(frequency));
|
||||
}
|
||||
if(m_down_sample_isSet){
|
||||
obj->insert("downSample", QJsonValue(down_sample));
|
||||
}
|
||||
if(m_down_sample_rate_isSet){
|
||||
obj->insert("downSampleRate", QJsonValue(down_sample_rate));
|
||||
}
|
||||
if(m_bandwidth_isSet){
|
||||
obj->insert("bandwidth", QJsonValue(bandwidth));
|
||||
}
|
||||
if(m_low_cutoff_isSet){
|
||||
obj->insert("lowCutoff", QJsonValue(low_cutoff));
|
||||
}
|
||||
if(m_span_log2_isSet){
|
||||
obj->insert("spanLog2", QJsonValue(span_log2));
|
||||
}
|
||||
if(m_ssb_isSet){
|
||||
obj->insert("ssb", QJsonValue(ssb));
|
||||
}
|
||||
if(m_pll_isSet){
|
||||
obj->insert("pll", QJsonValue(pll));
|
||||
}
|
||||
if(m_fll_isSet){
|
||||
obj->insert("fll", QJsonValue(fll));
|
||||
}
|
||||
if(m_rrc_isSet){
|
||||
obj->insert("rrc", QJsonValue(rrc));
|
||||
}
|
||||
if(m_rrc_rolloff_isSet){
|
||||
obj->insert("rrcRolloff", QJsonValue(rrc_rolloff));
|
||||
}
|
||||
if(m_pll_psk_order_isSet){
|
||||
obj->insert("pllPskOrder", QJsonValue(pll_psk_order));
|
||||
}
|
||||
if(m_input_type_isSet){
|
||||
obj->insert("inputType", QJsonValue(input_type));
|
||||
}
|
||||
if(m_rgb_color_isSet){
|
||||
obj->insert("rgbColor", QJsonValue(rgb_color));
|
||||
}
|
||||
if(title != nullptr && *title != QString("")){
|
||||
toJsonValue(QString("title"), title, obj, QString("QString"));
|
||||
}
|
||||
if((spectrum_config != nullptr) && (spectrum_config->isSet())){
|
||||
toJsonValue(QString("spectrumConfig"), spectrum_config, obj, QString("SWGGLSpectrum"));
|
||||
}
|
||||
if((scope_config != nullptr) && (scope_config->isSet())){
|
||||
toJsonValue(QString("scopeConfig"), scope_config, obj, QString("SWGGLScope"));
|
||||
}
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getFrequency() {
|
||||
return frequency;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setFrequency(qint32 frequency) {
|
||||
this->frequency = frequency;
|
||||
this->m_frequency_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getDownSample() {
|
||||
return down_sample;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setDownSample(qint32 down_sample) {
|
||||
this->down_sample = down_sample;
|
||||
this->m_down_sample_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getDownSampleRate() {
|
||||
return down_sample_rate;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setDownSampleRate(qint32 down_sample_rate) {
|
||||
this->down_sample_rate = down_sample_rate;
|
||||
this->m_down_sample_rate_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getBandwidth() {
|
||||
return bandwidth;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setBandwidth(qint32 bandwidth) {
|
||||
this->bandwidth = bandwidth;
|
||||
this->m_bandwidth_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getLowCutoff() {
|
||||
return low_cutoff;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setLowCutoff(qint32 low_cutoff) {
|
||||
this->low_cutoff = low_cutoff;
|
||||
this->m_low_cutoff_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getSpanLog2() {
|
||||
return span_log2;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setSpanLog2(qint32 span_log2) {
|
||||
this->span_log2 = span_log2;
|
||||
this->m_span_log2_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getSsb() {
|
||||
return ssb;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setSsb(qint32 ssb) {
|
||||
this->ssb = ssb;
|
||||
this->m_ssb_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getPll() {
|
||||
return pll;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setPll(qint32 pll) {
|
||||
this->pll = pll;
|
||||
this->m_pll_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getFll() {
|
||||
return fll;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setFll(qint32 fll) {
|
||||
this->fll = fll;
|
||||
this->m_fll_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getRrc() {
|
||||
return rrc;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setRrc(qint32 rrc) {
|
||||
this->rrc = rrc;
|
||||
this->m_rrc_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getRrcRolloff() {
|
||||
return rrc_rolloff;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setRrcRolloff(qint32 rrc_rolloff) {
|
||||
this->rrc_rolloff = rrc_rolloff;
|
||||
this->m_rrc_rolloff_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getPllPskOrder() {
|
||||
return pll_psk_order;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setPllPskOrder(qint32 pll_psk_order) {
|
||||
this->pll_psk_order = pll_psk_order;
|
||||
this->m_pll_psk_order_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getInputType() {
|
||||
return input_type;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setInputType(qint32 input_type) {
|
||||
this->input_type = input_type;
|
||||
this->m_input_type_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGChannelAnalyzerSettings::getRgbColor() {
|
||||
return rgb_color;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setRgbColor(qint32 rgb_color) {
|
||||
this->rgb_color = rgb_color;
|
||||
this->m_rgb_color_isSet = true;
|
||||
}
|
||||
|
||||
QString*
|
||||
SWGChannelAnalyzerSettings::getTitle() {
|
||||
return title;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setTitle(QString* title) {
|
||||
this->title = title;
|
||||
this->m_title_isSet = true;
|
||||
}
|
||||
|
||||
SWGGLSpectrum*
|
||||
SWGChannelAnalyzerSettings::getSpectrumConfig() {
|
||||
return spectrum_config;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setSpectrumConfig(SWGGLSpectrum* spectrum_config) {
|
||||
this->spectrum_config = spectrum_config;
|
||||
this->m_spectrum_config_isSet = true;
|
||||
}
|
||||
|
||||
SWGGLScope*
|
||||
SWGChannelAnalyzerSettings::getScopeConfig() {
|
||||
return scope_config;
|
||||
}
|
||||
void
|
||||
SWGChannelAnalyzerSettings::setScopeConfig(SWGGLScope* scope_config) {
|
||||
this->scope_config = scope_config;
|
||||
this->m_scope_config_isSet = true;
|
||||
}
|
||||
|
||||
|
||||
bool
|
||||
SWGChannelAnalyzerSettings::isSet(){
|
||||
bool isObjectUpdated = false;
|
||||
do{
|
||||
if(m_frequency_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_down_sample_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_down_sample_rate_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_bandwidth_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_low_cutoff_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_span_log2_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_ssb_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_pll_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_fll_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_rrc_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_rrc_rolloff_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_pll_psk_order_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_input_type_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_rgb_color_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(title && *title != QString("")){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(spectrum_config && spectrum_config->isSet()){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(scope_config && scope_config->isSet()){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
}while(false);
|
||||
return isObjectUpdated;
|
||||
}
|
||||
}
|
||||
|
157
swagger/sdrangel/code/qt5/client/SWGChannelAnalyzerSettings.h
Normal file
157
swagger/sdrangel/code/qt5/client/SWGChannelAnalyzerSettings.h
Normal file
@ -0,0 +1,157 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
/*
|
||||
* SWGChannelAnalyzerSettings.h
|
||||
*
|
||||
* ChannelAnalyzer
|
||||
*/
|
||||
|
||||
#ifndef SWGChannelAnalyzerSettings_H_
|
||||
#define SWGChannelAnalyzerSettings_H_
|
||||
|
||||
#include <QJsonObject>
|
||||
|
||||
|
||||
#include "SWGGLScope.h"
|
||||
#include "SWGGLSpectrum.h"
|
||||
#include <QString>
|
||||
|
||||
#include "SWGObject.h"
|
||||
#include "export.h"
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
class SWG_API SWGChannelAnalyzerSettings: public SWGObject {
|
||||
public:
|
||||
SWGChannelAnalyzerSettings();
|
||||
SWGChannelAnalyzerSettings(QString* json);
|
||||
virtual ~SWGChannelAnalyzerSettings();
|
||||
void init();
|
||||
void cleanup();
|
||||
|
||||
virtual QString asJson () override;
|
||||
virtual QJsonObject* asJsonObject() override;
|
||||
virtual void fromJsonObject(QJsonObject &json) override;
|
||||
virtual SWGChannelAnalyzerSettings* fromJson(QString &jsonString) override;
|
||||
|
||||
qint32 getFrequency();
|
||||
void setFrequency(qint32 frequency);
|
||||
|
||||
qint32 getDownSample();
|
||||
void setDownSample(qint32 down_sample);
|
||||
|
||||
qint32 getDownSampleRate();
|
||||
void setDownSampleRate(qint32 down_sample_rate);
|
||||
|
||||
qint32 getBandwidth();
|
||||
void setBandwidth(qint32 bandwidth);
|
||||
|
||||
qint32 getLowCutoff();
|
||||
void setLowCutoff(qint32 low_cutoff);
|
||||
|
||||
qint32 getSpanLog2();
|
||||
void setSpanLog2(qint32 span_log2);
|
||||
|
||||
qint32 getSsb();
|
||||
void setSsb(qint32 ssb);
|
||||
|
||||
qint32 getPll();
|
||||
void setPll(qint32 pll);
|
||||
|
||||
qint32 getFll();
|
||||
void setFll(qint32 fll);
|
||||
|
||||
qint32 getRrc();
|
||||
void setRrc(qint32 rrc);
|
||||
|
||||
qint32 getRrcRolloff();
|
||||
void setRrcRolloff(qint32 rrc_rolloff);
|
||||
|
||||
qint32 getPllPskOrder();
|
||||
void setPllPskOrder(qint32 pll_psk_order);
|
||||
|
||||
qint32 getInputType();
|
||||
void setInputType(qint32 input_type);
|
||||
|
||||
qint32 getRgbColor();
|
||||
void setRgbColor(qint32 rgb_color);
|
||||
|
||||
QString* getTitle();
|
||||
void setTitle(QString* title);
|
||||
|
||||
SWGGLSpectrum* getSpectrumConfig();
|
||||
void setSpectrumConfig(SWGGLSpectrum* spectrum_config);
|
||||
|
||||
SWGGLScope* getScopeConfig();
|
||||
void setScopeConfig(SWGGLScope* scope_config);
|
||||
|
||||
|
||||
virtual bool isSet() override;
|
||||
|
||||
private:
|
||||
qint32 frequency;
|
||||
bool m_frequency_isSet;
|
||||
|
||||
qint32 down_sample;
|
||||
bool m_down_sample_isSet;
|
||||
|
||||
qint32 down_sample_rate;
|
||||
bool m_down_sample_rate_isSet;
|
||||
|
||||
qint32 bandwidth;
|
||||
bool m_bandwidth_isSet;
|
||||
|
||||
qint32 low_cutoff;
|
||||
bool m_low_cutoff_isSet;
|
||||
|
||||
qint32 span_log2;
|
||||
bool m_span_log2_isSet;
|
||||
|
||||
qint32 ssb;
|
||||
bool m_ssb_isSet;
|
||||
|
||||
qint32 pll;
|
||||
bool m_pll_isSet;
|
||||
|
||||
qint32 fll;
|
||||
bool m_fll_isSet;
|
||||
|
||||
qint32 rrc;
|
||||
bool m_rrc_isSet;
|
||||
|
||||
qint32 rrc_rolloff;
|
||||
bool m_rrc_rolloff_isSet;
|
||||
|
||||
qint32 pll_psk_order;
|
||||
bool m_pll_psk_order_isSet;
|
||||
|
||||
qint32 input_type;
|
||||
bool m_input_type_isSet;
|
||||
|
||||
qint32 rgb_color;
|
||||
bool m_rgb_color_isSet;
|
||||
|
||||
QString* title;
|
||||
bool m_title_isSet;
|
||||
|
||||
SWGGLSpectrum* spectrum_config;
|
||||
bool m_spectrum_config_isSet;
|
||||
|
||||
SWGGLScope* scope_config;
|
||||
bool m_scope_config_isSet;
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif /* SWGChannelAnalyzerSettings_H_ */
|
@ -44,6 +44,8 @@ SWGChannelSettings::SWGChannelSettings() {
|
||||
m_atv_mod_settings_isSet = false;
|
||||
bfm_demod_settings = nullptr;
|
||||
m_bfm_demod_settings_isSet = false;
|
||||
channel_analyzer_settings = nullptr;
|
||||
m_channel_analyzer_settings_isSet = false;
|
||||
dsd_demod_settings = nullptr;
|
||||
m_dsd_demod_settings_isSet = false;
|
||||
file_source_settings = nullptr;
|
||||
@ -102,6 +104,8 @@ SWGChannelSettings::init() {
|
||||
m_atv_mod_settings_isSet = false;
|
||||
bfm_demod_settings = new SWGBFMDemodSettings();
|
||||
m_bfm_demod_settings_isSet = false;
|
||||
channel_analyzer_settings = new SWGChannelAnalyzerSettings();
|
||||
m_channel_analyzer_settings_isSet = false;
|
||||
dsd_demod_settings = new SWGDSDDemodSettings();
|
||||
m_dsd_demod_settings_isSet = false;
|
||||
file_source_settings = new SWGFileSourceSettings();
|
||||
@ -158,6 +162,9 @@ SWGChannelSettings::cleanup() {
|
||||
if(bfm_demod_settings != nullptr) {
|
||||
delete bfm_demod_settings;
|
||||
}
|
||||
if(channel_analyzer_settings != nullptr) {
|
||||
delete channel_analyzer_settings;
|
||||
}
|
||||
if(dsd_demod_settings != nullptr) {
|
||||
delete dsd_demod_settings;
|
||||
}
|
||||
@ -238,6 +245,8 @@ SWGChannelSettings::fromJsonObject(QJsonObject &pJson) {
|
||||
|
||||
::SWGSDRangel::setValue(&bfm_demod_settings, pJson["BFMDemodSettings"], "SWGBFMDemodSettings", "SWGBFMDemodSettings");
|
||||
|
||||
::SWGSDRangel::setValue(&channel_analyzer_settings, pJson["ChannelAnalyzerSettings"], "SWGChannelAnalyzerSettings", "SWGChannelAnalyzerSettings");
|
||||
|
||||
::SWGSDRangel::setValue(&dsd_demod_settings, pJson["DSDDemodSettings"], "SWGDSDDemodSettings", "SWGDSDDemodSettings");
|
||||
|
||||
::SWGSDRangel::setValue(&file_source_settings, pJson["FileSourceSettings"], "SWGFileSourceSettings", "SWGFileSourceSettings");
|
||||
@ -312,6 +321,9 @@ SWGChannelSettings::asJsonObject() {
|
||||
if((bfm_demod_settings != nullptr) && (bfm_demod_settings->isSet())){
|
||||
toJsonValue(QString("BFMDemodSettings"), bfm_demod_settings, obj, QString("SWGBFMDemodSettings"));
|
||||
}
|
||||
if((channel_analyzer_settings != nullptr) && (channel_analyzer_settings->isSet())){
|
||||
toJsonValue(QString("ChannelAnalyzerSettings"), channel_analyzer_settings, obj, QString("SWGChannelAnalyzerSettings"));
|
||||
}
|
||||
if((dsd_demod_settings != nullptr) && (dsd_demod_settings->isSet())){
|
||||
toJsonValue(QString("DSDDemodSettings"), dsd_demod_settings, obj, QString("SWGDSDDemodSettings"));
|
||||
}
|
||||
@ -447,6 +459,16 @@ SWGChannelSettings::setBfmDemodSettings(SWGBFMDemodSettings* bfm_demod_settings)
|
||||
this->m_bfm_demod_settings_isSet = true;
|
||||
}
|
||||
|
||||
SWGChannelAnalyzerSettings*
|
||||
SWGChannelSettings::getChannelAnalyzerSettings() {
|
||||
return channel_analyzer_settings;
|
||||
}
|
||||
void
|
||||
SWGChannelSettings::setChannelAnalyzerSettings(SWGChannelAnalyzerSettings* channel_analyzer_settings) {
|
||||
this->channel_analyzer_settings = channel_analyzer_settings;
|
||||
this->m_channel_analyzer_settings_isSet = true;
|
||||
}
|
||||
|
||||
SWGDSDDemodSettings*
|
||||
SWGChannelSettings::getDsdDemodSettings() {
|
||||
return dsd_demod_settings;
|
||||
@ -646,6 +668,9 @@ SWGChannelSettings::isSet(){
|
||||
if(bfm_demod_settings && bfm_demod_settings->isSet()){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(channel_analyzer_settings && channel_analyzer_settings->isSet()){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(dsd_demod_settings && dsd_demod_settings->isSet()){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
|
@ -26,6 +26,7 @@
|
||||
#include "SWGAMModSettings.h"
|
||||
#include "SWGATVModSettings.h"
|
||||
#include "SWGBFMDemodSettings.h"
|
||||
#include "SWGChannelAnalyzerSettings.h"
|
||||
#include "SWGDSDDemodSettings.h"
|
||||
#include "SWGFileSourceSettings.h"
|
||||
#include "SWGFreeDVDemodSettings.h"
|
||||
@ -87,6 +88,9 @@ public:
|
||||
SWGBFMDemodSettings* getBfmDemodSettings();
|
||||
void setBfmDemodSettings(SWGBFMDemodSettings* bfm_demod_settings);
|
||||
|
||||
SWGChannelAnalyzerSettings* getChannelAnalyzerSettings();
|
||||
void setChannelAnalyzerSettings(SWGChannelAnalyzerSettings* channel_analyzer_settings);
|
||||
|
||||
SWGDSDDemodSettings* getDsdDemodSettings();
|
||||
void setDsdDemodSettings(SWGDSDDemodSettings* dsd_demod_settings);
|
||||
|
||||
@ -166,6 +170,9 @@ private:
|
||||
SWGBFMDemodSettings* bfm_demod_settings;
|
||||
bool m_bfm_demod_settings_isSet;
|
||||
|
||||
SWGChannelAnalyzerSettings* channel_analyzer_settings;
|
||||
bool m_channel_analyzer_settings_isSet;
|
||||
|
||||
SWGDSDDemodSettings* dsd_demod_settings;
|
||||
bool m_dsd_demod_settings_isSet;
|
||||
|
||||
|
304
swagger/sdrangel/code/qt5/client/SWGGLScope.cpp
Normal file
304
swagger/sdrangel/code/qt5/client/SWGGLScope.cpp
Normal file
@ -0,0 +1,304 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
|
||||
#include "SWGGLScope.h"
|
||||
|
||||
#include "SWGHelpers.h"
|
||||
|
||||
#include <QJsonDocument>
|
||||
#include <QJsonArray>
|
||||
#include <QObject>
|
||||
#include <QDebug>
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
SWGGLScope::SWGGLScope(QString* json) {
|
||||
init();
|
||||
this->fromJson(*json);
|
||||
}
|
||||
|
||||
SWGGLScope::SWGGLScope() {
|
||||
display_mode = 0;
|
||||
m_display_mode_isSet = false;
|
||||
trace_intensity = 0;
|
||||
m_trace_intensity_isSet = false;
|
||||
grid_intensity = 0;
|
||||
m_grid_intensity_isSet = false;
|
||||
time = 0;
|
||||
m_time_isSet = false;
|
||||
time_ofs = 0;
|
||||
m_time_ofs_isSet = false;
|
||||
trace_len = 0;
|
||||
m_trace_len_isSet = false;
|
||||
trig_pre = 0;
|
||||
m_trig_pre_isSet = false;
|
||||
traces_data = nullptr;
|
||||
m_traces_data_isSet = false;
|
||||
m_triggers_data = nullptr;
|
||||
m_m_triggers_data_isSet = false;
|
||||
}
|
||||
|
||||
SWGGLScope::~SWGGLScope() {
|
||||
this->cleanup();
|
||||
}
|
||||
|
||||
void
|
||||
SWGGLScope::init() {
|
||||
display_mode = 0;
|
||||
m_display_mode_isSet = false;
|
||||
trace_intensity = 0;
|
||||
m_trace_intensity_isSet = false;
|
||||
grid_intensity = 0;
|
||||
m_grid_intensity_isSet = false;
|
||||
time = 0;
|
||||
m_time_isSet = false;
|
||||
time_ofs = 0;
|
||||
m_time_ofs_isSet = false;
|
||||
trace_len = 0;
|
||||
m_trace_len_isSet = false;
|
||||
trig_pre = 0;
|
||||
m_trig_pre_isSet = false;
|
||||
traces_data = new QList<SWGTraceData*>();
|
||||
m_traces_data_isSet = false;
|
||||
m_triggers_data = new QList<SWGTriggerData*>();
|
||||
m_m_triggers_data_isSet = false;
|
||||
}
|
||||
|
||||
void
|
||||
SWGGLScope::cleanup() {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if(traces_data != nullptr) {
|
||||
auto arr = traces_data;
|
||||
for(auto o: *arr) {
|
||||
delete o;
|
||||
}
|
||||
delete traces_data;
|
||||
}
|
||||
if(m_triggers_data != nullptr) {
|
||||
auto arr = m_triggers_data;
|
||||
for(auto o: *arr) {
|
||||
delete o;
|
||||
}
|
||||
delete m_triggers_data;
|
||||
}
|
||||
}
|
||||
|
||||
SWGGLScope*
|
||||
SWGGLScope::fromJson(QString &json) {
|
||||
QByteArray array (json.toStdString().c_str());
|
||||
QJsonDocument doc = QJsonDocument::fromJson(array);
|
||||
QJsonObject jsonObject = doc.object();
|
||||
this->fromJsonObject(jsonObject);
|
||||
return this;
|
||||
}
|
||||
|
||||
void
|
||||
SWGGLScope::fromJsonObject(QJsonObject &pJson) {
|
||||
::SWGSDRangel::setValue(&display_mode, pJson["displayMode"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_intensity, pJson["traceIntensity"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&grid_intensity, pJson["gridIntensity"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&time, pJson["time"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&time_ofs, pJson["timeOfs"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_len, pJson["traceLen"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trig_pre, pJson["trigPre"], "qint32", "");
|
||||
|
||||
|
||||
::SWGSDRangel::setValue(&traces_data, pJson["tracesData"], "QList", "SWGTraceData");
|
||||
|
||||
::SWGSDRangel::setValue(&m_triggers_data, pJson["m_triggersData"], "QList", "SWGTriggerData");
|
||||
}
|
||||
|
||||
QString
|
||||
SWGGLScope::asJson ()
|
||||
{
|
||||
QJsonObject* obj = this->asJsonObject();
|
||||
|
||||
QJsonDocument doc(*obj);
|
||||
QByteArray bytes = doc.toJson();
|
||||
delete obj;
|
||||
return QString(bytes);
|
||||
}
|
||||
|
||||
QJsonObject*
|
||||
SWGGLScope::asJsonObject() {
|
||||
QJsonObject* obj = new QJsonObject();
|
||||
if(m_display_mode_isSet){
|
||||
obj->insert("displayMode", QJsonValue(display_mode));
|
||||
}
|
||||
if(m_trace_intensity_isSet){
|
||||
obj->insert("traceIntensity", QJsonValue(trace_intensity));
|
||||
}
|
||||
if(m_grid_intensity_isSet){
|
||||
obj->insert("gridIntensity", QJsonValue(grid_intensity));
|
||||
}
|
||||
if(m_time_isSet){
|
||||
obj->insert("time", QJsonValue(time));
|
||||
}
|
||||
if(m_time_ofs_isSet){
|
||||
obj->insert("timeOfs", QJsonValue(time_ofs));
|
||||
}
|
||||
if(m_trace_len_isSet){
|
||||
obj->insert("traceLen", QJsonValue(trace_len));
|
||||
}
|
||||
if(m_trig_pre_isSet){
|
||||
obj->insert("trigPre", QJsonValue(trig_pre));
|
||||
}
|
||||
if(traces_data && traces_data->size() > 0){
|
||||
toJsonArray((QList<void*>*)traces_data, obj, "tracesData", "SWGTraceData");
|
||||
}
|
||||
if(m_triggers_data && m_triggers_data->size() > 0){
|
||||
toJsonArray((QList<void*>*)m_triggers_data, obj, "m_triggersData", "SWGTriggerData");
|
||||
}
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getDisplayMode() {
|
||||
return display_mode;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setDisplayMode(qint32 display_mode) {
|
||||
this->display_mode = display_mode;
|
||||
this->m_display_mode_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getTraceIntensity() {
|
||||
return trace_intensity;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setTraceIntensity(qint32 trace_intensity) {
|
||||
this->trace_intensity = trace_intensity;
|
||||
this->m_trace_intensity_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getGridIntensity() {
|
||||
return grid_intensity;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setGridIntensity(qint32 grid_intensity) {
|
||||
this->grid_intensity = grid_intensity;
|
||||
this->m_grid_intensity_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getTime() {
|
||||
return time;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setTime(qint32 time) {
|
||||
this->time = time;
|
||||
this->m_time_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getTimeOfs() {
|
||||
return time_ofs;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setTimeOfs(qint32 time_ofs) {
|
||||
this->time_ofs = time_ofs;
|
||||
this->m_time_ofs_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getTraceLen() {
|
||||
return trace_len;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setTraceLen(qint32 trace_len) {
|
||||
this->trace_len = trace_len;
|
||||
this->m_trace_len_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGGLScope::getTrigPre() {
|
||||
return trig_pre;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setTrigPre(qint32 trig_pre) {
|
||||
this->trig_pre = trig_pre;
|
||||
this->m_trig_pre_isSet = true;
|
||||
}
|
||||
|
||||
QList<SWGTraceData*>*
|
||||
SWGGLScope::getTracesData() {
|
||||
return traces_data;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setTracesData(QList<SWGTraceData*>* traces_data) {
|
||||
this->traces_data = traces_data;
|
||||
this->m_traces_data_isSet = true;
|
||||
}
|
||||
|
||||
QList<SWGTriggerData*>*
|
||||
SWGGLScope::getMTriggersData() {
|
||||
return m_triggers_data;
|
||||
}
|
||||
void
|
||||
SWGGLScope::setMTriggersData(QList<SWGTriggerData*>* m_triggers_data) {
|
||||
this->m_triggers_data = m_triggers_data;
|
||||
this->m_m_triggers_data_isSet = true;
|
||||
}
|
||||
|
||||
|
||||
bool
|
||||
SWGGLScope::isSet(){
|
||||
bool isObjectUpdated = false;
|
||||
do{
|
||||
if(m_display_mode_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_intensity_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_grid_intensity_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_time_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_time_ofs_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_len_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trig_pre_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(traces_data && (traces_data->size() > 0)){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_triggers_data && (m_triggers_data->size() > 0)){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
}while(false);
|
||||
return isObjectUpdated;
|
||||
}
|
||||
}
|
||||
|
109
swagger/sdrangel/code/qt5/client/SWGGLScope.h
Normal file
109
swagger/sdrangel/code/qt5/client/SWGGLScope.h
Normal file
@ -0,0 +1,109 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
/*
|
||||
* SWGGLScope.h
|
||||
*
|
||||
* GLScopeGUI settings
|
||||
*/
|
||||
|
||||
#ifndef SWGGLScope_H_
|
||||
#define SWGGLScope_H_
|
||||
|
||||
#include <QJsonObject>
|
||||
|
||||
|
||||
#include "SWGTraceData.h"
|
||||
#include "SWGTriggerData.h"
|
||||
#include <QList>
|
||||
|
||||
#include "SWGObject.h"
|
||||
#include "export.h"
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
class SWG_API SWGGLScope: public SWGObject {
|
||||
public:
|
||||
SWGGLScope();
|
||||
SWGGLScope(QString* json);
|
||||
virtual ~SWGGLScope();
|
||||
void init();
|
||||
void cleanup();
|
||||
|
||||
virtual QString asJson () override;
|
||||
virtual QJsonObject* asJsonObject() override;
|
||||
virtual void fromJsonObject(QJsonObject &json) override;
|
||||
virtual SWGGLScope* fromJson(QString &jsonString) override;
|
||||
|
||||
qint32 getDisplayMode();
|
||||
void setDisplayMode(qint32 display_mode);
|
||||
|
||||
qint32 getTraceIntensity();
|
||||
void setTraceIntensity(qint32 trace_intensity);
|
||||
|
||||
qint32 getGridIntensity();
|
||||
void setGridIntensity(qint32 grid_intensity);
|
||||
|
||||
qint32 getTime();
|
||||
void setTime(qint32 time);
|
||||
|
||||
qint32 getTimeOfs();
|
||||
void setTimeOfs(qint32 time_ofs);
|
||||
|
||||
qint32 getTraceLen();
|
||||
void setTraceLen(qint32 trace_len);
|
||||
|
||||
qint32 getTrigPre();
|
||||
void setTrigPre(qint32 trig_pre);
|
||||
|
||||
QList<SWGTraceData*>* getTracesData();
|
||||
void setTracesData(QList<SWGTraceData*>* traces_data);
|
||||
|
||||
QList<SWGTriggerData*>* getMTriggersData();
|
||||
void setMTriggersData(QList<SWGTriggerData*>* m_triggers_data);
|
||||
|
||||
|
||||
virtual bool isSet() override;
|
||||
|
||||
private:
|
||||
qint32 display_mode;
|
||||
bool m_display_mode_isSet;
|
||||
|
||||
qint32 trace_intensity;
|
||||
bool m_trace_intensity_isSet;
|
||||
|
||||
qint32 grid_intensity;
|
||||
bool m_grid_intensity_isSet;
|
||||
|
||||
qint32 time;
|
||||
bool m_time_isSet;
|
||||
|
||||
qint32 time_ofs;
|
||||
bool m_time_ofs_isSet;
|
||||
|
||||
qint32 trace_len;
|
||||
bool m_trace_len_isSet;
|
||||
|
||||
qint32 trig_pre;
|
||||
bool m_trig_pre_isSet;
|
||||
|
||||
QList<SWGTraceData*>* traces_data;
|
||||
bool m_traces_data_isSet;
|
||||
|
||||
QList<SWGTriggerData*>* m_triggers_data;
|
||||
bool m_m_triggers_data_isSet;
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif /* SWGGLScope_H_ */
|
@ -42,6 +42,7 @@
|
||||
#include "SWGBladeRF2OutputSettings.h"
|
||||
#include "SWGCWKeyerSettings.h"
|
||||
#include "SWGChannel.h"
|
||||
#include "SWGChannelAnalyzerSettings.h"
|
||||
#include "SWGChannelConfig.h"
|
||||
#include "SWGChannelListItem.h"
|
||||
#include "SWGChannelReport.h"
|
||||
@ -76,6 +77,7 @@
|
||||
#include "SWGFrequency.h"
|
||||
#include "SWGFrequencyBand.h"
|
||||
#include "SWGFrequencyRange.h"
|
||||
#include "SWGGLScope.h"
|
||||
#include "SWGGLSpectrum.h"
|
||||
#include "SWGGain.h"
|
||||
#include "SWGHackRFInputSettings.h"
|
||||
@ -148,6 +150,8 @@
|
||||
#include "SWGTestMISettings.h"
|
||||
#include "SWGTestMiStreamSettings.h"
|
||||
#include "SWGTestSourceSettings.h"
|
||||
#include "SWGTraceData.h"
|
||||
#include "SWGTriggerData.h"
|
||||
#include "SWGUDPSinkReport.h"
|
||||
#include "SWGUDPSinkSettings.h"
|
||||
#include "SWGUDPSourceReport.h"
|
||||
@ -248,6 +252,9 @@ namespace SWGSDRangel {
|
||||
if(QString("SWGChannel").compare(type) == 0) {
|
||||
return new SWGChannel();
|
||||
}
|
||||
if(QString("SWGChannelAnalyzerSettings").compare(type) == 0) {
|
||||
return new SWGChannelAnalyzerSettings();
|
||||
}
|
||||
if(QString("SWGChannelConfig").compare(type) == 0) {
|
||||
return new SWGChannelConfig();
|
||||
}
|
||||
@ -350,6 +357,9 @@ namespace SWGSDRangel {
|
||||
if(QString("SWGFrequencyRange").compare(type) == 0) {
|
||||
return new SWGFrequencyRange();
|
||||
}
|
||||
if(QString("SWGGLScope").compare(type) == 0) {
|
||||
return new SWGGLScope();
|
||||
}
|
||||
if(QString("SWGGLSpectrum").compare(type) == 0) {
|
||||
return new SWGGLSpectrum();
|
||||
}
|
||||
@ -566,6 +576,12 @@ namespace SWGSDRangel {
|
||||
if(QString("SWGTestSourceSettings").compare(type) == 0) {
|
||||
return new SWGTestSourceSettings();
|
||||
}
|
||||
if(QString("SWGTraceData").compare(type) == 0) {
|
||||
return new SWGTraceData();
|
||||
}
|
||||
if(QString("SWGTriggerData").compare(type) == 0) {
|
||||
return new SWGTriggerData();
|
||||
}
|
||||
if(QString("SWGUDPSinkReport").compare(type) == 0) {
|
||||
return new SWGUDPSinkReport();
|
||||
}
|
||||
|
501
swagger/sdrangel/code/qt5/client/SWGTraceData.cpp
Normal file
501
swagger/sdrangel/code/qt5/client/SWGTraceData.cpp
Normal file
@ -0,0 +1,501 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
|
||||
#include "SWGTraceData.h"
|
||||
|
||||
#include "SWGHelpers.h"
|
||||
|
||||
#include <QJsonDocument>
|
||||
#include <QJsonArray>
|
||||
#include <QObject>
|
||||
#include <QDebug>
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
SWGTraceData::SWGTraceData(QString* json) {
|
||||
init();
|
||||
this->fromJson(*json);
|
||||
}
|
||||
|
||||
SWGTraceData::SWGTraceData() {
|
||||
projection_type = 0;
|
||||
m_projection_type_isSet = false;
|
||||
input_index = 0;
|
||||
m_input_index_isSet = false;
|
||||
amp = 0.0f;
|
||||
m_amp_isSet = false;
|
||||
amp_index = 0;
|
||||
m_amp_index_isSet = false;
|
||||
ofs = 0.0f;
|
||||
m_ofs_isSet = false;
|
||||
ofs_coarse = 0;
|
||||
m_ofs_coarse_isSet = false;
|
||||
ofs_fine = 0;
|
||||
m_ofs_fine_isSet = false;
|
||||
trace_delay = 0;
|
||||
m_trace_delay_isSet = false;
|
||||
trace_delay_coarse = 0;
|
||||
m_trace_delay_coarse_isSet = false;
|
||||
trace_delay_fine = 0;
|
||||
m_trace_delay_fine_isSet = false;
|
||||
trigger_display_level = 0.0f;
|
||||
m_trigger_display_level_isSet = false;
|
||||
trace_color = 0;
|
||||
m_trace_color_isSet = false;
|
||||
trace_color_r = 0.0f;
|
||||
m_trace_color_r_isSet = false;
|
||||
trace_color_g = 0.0f;
|
||||
m_trace_color_g_isSet = false;
|
||||
trace_color_b = 0.0f;
|
||||
m_trace_color_b_isSet = false;
|
||||
has_text_overlay = 0;
|
||||
m_has_text_overlay_isSet = false;
|
||||
text_overlay = nullptr;
|
||||
m_text_overlay_isSet = false;
|
||||
view_trace = 0;
|
||||
m_view_trace_isSet = false;
|
||||
}
|
||||
|
||||
SWGTraceData::~SWGTraceData() {
|
||||
this->cleanup();
|
||||
}
|
||||
|
||||
void
|
||||
SWGTraceData::init() {
|
||||
projection_type = 0;
|
||||
m_projection_type_isSet = false;
|
||||
input_index = 0;
|
||||
m_input_index_isSet = false;
|
||||
amp = 0.0f;
|
||||
m_amp_isSet = false;
|
||||
amp_index = 0;
|
||||
m_amp_index_isSet = false;
|
||||
ofs = 0.0f;
|
||||
m_ofs_isSet = false;
|
||||
ofs_coarse = 0;
|
||||
m_ofs_coarse_isSet = false;
|
||||
ofs_fine = 0;
|
||||
m_ofs_fine_isSet = false;
|
||||
trace_delay = 0;
|
||||
m_trace_delay_isSet = false;
|
||||
trace_delay_coarse = 0;
|
||||
m_trace_delay_coarse_isSet = false;
|
||||
trace_delay_fine = 0;
|
||||
m_trace_delay_fine_isSet = false;
|
||||
trigger_display_level = 0.0f;
|
||||
m_trigger_display_level_isSet = false;
|
||||
trace_color = 0;
|
||||
m_trace_color_isSet = false;
|
||||
trace_color_r = 0.0f;
|
||||
m_trace_color_r_isSet = false;
|
||||
trace_color_g = 0.0f;
|
||||
m_trace_color_g_isSet = false;
|
||||
trace_color_b = 0.0f;
|
||||
m_trace_color_b_isSet = false;
|
||||
has_text_overlay = 0;
|
||||
m_has_text_overlay_isSet = false;
|
||||
text_overlay = new QString("");
|
||||
m_text_overlay_isSet = false;
|
||||
view_trace = 0;
|
||||
m_view_trace_isSet = false;
|
||||
}
|
||||
|
||||
void
|
||||
SWGTraceData::cleanup() {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if(text_overlay != nullptr) {
|
||||
delete text_overlay;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
SWGTraceData*
|
||||
SWGTraceData::fromJson(QString &json) {
|
||||
QByteArray array (json.toStdString().c_str());
|
||||
QJsonDocument doc = QJsonDocument::fromJson(array);
|
||||
QJsonObject jsonObject = doc.object();
|
||||
this->fromJsonObject(jsonObject);
|
||||
return this;
|
||||
}
|
||||
|
||||
void
|
||||
SWGTraceData::fromJsonObject(QJsonObject &pJson) {
|
||||
::SWGSDRangel::setValue(&projection_type, pJson["projectionType"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&input_index, pJson["inputIndex"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&, pJson["amp"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&_index, pJson["ampIndex"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&ofs, pJson["ofs"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&ofs_coarse, pJson["ofsCoarse"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&ofs_fine, pJson["ofsFine"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_delay, pJson["traceDelay"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_delay_coarse, pJson["traceDelayCoarse"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_delay_fine, pJson["traceDelayFine"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_display_level, pJson["triggerDisplayLevel"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_color, pJson["traceColor"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_color_r, pJson["traceColorR"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_color_g, pJson["traceColorG"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trace_color_b, pJson["traceColorB"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&has_text_overlay, pJson["hasTextOverlay"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&text_overlay, pJson["textOverlay"], "QString", "QString");
|
||||
|
||||
::SWGSDRangel::setValue(&view_trace, pJson["viewTrace"], "qint32", "");
|
||||
|
||||
}
|
||||
|
||||
QString
|
||||
SWGTraceData::asJson ()
|
||||
{
|
||||
QJsonObject* obj = this->asJsonObject();
|
||||
|
||||
QJsonDocument doc(*obj);
|
||||
QByteArray bytes = doc.toJson();
|
||||
delete obj;
|
||||
return QString(bytes);
|
||||
}
|
||||
|
||||
QJsonObject*
|
||||
SWGTraceData::asJsonObject() {
|
||||
QJsonObject* obj = new QJsonObject();
|
||||
if(m_projection_type_isSet){
|
||||
obj->insert("projectionType", QJsonValue(projection_type));
|
||||
}
|
||||
if(m_input_index_isSet){
|
||||
obj->insert("inputIndex", QJsonValue(input_index));
|
||||
}
|
||||
if(m_amp_isSet){
|
||||
obj->insert("amp", QJsonValue(amp));
|
||||
}
|
||||
if(m_amp_index_isSet){
|
||||
obj->insert("ampIndex", QJsonValue(amp_index));
|
||||
}
|
||||
if(m_ofs_isSet){
|
||||
obj->insert("ofs", QJsonValue(ofs));
|
||||
}
|
||||
if(m_ofs_coarse_isSet){
|
||||
obj->insert("ofsCoarse", QJsonValue(ofs_coarse));
|
||||
}
|
||||
if(m_ofs_fine_isSet){
|
||||
obj->insert("ofsFine", QJsonValue(ofs_fine));
|
||||
}
|
||||
if(m_trace_delay_isSet){
|
||||
obj->insert("traceDelay", QJsonValue(trace_delay));
|
||||
}
|
||||
if(m_trace_delay_coarse_isSet){
|
||||
obj->insert("traceDelayCoarse", QJsonValue(trace_delay_coarse));
|
||||
}
|
||||
if(m_trace_delay_fine_isSet){
|
||||
obj->insert("traceDelayFine", QJsonValue(trace_delay_fine));
|
||||
}
|
||||
if(m_trigger_display_level_isSet){
|
||||
obj->insert("triggerDisplayLevel", QJsonValue(trigger_display_level));
|
||||
}
|
||||
if(m_trace_color_isSet){
|
||||
obj->insert("traceColor", QJsonValue(trace_color));
|
||||
}
|
||||
if(m_trace_color_r_isSet){
|
||||
obj->insert("traceColorR", QJsonValue(trace_color_r));
|
||||
}
|
||||
if(m_trace_color_g_isSet){
|
||||
obj->insert("traceColorG", QJsonValue(trace_color_g));
|
||||
}
|
||||
if(m_trace_color_b_isSet){
|
||||
obj->insert("traceColorB", QJsonValue(trace_color_b));
|
||||
}
|
||||
if(m_has_text_overlay_isSet){
|
||||
obj->insert("hasTextOverlay", QJsonValue(has_text_overlay));
|
||||
}
|
||||
if(text_overlay != nullptr && *text_overlay != QString("")){
|
||||
toJsonValue(QString("textOverlay"), text_overlay, obj, QString("QString"));
|
||||
}
|
||||
if(m_view_trace_isSet){
|
||||
obj->insert("viewTrace", QJsonValue(view_trace));
|
||||
}
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getProjectionType() {
|
||||
return projection_type;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setProjectionType(qint32 projection_type) {
|
||||
this->projection_type = projection_type;
|
||||
this->m_projection_type_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getInputIndex() {
|
||||
return input_index;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setInputIndex(qint32 input_index) {
|
||||
this->input_index = input_index;
|
||||
this->m_input_index_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTraceData::getAmp() {
|
||||
return amp;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setAmp(float amp) {
|
||||
this->amp = amp;
|
||||
this->m_amp_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getAmpIndex() {
|
||||
return amp_index;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setAmpIndex(qint32 amp_index) {
|
||||
this->amp_index = amp_index;
|
||||
this->m_amp_index_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTraceData::getOfs() {
|
||||
return ofs;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setOfs(float ofs) {
|
||||
this->ofs = ofs;
|
||||
this->m_ofs_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getOfsCoarse() {
|
||||
return ofs_coarse;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setOfsCoarse(qint32 ofs_coarse) {
|
||||
this->ofs_coarse = ofs_coarse;
|
||||
this->m_ofs_coarse_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getOfsFine() {
|
||||
return ofs_fine;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setOfsFine(qint32 ofs_fine) {
|
||||
this->ofs_fine = ofs_fine;
|
||||
this->m_ofs_fine_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getTraceDelay() {
|
||||
return trace_delay;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceDelay(qint32 trace_delay) {
|
||||
this->trace_delay = trace_delay;
|
||||
this->m_trace_delay_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getTraceDelayCoarse() {
|
||||
return trace_delay_coarse;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceDelayCoarse(qint32 trace_delay_coarse) {
|
||||
this->trace_delay_coarse = trace_delay_coarse;
|
||||
this->m_trace_delay_coarse_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getTraceDelayFine() {
|
||||
return trace_delay_fine;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceDelayFine(qint32 trace_delay_fine) {
|
||||
this->trace_delay_fine = trace_delay_fine;
|
||||
this->m_trace_delay_fine_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTraceData::getTriggerDisplayLevel() {
|
||||
return trigger_display_level;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTriggerDisplayLevel(float trigger_display_level) {
|
||||
this->trigger_display_level = trigger_display_level;
|
||||
this->m_trigger_display_level_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getTraceColor() {
|
||||
return trace_color;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceColor(qint32 trace_color) {
|
||||
this->trace_color = trace_color;
|
||||
this->m_trace_color_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTraceData::getTraceColorR() {
|
||||
return trace_color_r;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceColorR(float trace_color_r) {
|
||||
this->trace_color_r = trace_color_r;
|
||||
this->m_trace_color_r_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTraceData::getTraceColorG() {
|
||||
return trace_color_g;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceColorG(float trace_color_g) {
|
||||
this->trace_color_g = trace_color_g;
|
||||
this->m_trace_color_g_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTraceData::getTraceColorB() {
|
||||
return trace_color_b;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTraceColorB(float trace_color_b) {
|
||||
this->trace_color_b = trace_color_b;
|
||||
this->m_trace_color_b_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getHasTextOverlay() {
|
||||
return has_text_overlay;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setHasTextOverlay(qint32 has_text_overlay) {
|
||||
this->has_text_overlay = has_text_overlay;
|
||||
this->m_has_text_overlay_isSet = true;
|
||||
}
|
||||
|
||||
QString*
|
||||
SWGTraceData::getTextOverlay() {
|
||||
return text_overlay;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setTextOverlay(QString* text_overlay) {
|
||||
this->text_overlay = text_overlay;
|
||||
this->m_text_overlay_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTraceData::getViewTrace() {
|
||||
return view_trace;
|
||||
}
|
||||
void
|
||||
SWGTraceData::setViewTrace(qint32 view_trace) {
|
||||
this->view_trace = view_trace;
|
||||
this->m_view_trace_isSet = true;
|
||||
}
|
||||
|
||||
|
||||
bool
|
||||
SWGTraceData::isSet(){
|
||||
bool isObjectUpdated = false;
|
||||
do{
|
||||
if(m_projection_type_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_input_index_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_amp_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_amp_index_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_ofs_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_ofs_coarse_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_ofs_fine_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_delay_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_delay_coarse_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_delay_fine_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_display_level_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_color_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_color_r_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_color_g_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trace_color_b_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_has_text_overlay_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(text_overlay && *text_overlay != QString("")){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_view_trace_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
}while(false);
|
||||
return isObjectUpdated;
|
||||
}
|
||||
}
|
||||
|
161
swagger/sdrangel/code/qt5/client/SWGTraceData.h
Normal file
161
swagger/sdrangel/code/qt5/client/SWGTraceData.h
Normal file
@ -0,0 +1,161 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
/*
|
||||
* SWGTraceData.h
|
||||
*
|
||||
* see GLScopeSettings::TraceData
|
||||
*/
|
||||
|
||||
#ifndef SWGTraceData_H_
|
||||
#define SWGTraceData_H_
|
||||
|
||||
#include <QJsonObject>
|
||||
|
||||
|
||||
#include <QString>
|
||||
|
||||
#include "SWGObject.h"
|
||||
#include "export.h"
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
class SWG_API SWGTraceData: public SWGObject {
|
||||
public:
|
||||
SWGTraceData();
|
||||
SWGTraceData(QString* json);
|
||||
virtual ~SWGTraceData();
|
||||
void init();
|
||||
void cleanup();
|
||||
|
||||
virtual QString asJson () override;
|
||||
virtual QJsonObject* asJsonObject() override;
|
||||
virtual void fromJsonObject(QJsonObject &json) override;
|
||||
virtual SWGTraceData* fromJson(QString &jsonString) override;
|
||||
|
||||
qint32 getProjectionType();
|
||||
void setProjectionType(qint32 projection_type);
|
||||
|
||||
qint32 getInputIndex();
|
||||
void setInputIndex(qint32 input_index);
|
||||
|
||||
float getAmp();
|
||||
void setAmp(float amp);
|
||||
|
||||
qint32 getAmpIndex();
|
||||
void setAmpIndex(qint32 amp_index);
|
||||
|
||||
float getOfs();
|
||||
void setOfs(float ofs);
|
||||
|
||||
qint32 getOfsCoarse();
|
||||
void setOfsCoarse(qint32 ofs_coarse);
|
||||
|
||||
qint32 getOfsFine();
|
||||
void setOfsFine(qint32 ofs_fine);
|
||||
|
||||
qint32 getTraceDelay();
|
||||
void setTraceDelay(qint32 trace_delay);
|
||||
|
||||
qint32 getTraceDelayCoarse();
|
||||
void setTraceDelayCoarse(qint32 trace_delay_coarse);
|
||||
|
||||
qint32 getTraceDelayFine();
|
||||
void setTraceDelayFine(qint32 trace_delay_fine);
|
||||
|
||||
float getTriggerDisplayLevel();
|
||||
void setTriggerDisplayLevel(float trigger_display_level);
|
||||
|
||||
qint32 getTraceColor();
|
||||
void setTraceColor(qint32 trace_color);
|
||||
|
||||
float getTraceColorR();
|
||||
void setTraceColorR(float trace_color_r);
|
||||
|
||||
float getTraceColorG();
|
||||
void setTraceColorG(float trace_color_g);
|
||||
|
||||
float getTraceColorB();
|
||||
void setTraceColorB(float trace_color_b);
|
||||
|
||||
qint32 getHasTextOverlay();
|
||||
void setHasTextOverlay(qint32 has_text_overlay);
|
||||
|
||||
QString* getTextOverlay();
|
||||
void setTextOverlay(QString* text_overlay);
|
||||
|
||||
qint32 getViewTrace();
|
||||
void setViewTrace(qint32 view_trace);
|
||||
|
||||
|
||||
virtual bool isSet() override;
|
||||
|
||||
private:
|
||||
qint32 projection_type;
|
||||
bool m_projection_type_isSet;
|
||||
|
||||
qint32 input_index;
|
||||
bool m_input_index_isSet;
|
||||
|
||||
float amp;
|
||||
bool m_amp_isSet;
|
||||
|
||||
qint32 amp_index;
|
||||
bool m_amp_index_isSet;
|
||||
|
||||
float ofs;
|
||||
bool m_ofs_isSet;
|
||||
|
||||
qint32 ofs_coarse;
|
||||
bool m_ofs_coarse_isSet;
|
||||
|
||||
qint32 ofs_fine;
|
||||
bool m_ofs_fine_isSet;
|
||||
|
||||
qint32 trace_delay;
|
||||
bool m_trace_delay_isSet;
|
||||
|
||||
qint32 trace_delay_coarse;
|
||||
bool m_trace_delay_coarse_isSet;
|
||||
|
||||
qint32 trace_delay_fine;
|
||||
bool m_trace_delay_fine_isSet;
|
||||
|
||||
float trigger_display_level;
|
||||
bool m_trigger_display_level_isSet;
|
||||
|
||||
qint32 trace_color;
|
||||
bool m_trace_color_isSet;
|
||||
|
||||
float trace_color_r;
|
||||
bool m_trace_color_r_isSet;
|
||||
|
||||
float trace_color_g;
|
||||
bool m_trace_color_g_isSet;
|
||||
|
||||
float trace_color_b;
|
||||
bool m_trace_color_b_isSet;
|
||||
|
||||
qint32 has_text_overlay;
|
||||
bool m_has_text_overlay_isSet;
|
||||
|
||||
QString* text_overlay;
|
||||
bool m_text_overlay_isSet;
|
||||
|
||||
qint32 view_trace;
|
||||
bool m_view_trace_isSet;
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif /* SWGTraceData_H_ */
|
476
swagger/sdrangel/code/qt5/client/SWGTriggerData.cpp
Normal file
476
swagger/sdrangel/code/qt5/client/SWGTriggerData.cpp
Normal file
@ -0,0 +1,476 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
|
||||
#include "SWGTriggerData.h"
|
||||
|
||||
#include "SWGHelpers.h"
|
||||
|
||||
#include <QJsonDocument>
|
||||
#include <QJsonArray>
|
||||
#include <QObject>
|
||||
#include <QDebug>
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
SWGTriggerData::SWGTriggerData(QString* json) {
|
||||
init();
|
||||
this->fromJson(*json);
|
||||
}
|
||||
|
||||
SWGTriggerData::SWGTriggerData() {
|
||||
projection_type = 0;
|
||||
m_projection_type_isSet = false;
|
||||
input_index = 0;
|
||||
m_input_index_isSet = false;
|
||||
trigger_level = 0.0f;
|
||||
m_trigger_level_isSet = false;
|
||||
trigger_level_coarse = 0;
|
||||
m_trigger_level_coarse_isSet = false;
|
||||
trigger_level_fine = 0;
|
||||
m_trigger_level_fine_isSet = false;
|
||||
trigger_positive_edge = 0;
|
||||
m_trigger_positive_edge_isSet = false;
|
||||
trigger_both_edges = 0;
|
||||
m_trigger_both_edges_isSet = false;
|
||||
trigger_holdoff = 0;
|
||||
m_trigger_holdoff_isSet = false;
|
||||
trigger_delay = 0;
|
||||
m_trigger_delay_isSet = false;
|
||||
trigger_delay_mult = 0.0f;
|
||||
m_trigger_delay_mult_isSet = false;
|
||||
trigger_delay_coarse = 0;
|
||||
m_trigger_delay_coarse_isSet = false;
|
||||
trigger_delay_fine = 0;
|
||||
m_trigger_delay_fine_isSet = false;
|
||||
trigger_repeat = 0;
|
||||
m_trigger_repeat_isSet = false;
|
||||
trigger_color = 0;
|
||||
m_trigger_color_isSet = false;
|
||||
trigger_color_r = 0.0f;
|
||||
m_trigger_color_r_isSet = false;
|
||||
trigger_color_g = 0.0f;
|
||||
m_trigger_color_g_isSet = false;
|
||||
trigger_color_b = 0.0f;
|
||||
m_trigger_color_b_isSet = false;
|
||||
}
|
||||
|
||||
SWGTriggerData::~SWGTriggerData() {
|
||||
this->cleanup();
|
||||
}
|
||||
|
||||
void
|
||||
SWGTriggerData::init() {
|
||||
projection_type = 0;
|
||||
m_projection_type_isSet = false;
|
||||
input_index = 0;
|
||||
m_input_index_isSet = false;
|
||||
trigger_level = 0.0f;
|
||||
m_trigger_level_isSet = false;
|
||||
trigger_level_coarse = 0;
|
||||
m_trigger_level_coarse_isSet = false;
|
||||
trigger_level_fine = 0;
|
||||
m_trigger_level_fine_isSet = false;
|
||||
trigger_positive_edge = 0;
|
||||
m_trigger_positive_edge_isSet = false;
|
||||
trigger_both_edges = 0;
|
||||
m_trigger_both_edges_isSet = false;
|
||||
trigger_holdoff = 0;
|
||||
m_trigger_holdoff_isSet = false;
|
||||
trigger_delay = 0;
|
||||
m_trigger_delay_isSet = false;
|
||||
trigger_delay_mult = 0.0f;
|
||||
m_trigger_delay_mult_isSet = false;
|
||||
trigger_delay_coarse = 0;
|
||||
m_trigger_delay_coarse_isSet = false;
|
||||
trigger_delay_fine = 0;
|
||||
m_trigger_delay_fine_isSet = false;
|
||||
trigger_repeat = 0;
|
||||
m_trigger_repeat_isSet = false;
|
||||
trigger_color = 0;
|
||||
m_trigger_color_isSet = false;
|
||||
trigger_color_r = 0.0f;
|
||||
m_trigger_color_r_isSet = false;
|
||||
trigger_color_g = 0.0f;
|
||||
m_trigger_color_g_isSet = false;
|
||||
trigger_color_b = 0.0f;
|
||||
m_trigger_color_b_isSet = false;
|
||||
}
|
||||
|
||||
void
|
||||
SWGTriggerData::cleanup() {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
SWGTriggerData*
|
||||
SWGTriggerData::fromJson(QString &json) {
|
||||
QByteArray array (json.toStdString().c_str());
|
||||
QJsonDocument doc = QJsonDocument::fromJson(array);
|
||||
QJsonObject jsonObject = doc.object();
|
||||
this->fromJsonObject(jsonObject);
|
||||
return this;
|
||||
}
|
||||
|
||||
void
|
||||
SWGTriggerData::fromJsonObject(QJsonObject &pJson) {
|
||||
::SWGSDRangel::setValue(&projection_type, pJson["projectionType"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&input_index, pJson["inputIndex"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_level, pJson["triggerLevel"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_level_coarse, pJson["triggerLevelCoarse"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_level_fine, pJson["triggerLevelFine"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_positive_edge, pJson["triggerPositiveEdge"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_both_edges, pJson["triggerBothEdges"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_holdoff, pJson["triggerHoldoff"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_delay, pJson["triggerDelay"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_delay_mult, pJson["triggerDelayMult"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_delay_coarse, pJson["triggerDelayCoarse"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_delay_fine, pJson["triggerDelayFine"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_repeat, pJson["triggerRepeat"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_color, pJson["triggerColor"], "qint32", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_color_r, pJson["triggerColorR"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_color_g, pJson["triggerColorG"], "float", "");
|
||||
|
||||
::SWGSDRangel::setValue(&trigger_color_b, pJson["triggerColorB"], "float", "");
|
||||
|
||||
}
|
||||
|
||||
QString
|
||||
SWGTriggerData::asJson ()
|
||||
{
|
||||
QJsonObject* obj = this->asJsonObject();
|
||||
|
||||
QJsonDocument doc(*obj);
|
||||
QByteArray bytes = doc.toJson();
|
||||
delete obj;
|
||||
return QString(bytes);
|
||||
}
|
||||
|
||||
QJsonObject*
|
||||
SWGTriggerData::asJsonObject() {
|
||||
QJsonObject* obj = new QJsonObject();
|
||||
if(m_projection_type_isSet){
|
||||
obj->insert("projectionType", QJsonValue(projection_type));
|
||||
}
|
||||
if(m_input_index_isSet){
|
||||
obj->insert("inputIndex", QJsonValue(input_index));
|
||||
}
|
||||
if(m_trigger_level_isSet){
|
||||
obj->insert("triggerLevel", QJsonValue(trigger_level));
|
||||
}
|
||||
if(m_trigger_level_coarse_isSet){
|
||||
obj->insert("triggerLevelCoarse", QJsonValue(trigger_level_coarse));
|
||||
}
|
||||
if(m_trigger_level_fine_isSet){
|
||||
obj->insert("triggerLevelFine", QJsonValue(trigger_level_fine));
|
||||
}
|
||||
if(m_trigger_positive_edge_isSet){
|
||||
obj->insert("triggerPositiveEdge", QJsonValue(trigger_positive_edge));
|
||||
}
|
||||
if(m_trigger_both_edges_isSet){
|
||||
obj->insert("triggerBothEdges", QJsonValue(trigger_both_edges));
|
||||
}
|
||||
if(m_trigger_holdoff_isSet){
|
||||
obj->insert("triggerHoldoff", QJsonValue(trigger_holdoff));
|
||||
}
|
||||
if(m_trigger_delay_isSet){
|
||||
obj->insert("triggerDelay", QJsonValue(trigger_delay));
|
||||
}
|
||||
if(m_trigger_delay_mult_isSet){
|
||||
obj->insert("triggerDelayMult", QJsonValue(trigger_delay_mult));
|
||||
}
|
||||
if(m_trigger_delay_coarse_isSet){
|
||||
obj->insert("triggerDelayCoarse", QJsonValue(trigger_delay_coarse));
|
||||
}
|
||||
if(m_trigger_delay_fine_isSet){
|
||||
obj->insert("triggerDelayFine", QJsonValue(trigger_delay_fine));
|
||||
}
|
||||
if(m_trigger_repeat_isSet){
|
||||
obj->insert("triggerRepeat", QJsonValue(trigger_repeat));
|
||||
}
|
||||
if(m_trigger_color_isSet){
|
||||
obj->insert("triggerColor", QJsonValue(trigger_color));
|
||||
}
|
||||
if(m_trigger_color_r_isSet){
|
||||
obj->insert("triggerColorR", QJsonValue(trigger_color_r));
|
||||
}
|
||||
if(m_trigger_color_g_isSet){
|
||||
obj->insert("triggerColorG", QJsonValue(trigger_color_g));
|
||||
}
|
||||
if(m_trigger_color_b_isSet){
|
||||
obj->insert("triggerColorB", QJsonValue(trigger_color_b));
|
||||
}
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getProjectionType() {
|
||||
return projection_type;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setProjectionType(qint32 projection_type) {
|
||||
this->projection_type = projection_type;
|
||||
this->m_projection_type_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getInputIndex() {
|
||||
return input_index;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setInputIndex(qint32 input_index) {
|
||||
this->input_index = input_index;
|
||||
this->m_input_index_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTriggerData::getTriggerLevel() {
|
||||
return trigger_level;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerLevel(float trigger_level) {
|
||||
this->trigger_level = trigger_level;
|
||||
this->m_trigger_level_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerLevelCoarse() {
|
||||
return trigger_level_coarse;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerLevelCoarse(qint32 trigger_level_coarse) {
|
||||
this->trigger_level_coarse = trigger_level_coarse;
|
||||
this->m_trigger_level_coarse_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerLevelFine() {
|
||||
return trigger_level_fine;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerLevelFine(qint32 trigger_level_fine) {
|
||||
this->trigger_level_fine = trigger_level_fine;
|
||||
this->m_trigger_level_fine_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerPositiveEdge() {
|
||||
return trigger_positive_edge;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerPositiveEdge(qint32 trigger_positive_edge) {
|
||||
this->trigger_positive_edge = trigger_positive_edge;
|
||||
this->m_trigger_positive_edge_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerBothEdges() {
|
||||
return trigger_both_edges;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerBothEdges(qint32 trigger_both_edges) {
|
||||
this->trigger_both_edges = trigger_both_edges;
|
||||
this->m_trigger_both_edges_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerHoldoff() {
|
||||
return trigger_holdoff;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerHoldoff(qint32 trigger_holdoff) {
|
||||
this->trigger_holdoff = trigger_holdoff;
|
||||
this->m_trigger_holdoff_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerDelay() {
|
||||
return trigger_delay;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerDelay(qint32 trigger_delay) {
|
||||
this->trigger_delay = trigger_delay;
|
||||
this->m_trigger_delay_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTriggerData::getTriggerDelayMult() {
|
||||
return trigger_delay_mult;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerDelayMult(float trigger_delay_mult) {
|
||||
this->trigger_delay_mult = trigger_delay_mult;
|
||||
this->m_trigger_delay_mult_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerDelayCoarse() {
|
||||
return trigger_delay_coarse;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerDelayCoarse(qint32 trigger_delay_coarse) {
|
||||
this->trigger_delay_coarse = trigger_delay_coarse;
|
||||
this->m_trigger_delay_coarse_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerDelayFine() {
|
||||
return trigger_delay_fine;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerDelayFine(qint32 trigger_delay_fine) {
|
||||
this->trigger_delay_fine = trigger_delay_fine;
|
||||
this->m_trigger_delay_fine_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerRepeat() {
|
||||
return trigger_repeat;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerRepeat(qint32 trigger_repeat) {
|
||||
this->trigger_repeat = trigger_repeat;
|
||||
this->m_trigger_repeat_isSet = true;
|
||||
}
|
||||
|
||||
qint32
|
||||
SWGTriggerData::getTriggerColor() {
|
||||
return trigger_color;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerColor(qint32 trigger_color) {
|
||||
this->trigger_color = trigger_color;
|
||||
this->m_trigger_color_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTriggerData::getTriggerColorR() {
|
||||
return trigger_color_r;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerColorR(float trigger_color_r) {
|
||||
this->trigger_color_r = trigger_color_r;
|
||||
this->m_trigger_color_r_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTriggerData::getTriggerColorG() {
|
||||
return trigger_color_g;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerColorG(float trigger_color_g) {
|
||||
this->trigger_color_g = trigger_color_g;
|
||||
this->m_trigger_color_g_isSet = true;
|
||||
}
|
||||
|
||||
float
|
||||
SWGTriggerData::getTriggerColorB() {
|
||||
return trigger_color_b;
|
||||
}
|
||||
void
|
||||
SWGTriggerData::setTriggerColorB(float trigger_color_b) {
|
||||
this->trigger_color_b = trigger_color_b;
|
||||
this->m_trigger_color_b_isSet = true;
|
||||
}
|
||||
|
||||
|
||||
bool
|
||||
SWGTriggerData::isSet(){
|
||||
bool isObjectUpdated = false;
|
||||
do{
|
||||
if(m_projection_type_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_input_index_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_level_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_level_coarse_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_level_fine_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_positive_edge_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_both_edges_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_holdoff_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_delay_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_delay_mult_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_delay_coarse_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_delay_fine_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_repeat_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_color_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_color_r_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_color_g_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
if(m_trigger_color_b_isSet){
|
||||
isObjectUpdated = true; break;
|
||||
}
|
||||
}while(false);
|
||||
return isObjectUpdated;
|
||||
}
|
||||
}
|
||||
|
154
swagger/sdrangel/code/qt5/client/SWGTriggerData.h
Normal file
154
swagger/sdrangel/code/qt5/client/SWGTriggerData.h
Normal file
@ -0,0 +1,154 @@
|
||||
/**
|
||||
* SDRangel
|
||||
* This is the web REST/JSON API of SDRangel SDR software. SDRangel is an Open Source Qt5/OpenGL 3.0+ (4.3+ in Windows) GUI and server Software Defined Radio and signal analyzer in software. It supports Airspy, BladeRF, HackRF, LimeSDR, PlutoSDR, RTL-SDR, SDRplay RSP1 and FunCube --- Limitations and specifcities: * In SDRangel GUI the first Rx device set cannot be deleted. Conversely the server starts with no device sets and its number of device sets can be reduced to zero by as many calls as necessary to /sdrangel/deviceset with DELETE method. * Preset import and export from/to file is a server only feature. * Device set focus is a GUI only feature. * The following channels are not implemented (status 501 is returned): ATV and DATV demodulators, Channel Analyzer NG, LoRa demodulator * The device settings and report structures contains only the sub-structure corresponding to the device type. The DeviceSettings and DeviceReport structures documented here shows all of them but only one will be or should be present at a time * The channel settings and report structures contains only the sub-structure corresponding to the channel type. The ChannelSettings and ChannelReport structures documented here shows all of them but only one will be or should be present at a time ---
|
||||
*
|
||||
* OpenAPI spec version: 4.11.6
|
||||
* Contact: f4exb06@gmail.com
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*/
|
||||
|
||||
/*
|
||||
* SWGTriggerData.h
|
||||
*
|
||||
* see GLScopeSettings::TriggerData
|
||||
*/
|
||||
|
||||
#ifndef SWGTriggerData_H_
|
||||
#define SWGTriggerData_H_
|
||||
|
||||
#include <QJsonObject>
|
||||
|
||||
|
||||
|
||||
#include "SWGObject.h"
|
||||
#include "export.h"
|
||||
|
||||
namespace SWGSDRangel {
|
||||
|
||||
class SWG_API SWGTriggerData: public SWGObject {
|
||||
public:
|
||||
SWGTriggerData();
|
||||
SWGTriggerData(QString* json);
|
||||
virtual ~SWGTriggerData();
|
||||
void init();
|
||||
void cleanup();
|
||||
|
||||
virtual QString asJson () override;
|
||||
virtual QJsonObject* asJsonObject() override;
|
||||
virtual void fromJsonObject(QJsonObject &json) override;
|
||||
virtual SWGTriggerData* fromJson(QString &jsonString) override;
|
||||
|
||||
qint32 getProjectionType();
|
||||
void setProjectionType(qint32 projection_type);
|
||||
|
||||
qint32 getInputIndex();
|
||||
void setInputIndex(qint32 input_index);
|
||||
|
||||
float getTriggerLevel();
|
||||
void setTriggerLevel(float trigger_level);
|
||||
|
||||
qint32 getTriggerLevelCoarse();
|
||||
void setTriggerLevelCoarse(qint32 trigger_level_coarse);
|
||||
|
||||
qint32 getTriggerLevelFine();
|
||||
void setTriggerLevelFine(qint32 trigger_level_fine);
|
||||
|
||||
qint32 getTriggerPositiveEdge();
|
||||
void setTriggerPositiveEdge(qint32 trigger_positive_edge);
|
||||
|
||||
qint32 getTriggerBothEdges();
|
||||
void setTriggerBothEdges(qint32 trigger_both_edges);
|
||||
|
||||
qint32 getTriggerHoldoff();
|
||||
void setTriggerHoldoff(qint32 trigger_holdoff);
|
||||
|
||||
qint32 getTriggerDelay();
|
||||
void setTriggerDelay(qint32 trigger_delay);
|
||||
|
||||
float getTriggerDelayMult();
|
||||
void setTriggerDelayMult(float trigger_delay_mult);
|
||||
|
||||
qint32 getTriggerDelayCoarse();
|
||||
void setTriggerDelayCoarse(qint32 trigger_delay_coarse);
|
||||
|
||||
qint32 getTriggerDelayFine();
|
||||
void setTriggerDelayFine(qint32 trigger_delay_fine);
|
||||
|
||||
qint32 getTriggerRepeat();
|
||||
void setTriggerRepeat(qint32 trigger_repeat);
|
||||
|
||||
qint32 getTriggerColor();
|
||||
void setTriggerColor(qint32 trigger_color);
|
||||
|
||||
float getTriggerColorR();
|
||||
void setTriggerColorR(float trigger_color_r);
|
||||
|
||||
float getTriggerColorG();
|
||||
void setTriggerColorG(float trigger_color_g);
|
||||
|
||||
float getTriggerColorB();
|
||||
void setTriggerColorB(float trigger_color_b);
|
||||
|
||||
|
||||
virtual bool isSet() override;
|
||||
|
||||
private:
|
||||
qint32 projection_type;
|
||||
bool m_projection_type_isSet;
|
||||
|
||||
qint32 input_index;
|
||||
bool m_input_index_isSet;
|
||||
|
||||
float trigger_level;
|
||||
bool m_trigger_level_isSet;
|
||||
|
||||
qint32 trigger_level_coarse;
|
||||
bool m_trigger_level_coarse_isSet;
|
||||
|
||||
qint32 trigger_level_fine;
|
||||
bool m_trigger_level_fine_isSet;
|
||||
|
||||
qint32 trigger_positive_edge;
|
||||
bool m_trigger_positive_edge_isSet;
|
||||
|
||||
qint32 trigger_both_edges;
|
||||
bool m_trigger_both_edges_isSet;
|
||||
|
||||
qint32 trigger_holdoff;
|
||||
bool m_trigger_holdoff_isSet;
|
||||
|
||||
qint32 trigger_delay;
|
||||
bool m_trigger_delay_isSet;
|
||||
|
||||
float trigger_delay_mult;
|
||||
bool m_trigger_delay_mult_isSet;
|
||||
|
||||
qint32 trigger_delay_coarse;
|
||||
bool m_trigger_delay_coarse_isSet;
|
||||
|
||||
qint32 trigger_delay_fine;
|
||||
bool m_trigger_delay_fine_isSet;
|
||||
|
||||
qint32 trigger_repeat;
|
||||
bool m_trigger_repeat_isSet;
|
||||
|
||||
qint32 trigger_color;
|
||||
bool m_trigger_color_isSet;
|
||||
|
||||
float trigger_color_r;
|
||||
bool m_trigger_color_r_isSet;
|
||||
|
||||
float trigger_color_g;
|
||||
bool m_trigger_color_g_isSet;
|
||||
|
||||
float trigger_color_b;
|
||||
bool m_trigger_color_b_isSet;
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif /* SWGTriggerData_H_ */
|
Loading…
Reference in New Issue
Block a user