SDRAngel  4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
Classes | Public Member Functions | Private Slots | Private Member Functions | Private Attributes | List of all members
FCDProInput Class Reference

#include <fcdproinput.h>

+ Inheritance diagram for FCDProInput:
+ Collaboration diagram for FCDProInput:

Classes

class  MsgConfigureFCDPro
 
class  MsgFileRecord
 
class  MsgStartStop
 

Public Member Functions

 FCDProInput (DeviceAPI *deviceAPI)
 
virtual ~FCDProInput ()
 
virtual void destroy ()
 
virtual void init ()
 initializations to be done when all collaborating objects are created and possibly connected More...
 
virtual bool start ()
 
virtual void stop ()
 
virtual QByteArray serialize () const
 
virtual bool deserialize (const QByteArray &data)
 
virtual void setMessageQueueToGUI (MessageQueue *queue)
 
virtual const QString & getDeviceDescription () const
 
virtual int getSampleRate () const
 Sample rate exposed by the source. More...
 
virtual void setSampleRate (int sampleRate)
 For when the source sample rate is set externally. More...
 
virtual quint64 getCenterFrequency () const
 Center frequency exposed by the source. More...
 
virtual void setCenterFrequency (qint64 centerFrequency)
 
virtual bool handleMessage (const Message &message)
 
virtual int webapiSettingsGet (SWGSDRangel::SWGDeviceSettings &response, QString &errorMessage)
 
virtual int webapiSettingsPutPatch (bool force, const QStringList &deviceSettingsKeys, SWGSDRangel::SWGDeviceSettings &response, QString &errorMessage)
 
virtual int webapiRunGet (SWGSDRangel::SWGDeviceState &response, QString &errorMessage)
 
virtual int webapiRun (bool run, SWGSDRangel::SWGDeviceState &response, QString &errorMessage)
 
void set_center_freq (double freq)
 
void set_bias_t (bool on)
 
void set_lnaGain (int index)
 
void set_rfFilter (int index)
 
void set_lnaEnhance (int index)
 
void set_band (int index)
 
void set_mixerGain (int index)
 
void set_mixerFilter (int index)
 
void set_biasCurrent (int index)
 
void set_mode (int index)
 
void set_gain1 (int index)
 
void set_rcFilter (int index)
 
void set_gain2 (int index)
 
void set_gain3 (int index)
 
void set_gain4 (int index)
 
void set_ifFilter (int index)
 
void set_gain5 (int index)
 
void set_gain6 (int index)
 
- Public Member Functions inherited from DeviceSampleSource
 DeviceSampleSource ()
 
virtual ~DeviceSampleSource ()
 
virtual int webapiReportGet (SWGSDRangel::SWGDeviceReport &response, QString &errorMessage)
 
MessageQueuegetInputMessageQueue ()
 
MessageQueuegetMessageQueueToGUI ()
 
SampleSinkFifogetSampleFifo ()
 

Private Slots

void networkManagerFinished (QNetworkReply *reply)
 

Private Member Functions

bool openDevice ()
 
void closeDevice ()
 
bool openFCDAudio (const char *filename)
 
void closeFCDAudio ()
 
void applySettings (const FCDProSettings &settings, bool force)
 
void webapiFormatDeviceSettings (SWGSDRangel::SWGDeviceSettings &response, const FCDProSettings &settings)
 
void webapiReverseSendSettings (QList< QString > &deviceSettingsKeys, const FCDProSettings &settings, bool force)
 
void webapiReverseSendStartStop (bool start)
 

Private Attributes

DeviceAPIm_deviceAPI
 
hid_devicem_dev
 
AudioInput m_fcdAudioInput
 
AudioFifo m_fcdFIFO
 
QMutex m_mutex
 
FCDProSettings m_settings
 
FCDProThreadm_FCDThread
 
QString m_deviceDescription
 
bool m_running
 
FileRecordm_fileSink
 File sink to record device I/Q output. More...
 
QNetworkAccessManager * m_networkManager
 
QNetworkRequest m_networkRequest
 

Additional Inherited Members

- Public Types inherited from DeviceSampleSource
enum  fcPos_t { FC_POS_INFRA = 0, FC_POS_SUPRA, FC_POS_CENTER }
 
enum  FrequencyShiftScheme { FSHIFT_STD = 0, FSHIFT_TXSYNC }
 
- Static Public Member Functions inherited from DeviceSampleSource
static qint64 calculateDeviceCenterFrequency (quint64 centerFrequency, qint64 transverterDeltaFrequency, int log2Decim, fcPos_t fcPos, quint32 devSampleRate, FrequencyShiftScheme frequencyShiftScheme, bool transverterMode=false)
 
static qint64 calculateCenterFrequency (quint64 deviceCenterFrequency, qint64 transverterDeltaFrequency, int log2Decim, fcPos_t fcPos, quint32 devSampleRate, FrequencyShiftScheme frequencyShiftScheme, bool transverterMode=false)
 
static qint32 calculateFrequencyShift (int log2Decim, fcPos_t fcPos, quint32 devSampleRate, FrequencyShiftScheme frequencyShiftScheme)
 
- Protected Slots inherited from DeviceSampleSource
void handleInputMessages ()
 
- Protected Attributes inherited from DeviceSampleSource
SampleSinkFifo m_sampleFifo
 
MessageQueue m_inputMessageQueue
 Input queue to the source. More...
 
MessageQueuem_guiMessageQueue
 Input message queue to the GUI. More...
 

Detailed Description

Definition at line 45 of file fcdproinput.h.

Constructor & Destructor Documentation

◆ FCDProInput()

FCDProInput::FCDProInput ( DeviceAPI deviceAPI)

Definition at line 42 of file fcdproinput.cpp.

References arg().

42  :
43  m_deviceAPI(deviceAPI),
44  m_dev(0),
45  m_settings(),
46  m_FCDThread(0),
48  m_running(false)
49 {
51  openDevice();
52  m_fileSink = new FileRecord(QString("test_%1.sdriq").arg(m_deviceAPI->getDeviceUID()));
55  m_networkManager = new QNetworkAccessManager();
56  connect(m_networkManager, SIGNAL(finished(QNetworkReply*)), this, SLOT(networkManagerFinished(QNetworkReply*)));
57 }
QNetworkAccessManager * m_networkManager
Definition: fcdproinput.h:178
uint getDeviceUID() const
Return the current device engine unique ID.
Definition: deviceapi.cpp:303
void setNbSourceStreams(uint32_t nbSourceStreams)
Definition: deviceapi.h:168
FileRecord * m_fileSink
File sink to record device I/Q output.
Definition: fcdproinput.h:177
void networkManagerFinished(QNetworkReply *reply)
AudioFifo m_fcdFIFO
Definition: fcdproinput.h:171
bool m_running
Definition: fcdproinput.h:176
FCDProSettings m_settings
Definition: fcdproinput.h:173
Fixed< IntType, IntBits > arg(const std::complex< Fixed< IntType, IntBits > > &val)
Definition: fixed.h:2401
void addAncillarySink(BasebandSampleSink *sink, unsigned int index=0)
Adds a sink to receive full baseband and that is not a channel (e.g. spectrum)
Definition: deviceapi.cpp:89
hid_device * m_dev
Definition: fcdproinput.h:169
QString m_deviceDescription
Definition: fcdproinput.h:175
bool setSize(uint32_t numSamples)
Definition: audiofifo.cpp:59
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
bool openDevice()
Definition: fcdproinput.cpp:79
FCDProThread * m_FCDThread
Definition: fcdproinput.h:174
+ Here is the call graph for this function:

◆ ~FCDProInput()

FCDProInput::~FCDProInput ( )
virtual

Definition at line 59 of file fcdproinput.cpp.

References closeDevice(), m_deviceAPI, m_fileSink, m_networkManager, m_running, networkManagerFinished(), DeviceAPI::removeAncillarySink(), and stop().

60 {
61  disconnect(m_networkManager, SIGNAL(finished(QNetworkReply*)), this, SLOT(networkManagerFinished(QNetworkReply*)));
62  delete m_networkManager;
63 
64  if (m_running) {
65  stop();
66  }
67 
69  delete m_fileSink;
70 
71  closeDevice();
72 }
virtual void stop()
QNetworkAccessManager * m_networkManager
Definition: fcdproinput.h:178
FileRecord * m_fileSink
File sink to record device I/Q output.
Definition: fcdproinput.h:177
void networkManagerFinished(QNetworkReply *reply)
bool m_running
Definition: fcdproinput.h:176
void closeDevice()
void removeAncillarySink(BasebandSampleSink *sink, unsigned int index=0)
Removes it.
Definition: deviceapi.cpp:100
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
+ Here is the call graph for this function:

Member Function Documentation

◆ applySettings()

void FCDProInput::applySettings ( const FCDProSettings settings,
bool  force 
)
private

Definition at line 323 of file fcdproinput.cpp.

References DeviceSampleSource::calculateDeviceCenterFrequency(), DeviceAPI::configureCorrections(), DeviceAPI::getDeviceEngineInputMessageQueue(), FileRecord::handleMessage(), FCDProSettings::m_bandIndex, FCDProSettings::m_biasCurrentIndex, FCDProSettings::m_centerFrequency, FCDProSettings::m_dcBlock, m_dev, m_deviceAPI, m_FCDThread, FCDProSettings::m_fcPos, m_fileSink, FCDProSettings::m_gain1Index, FCDProSettings::m_gain2Index, FCDProSettings::m_gain3Index, FCDProSettings::m_gain4Index, FCDProSettings::m_gain5Index, FCDProSettings::m_gain6Index, FCDProSettings::m_ifFilterIndex, FCDProSettings::m_iqCorrection, FCDProSettings::m_lnaEnhanceIndex, FCDProSettings::m_lnaGainIndex, FCDProSettings::m_log2Decim, FCDProSettings::m_LOppmTenths, FCDProSettings::m_mixerFilterIndex, FCDProSettings::m_mixerGainIndex, FCDProSettings::m_modeIndex, FCDProSettings::m_rcFilterIndex, FCDProSettings::m_reverseAPIAddress, FCDProSettings::m_reverseAPIDeviceIndex, FCDProSettings::m_reverseAPIPort, FCDProSettings::m_rfFilterIndex, m_settings, FCDProSettings::m_transverterDeltaFrequency, FCDProSettings::m_transverterMode, FCDProSettings::m_useReverseAPI, MessageQueue::push(), set_band(), set_biasCurrent(), set_center_freq(), set_gain1(), set_gain2(), set_gain3(), set_gain4(), set_gain5(), set_gain6(), set_ifFilter(), set_lnaEnhance(), set_lnaGain(), set_mixerFilter(), set_mixerGain(), set_mode(), set_rcFilter(), set_rfFilter(), FCDProThread::setFcPos(), FCDProThread::setLog2Decimation(), and webapiReverseSendSettings().

Referenced by handleMessage(), init(), and start().

324 {
325  bool forwardChange = false;
326  QList<QString> reverseAPIKeys;
327 
328  if (force || (m_settings.m_centerFrequency != settings.m_centerFrequency)) {
329  reverseAPIKeys.append("centerFrequency");
330  }
331  if (force || (m_settings.m_transverterMode != settings.m_transverterMode)) {
332  reverseAPIKeys.append("transverterMode");
333  }
335  reverseAPIKeys.append("transverterDeltaFrequency");
336  }
337  if ((m_settings.m_LOppmTenths != settings.m_LOppmTenths) || force) {
338  reverseAPIKeys.append("LOppmTenths");
339  }
340 
341  if (force || (m_settings.m_centerFrequency != settings.m_centerFrequency)
342  || (m_settings.m_LOppmTenths != settings.m_LOppmTenths)
343  || (m_settings.m_fcPos != settings.m_fcPos)
344  || (m_settings.m_log2Decim != settings.m_log2Decim)
347  {
348  qint64 deviceCenterFrequency = DeviceSampleSource::calculateDeviceCenterFrequency(
349  settings.m_centerFrequency,
351  settings.m_log2Decim,
354  DeviceSampleSource::FrequencyShiftScheme::FSHIFT_STD,
355  settings.m_transverterMode);
356 
357  if (m_dev != 0)
358  {
359  set_center_freq((double) deviceCenterFrequency);
360  }
361 
362  qDebug() << "FCDProInput::applySettings: center freq: " << settings.m_centerFrequency << " Hz"
363  << " device center freq: " << deviceCenterFrequency << " Hz";
364 
365  forwardChange = (m_settings.m_centerFrequency != settings.m_centerFrequency) || force;
366 
368  }
369 
370  if ((m_settings.m_log2Decim != settings.m_log2Decim) || force)
371  {
372  reverseAPIKeys.append("log2Decim");
373  forwardChange = true;
374 
375  if (m_FCDThread != 0)
376  {
378  qDebug() << "FCDProInput::applySettings: set decimation to " << (1<<settings.m_log2Decim);
379  }
380  }
381 
382  if ((m_settings.m_fcPos != settings.m_fcPos) || force)
383  {
384  reverseAPIKeys.append("fcPos");
385 
386  if (m_FCDThread != 0) {
387  m_FCDThread->setFcPos((int) settings.m_fcPos);
388  }
389 
390  qDebug() << "FCDProInput::applySettings: set fc pos (enum) to " << (int) settings.m_fcPos;
391  }
392 
393  if ((m_settings.m_lnaGainIndex != settings.m_lnaGainIndex) || force)
394  {
395  reverseAPIKeys.append("lnaGainIndex");
396 
397  if (m_dev != 0) {
398  set_lnaGain(settings.m_lnaGainIndex);
399  }
400  }
401 
402  if ((m_settings.m_rfFilterIndex != settings.m_rfFilterIndex) || force)
403  {
404  reverseAPIKeys.append("rfFilterIndex");
405 
406  if (m_dev != 0) {
407  set_rfFilter(settings.m_rfFilterIndex);
408  }
409  }
410 
411  if ((m_settings.m_lnaEnhanceIndex != settings.m_lnaEnhanceIndex) || force)
412  {
413  reverseAPIKeys.append("lnaEnhanceIndex");
414 
415  if (m_dev != 0) {
417  }
418  }
419 
420  if ((m_settings.m_bandIndex != settings.m_bandIndex) || force)
421  {
422  reverseAPIKeys.append("bandIndex");
423 
424  if (m_dev != 0) {
425  set_band(settings.m_bandIndex);
426  }
427  }
428 
429  if ((m_settings.m_mixerGainIndex != settings.m_mixerGainIndex) || force)
430  {
431  reverseAPIKeys.append("mixerGainIndex");
432 
433  if (m_dev != 0) {
435  }
436  }
437 
438  if ((m_settings.m_mixerFilterIndex != settings.m_mixerFilterIndex) || force)
439  {
440  reverseAPIKeys.append("mixerFilterIndex");
441 
442  if (m_dev != 0) {
444  }
445  }
446 
447  if ((m_settings.m_biasCurrentIndex != settings.m_biasCurrentIndex) || force)
448  {
449  reverseAPIKeys.append("biasCurrentIndex");
450 
451  if (m_dev != 0) {
453  }
454  }
455 
456  if ((m_settings.m_modeIndex != settings.m_modeIndex) || force)
457  {
458  reverseAPIKeys.append("modeIndex");
459 
460  if (m_dev != 0) {
461  set_mode(settings.m_modeIndex);
462  }
463  }
464 
465  if ((m_settings.m_gain1Index != settings.m_gain1Index) || force)
466  {
467  reverseAPIKeys.append("gain1Index");
468 
469  if (m_dev != 0) {
470  set_gain1(settings.m_gain1Index);
471  }
472  }
473 
474  if ((m_settings.m_rcFilterIndex != settings.m_rcFilterIndex) || force)
475  {
476  reverseAPIKeys.append("rcFilterIndex");
477 
478  if (m_dev != 0) {
479  set_rcFilter(settings.m_rcFilterIndex);
480  }
481  }
482 
483  if ((m_settings.m_gain2Index != settings.m_gain2Index) || force)
484  {
485  reverseAPIKeys.append("gain2Index");
486 
487  if (m_dev != 0) {
488  set_gain2(settings.m_gain2Index);
489  }
490  }
491 
492  if ((m_settings.m_gain3Index != settings.m_gain3Index) || force)
493  {
494  reverseAPIKeys.append("gain3Index");
495 
496  if (m_dev != 0) {
497  set_gain3(settings.m_gain3Index);
498  }
499  }
500 
501  if ((m_settings.m_gain4Index != settings.m_gain4Index) || force)
502  {
503  reverseAPIKeys.append("gain4Index");
504 
505  if (m_dev != 0) {
506  set_gain4(settings.m_gain4Index);
507  }
508  }
509 
510  if ((m_settings.m_ifFilterIndex != settings.m_ifFilterIndex) || force)
511  {
512  reverseAPIKeys.append("ifFilterIndex");
513 
514  if (m_dev != 0) {
515  set_ifFilter(settings.m_ifFilterIndex);
516  }
517  }
518 
519  if ((m_settings.m_gain5Index != settings.m_gain5Index) || force)
520  {
521  reverseAPIKeys.append("gain5Index");
522 
523  if (m_dev != 0) {
524  set_gain5(settings.m_gain5Index);
525  }
526  }
527 
528  if ((m_settings.m_gain6Index != settings.m_gain6Index) || force)
529  {
530  reverseAPIKeys.append("gain6Index");
531 
532  if (m_dev != 0) {
533  set_gain6(settings.m_gain6Index);
534  }
535  }
536 
537  if ((m_settings.m_dcBlock != settings.m_dcBlock) || force)
538  {
539  reverseAPIKeys.append("dcBlock");
541  }
542 
543  if ((m_settings.m_iqCorrection != settings.m_iqCorrection) || force)
544  {
545  reverseAPIKeys.append("iqCorrection");
547  }
548 
549  if (settings.m_useReverseAPI)
550  {
551  bool fullUpdate = ((m_settings.m_useReverseAPI != settings.m_useReverseAPI) && settings.m_useReverseAPI) ||
555  webapiReverseSendSettings(reverseAPIKeys, settings, fullUpdate || force);
556  }
557 
558  m_settings = settings;
559 
560  if (forwardChange)
561  {
563  m_fileSink->handleMessage(*notif); // forward to file sink
565  }
566 }
void setLog2Decimation(unsigned int log2_decim)
uint16_t m_reverseAPIPort
void set_gain5(int index)
qint32 m_lnaEnhanceIndex
static qint64 calculateDeviceCenterFrequency(quint64 centerFrequency, qint64 transverterDeltaFrequency, int log2Decim, fcPos_t fcPos, quint32 devSampleRate, FrequencyShiftScheme frequencyShiftScheme, bool transverterMode=false)
void push(Message *message, bool emitSignal=true)
Push message onto queue.
void set_lnaEnhance(int index)
void set_rcFilter(int index)
FileRecord * m_fileSink
File sink to record device I/Q output.
Definition: fcdproinput.h:177
qint32 m_mixerGainIndex
void webapiReverseSendSettings(QList< QString > &deviceSettingsKeys, const FCDProSettings &settings, bool force)
MessageQueue * getDeviceEngineInputMessageQueue()
Device engine message queue.
Definition: deviceapi.cpp:316
void set_band(int index)
void set_gain4(int index)
quint32 m_log2Decim
qint32 m_lnaGainIndex
qint32 m_ifFilterIndex
FCDProSettings m_settings
Definition: fcdproinput.h:173
virtual bool handleMessage(const Message &message)
Processing of a message. Returns true if message has actually been processed.
Definition: filerecord.cpp:128
void set_gain6(int index)
qint64 m_transverterDeltaFrequency
void set_rfFilter(int index)
uint16_t m_reverseAPIDeviceIndex
void set_gain3(int index)
void set_gain2(int index)
void set_center_freq(double freq)
qint32 m_LOppmTenths
qint32 m_rfFilterIndex
qint32 m_mixerFilterIndex
void set_ifFilter(int index)
void setFcPos(int fcPos)
hid_device * m_dev
Definition: fcdproinput.h:169
void set_mixerGain(int index)
void set_mode(int index)
QString m_reverseAPIAddress
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
void set_mixerFilter(int index)
qint32 m_rcFilterIndex
FCDProThread * m_FCDThread
Definition: fcdproinput.h:174
void set_lnaGain(int index)
void set_gain1(int index)
void configureCorrections(bool dcOffsetCorrection, bool iqImbalanceCorrection, int streamIndex=0)
Configure current device engine DSP corrections (Rx)
Definition: deviceapi.cpp:355
quint64 m_centerFrequency
qint32 m_biasCurrentIndex
void set_biasCurrent(int index)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ closeDevice()

void FCDProInput::closeDevice ( )
private

Definition at line 150 of file fcdproinput.cpp.

References closeFCDAudio(), fcdClose(), and m_dev.

Referenced by openDevice(), and ~FCDProInput().

151 {
152  if (m_dev == 0) { // was never open
153  return;
154  }
155 
156  fcdClose(m_dev);
157  m_dev = 0;
158 
159  closeFCDAudio();
160 }
void closeFCDAudio()
void fcdClose(hid_device *phd)
Close FCD HID device.
Definition: fcdhid.c:78
hid_device * m_dev
Definition: fcdproinput.h:169
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ closeFCDAudio()

void FCDProInput::closeFCDAudio ( )
private

Definition at line 185 of file fcdproinput.cpp.

References m_fcdAudioInput, m_fcdFIFO, AudioInput::removeFifo(), and AudioInput::stop().

Referenced by closeDevice().

186 {
189 }
AudioInput m_fcdAudioInput
Definition: fcdproinput.h:170
AudioFifo m_fcdFIFO
Definition: fcdproinput.h:171
void removeFifo(AudioFifo *audioFifo)
Definition: audioinput.cpp:149
void stop()
Definition: audioinput.cpp:121
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ deserialize()

bool FCDProInput::deserialize ( const QByteArray &  data)
virtual

Implements DeviceSampleSource.

Definition at line 211 of file fcdproinput.cpp.

References FCDProInput::MsgConfigureFCDPro::create(), FCDProSettings::deserialize(), DeviceSampleSource::m_guiMessageQueue, DeviceSampleSource::m_inputMessageQueue, m_settings, MessageQueue::push(), and FCDProSettings::resetToDefaults().

212 {
213  bool success = true;
214 
215  if (!m_settings.deserialize(data))
216  {
218  success = false;
219  }
220 
221  MsgConfigureFCDPro* message = MsgConfigureFCDPro::create(m_settings, true);
222  m_inputMessageQueue.push(message);
223 
224  if (m_guiMessageQueue)
225  {
226  MsgConfigureFCDPro* messageToGUI = MsgConfigureFCDPro::create(m_settings, true);
227  m_guiMessageQueue->push(messageToGUI);
228  }
229 
230  return success;
231 }
void push(Message *message, bool emitSignal=true)
Push message onto queue.
MessageQueue m_inputMessageQueue
Input queue to the source.
FCDProSettings m_settings
Definition: fcdproinput.h:173
static MsgConfigureFCDPro * create(const FCDProSettings &settings, bool force)
Definition: fcdproinput.h:55
MessageQueue * m_guiMessageQueue
Input message queue to the GUI.
bool deserialize(const QByteArray &data)
+ Here is the call graph for this function:

◆ destroy()

void FCDProInput::destroy ( )
virtual

Implements DeviceSampleSource.

Definition at line 74 of file fcdproinput.cpp.

75 {
76  delete this;
77 }

◆ getCenterFrequency()

quint64 FCDProInput::getCenterFrequency ( ) const
virtual

Center frequency exposed by the source.

Implements DeviceSampleSource.

Definition at line 243 of file fcdproinput.cpp.

References FCDProSettings::m_centerFrequency, and m_settings.

244 {
246 }
FCDProSettings m_settings
Definition: fcdproinput.h:173
quint64 m_centerFrequency

◆ getDeviceDescription()

const QString & FCDProInput::getDeviceDescription ( ) const
virtual

Implements DeviceSampleSource.

Definition at line 233 of file fcdproinput.cpp.

References m_deviceDescription.

234 {
235  return m_deviceDescription;
236 }
QString m_deviceDescription
Definition: fcdproinput.h:175

◆ getSampleRate()

int FCDProInput::getSampleRate ( ) const
virtual

Sample rate exposed by the source.

Implements DeviceSampleSource.

Definition at line 238 of file fcdproinput.cpp.

References FCDProSettings::m_log2Decim, and m_settings.

239 {
241 }
quint32 m_log2Decim
FCDProSettings m_settings
Definition: fcdproinput.h:173

◆ handleMessage()

bool FCDProInput::handleMessage ( const Message message)
virtual

Implements DeviceSampleSource.

Definition at line 263 of file fcdproinput.cpp.

References applySettings(), FileRecord::genUniqueFileName(), DeviceAPI::getDeviceUID(), FCDProInput::MsgConfigureFCDPro::getForce(), FCDProInput::MsgConfigureFCDPro::getSettings(), FCDProInput::MsgFileRecord::getStartStop(), FCDProInput::MsgStartStop::getStartStop(), DeviceAPI::initDeviceEngine(), m_deviceAPI, FCDProSettings::m_fileRecordName, m_fileSink, m_settings, FCDProSettings::m_useReverseAPI, Message::match(), FileRecord::setFileName(), DeviceAPI::startDeviceEngine(), FileRecord::startRecording(), DeviceAPI::stopDeviceEngine(), FileRecord::stopRecording(), and webapiReverseSendStartStop().

264 {
265  if(MsgConfigureFCDPro::match(message))
266  {
267  qDebug() << "FCDProInput::handleMessage: MsgConfigureFCD";
268  MsgConfigureFCDPro& conf = (MsgConfigureFCDPro&) message;
269  applySettings(conf.getSettings(), conf.getForce());
270  return true;
271  }
272  else if (MsgStartStop::match(message))
273  {
274  MsgStartStop& cmd = (MsgStartStop&) message;
275  qDebug() << "FCDProInput::handleMessage: MsgStartStop: " << (cmd.getStartStop() ? "start" : "stop");
276 
277  if (cmd.getStartStop())
278  {
280  {
282  }
283  }
284  else
285  {
287  }
288 
290  webapiReverseSendStartStop(cmd.getStartStop());
291  }
292 
293  return true;
294  }
295  else if (MsgFileRecord::match(message))
296  {
297  MsgFileRecord& conf = (MsgFileRecord&) message;
298  qDebug() << "FCDProInput::handleMessage: MsgFileRecord: " << conf.getStartStop();
299 
300  if (conf.getStartStop())
301  {
302  if (m_settings.m_fileRecordName.size() != 0) {
304  } else {
306  }
307 
309  }
310  else
311  {
313  }
314 
315  return true;
316  }
317  else
318  {
319  return false;
320  }
321 }
bool startDeviceEngine()
Start the device engine corresponding to the stream type.
Definition: deviceapi.cpp:253
void stopDeviceEngine()
Stop the device engine corresponding to the stream type.
Definition: deviceapi.cpp:266
void setFileName(const QString &filename)
Definition: filerecord.cpp:59
uint getDeviceUID() const
Return the current device engine unique ID.
Definition: deviceapi.cpp:303
FileRecord * m_fileSink
File sink to record device I/Q output.
Definition: fcdproinput.h:177
void startRecording()
Definition: filerecord.cpp:105
void applySettings(const FCDProSettings &settings, bool force)
bool initDeviceEngine()
Init the device engine corresponding to the stream type.
Definition: deviceapi.cpp:240
FCDProSettings m_settings
Definition: fcdproinput.h:173
void genUniqueFileName(uint deviceUID, int istream=-1)
Definition: filerecord.cpp:67
void stopRecording()
Definition: filerecord.cpp:117
static bool match(const Message *message)
Definition: message.cpp:45
void webapiReverseSendStartStop(bool start)
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
QString m_fileRecordName
+ Here is the call graph for this function:

◆ init()

void FCDProInput::init ( )
virtual

initializations to be done when all collaborating objects are created and possibly connected

Implements DeviceSampleSource.

Definition at line 108 of file fcdproinput.cpp.

References applySettings(), and m_settings.

109 {
110  applySettings(m_settings, true);
111 }
void applySettings(const FCDProSettings &settings, bool force)
FCDProSettings m_settings
Definition: fcdproinput.h:173
+ Here is the call graph for this function:

◆ networkManagerFinished

void FCDProInput::networkManagerFinished ( QNetworkReply *  reply)
privateslot

Definition at line 1156 of file fcdproinput.cpp.

Referenced by ~FCDProInput().

1157 {
1158  QNetworkReply::NetworkError replyError = reply->error();
1159 
1160  if (replyError)
1161  {
1162  qWarning() << "FCDProInput::networkManagerFinished:"
1163  << " error(" << (int) replyError
1164  << "): " << replyError
1165  << ": " << reply->errorString();
1166  return;
1167  }
1168 
1169  QString answer = reply->readAll();
1170  answer.chop(1); // remove last \n
1171  qDebug("FCDProInput::networkManagerFinished: reply:\n%s", answer.toStdString().c_str());
1172 }
+ Here is the caller graph for this function:

◆ openDevice()

bool FCDProInput::openDevice ( )
private

Definition at line 79 of file fcdproinput.cpp.

References closeDevice(), fcdOpen(), DeviceAPI::getSamplingDeviceSequence(), m_dev, m_deviceAPI, and openFCDAudio().

80 {
81  if (m_dev != 0) {
82  closeDevice();
83  }
84 
85  int device = m_deviceAPI->getSamplingDeviceSequence();
86  qDebug() << "FCDProInput::openDevice with device #" << device;
88 
89  if (m_dev == 0)
90  {
91  qCritical("FCDProInput::start: could not open FCD");
92  return false;
93  }
94 
96  {
97  qCritical("FCDProInput::start: could not open FCD audio source");
98  return false;
99  }
100  else
101  {
102  qDebug("FCDProInput::start: FCD audio source opened");
103  }
104 
105  return true;
106 }
hid_device * fcdOpen(uint16_t usVID, uint16_t usPID, int whichdongle)
Open FCD device.
Definition: fcdhid.c:31
void closeDevice()
hid_device * m_dev
Definition: fcdproinput.h:169
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
bool openFCDAudio(const char *filename)
uint32_t getSamplingDeviceSequence() const
Definition: deviceapi.h:123
+ Here is the call graph for this function:

◆ openFCDAudio()

bool FCDProInput::openFCDAudio ( const char *  filename)
private

Definition at line 162 of file fcdproinput.cpp.

References AudioInput::addFifo(), DSPEngine::getAudioDeviceManager(), AudioDeviceManager::getInputDeviceIndex(), AudioDeviceManager::getInputDevices(), AudioInput::getRate(), DSPEngine::instance(), m_fcdAudioInput, m_fcdFIFO, and AudioInput::start().

Referenced by openDevice().

163 {
165  const QList<QAudioDeviceInfo>& audioList = audioDeviceManager->getInputDevices();
166 
167  for (const auto &itAudio : audioList)
168  {
169  if (itAudio.deviceName().contains(QString(cardname)))
170  {
171  int fcdDeviceIndex = audioDeviceManager->getInputDeviceIndex(itAudio.deviceName());
173  int fcdSampleRate = m_fcdAudioInput.getRate();
174  qDebug("FCDProPlusInput::openFCDAudio: %s index %d at %d S/s",
175  itAudio.deviceName().toStdString().c_str(), fcdDeviceIndex, fcdSampleRate);
177  return true;
178  }
179  }
180 
181  qCritical("FCDProInput::openFCDAudio: device with name %s not found", cardname);
182  return false;
183 }
const QList< QAudioDeviceInfo > & getInputDevices() const
AudioInput m_fcdAudioInput
Definition: fcdproinput.h:170
AudioFifo m_fcdFIFO
Definition: fcdproinput.h:171
static DSPEngine * instance()
Definition: dspengine.cpp:51
bool start(int device, int rate)
Definition: audioinput.cpp:49
AudioDeviceManager * getAudioDeviceManager()
Definition: dspengine.h:55
int getInputDeviceIndex(const QString &deviceName) const
uint getRate() const
Definition: audioinput.h:45
void addFifo(AudioFifo *audioFifo)
Definition: audioinput.cpp:142
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ serialize()

QByteArray FCDProInput::serialize ( ) const
virtual

Implements DeviceSampleSource.

Definition at line 206 of file fcdproinput.cpp.

References m_settings, and FCDProSettings::serialize().

207 {
208  return m_settings.serialize();
209 }
FCDProSettings m_settings
Definition: fcdproinput.h:173
QByteArray serialize() const
+ Here is the call graph for this function:

◆ set_band()

void FCDProInput::set_band ( int  index)

Definition at line 633 of file fcdproinput.cpp.

References FCDProConstants::bands, FCD_MODE_APP, fcdAppSetParam(), FCDProConstants::fcdpro_band_nb_values(), FCDPRO_HID_CMD_SET_BAND, m_dev, and fcdpro_band::value.

Referenced by applySettings().

634 {
635  if ((index < 0) || (index >= FCDProConstants::fcdpro_band_nb_values()))
636  {
637  return;
638  }
639 
640  quint8 cmd_value = FCDProConstants::bands[index].value;
641 
643  {
644  qWarning() << "FCDProPlusInput::set_band: failed to set at " << cmd_value;
645  }
646 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
fcdpro_band_value value
Definition: fcdproconst.h:61
#define FCDPRO_HID_CMD_SET_BAND
Definition: fcdprohidcmd.h:14
static int fcdpro_band_nb_values()
Definition: fcdproconst.cpp:51
hid_device * m_dev
Definition: fcdproinput.h:169
static const fcdpro_band bands[]
Definition: fcdproconst.h:328
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_bias_t()

void FCDProInput::set_bias_t ( bool  on)

Definition at line 579 of file fcdproinput.cpp.

580 {
581  (void) on;
582  //quint8 cmd = on ? 1 : 0;
583 
584  // TODO: use FCD Pro controls
585  //fcdAppSetParam(m_dev, FCD_CMD_APP_SET_BIAS_TEE, &cmd, 1);
586 }

◆ set_biasCurrent()

void FCDProInput::set_biasCurrent ( int  index)

Definition at line 678 of file fcdproinput.cpp.

References FCDProConstants::bias_currents, FCD_MODE_APP, fcdAppSetParam(), FCDProConstants::fcdpro_bias_current_nb_values(), FCDPRO_HID_CMD_SET_BIAS_CURRENT, m_dev, and fcdpro_bias_current::value.

Referenced by applySettings().

679 {
680  if ((index < 0) || (index >= FCDProConstants::fcdpro_bias_current_nb_values()))
681  {
682  return;
683  }
684 
685  quint8 cmd_value = FCDProConstants::bias_currents[index].value;
686 
688  {
689  qWarning() << "FCDProPlusInput::set_biasCurrent: failed to set at " << cmd_value;
690  }
691 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_bias_current bias_currents[]
Definition: fcdproconst.h:331
static int fcdpro_bias_current_nb_values()
#define FCDPRO_HID_CMD_SET_BIAS_CURRENT
Definition: fcdprohidcmd.h:17
fcdpro_bias_current_value value
Definition: fcdproconst.h:137
hid_device * m_dev
Definition: fcdproinput.h:169
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_center_freq()

void FCDProInput::set_center_freq ( double  freq)

Definition at line 568 of file fcdproinput.cpp.

References FCD_MODE_NONE, fcdAppSetFreq(), m_dev, FCDProSettings::m_LOppmTenths, and m_settings.

Referenced by applySettings().

569 {
570  freq += freq*(((double) m_settings.m_LOppmTenths)/10000000.0);
571 
572  if (fcdAppSetFreq(m_dev, freq) == FCD_MODE_NONE)
573  {
574  qDebug("No FCD HID found for frquency change");
575  }
576 
577 }
FCD_MODE_ENUM fcdAppSetFreq(hid_device *phd, int nFreq)
Set FCD frequency with Hz resolution.
Definition: fcdhid.c:450
FCDProSettings m_settings
Definition: fcdproinput.h:173
qint32 m_LOppmTenths
hid_device * m_dev
Definition: fcdproinput.h:169
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_gain1()

void FCDProInput::set_gain1 ( int  index)

Definition at line 708 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN1, FCDProConstants::fcdpro_if_gain1_nb_values(), FCDProConstants::if_gains1, m_dev, and fcdpro_if_gain1::value.

Referenced by applySettings().

709 {
710  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain1_nb_values()))
711  {
712  return;
713  }
714 
715  quint8 cmd_value = FCDProConstants::if_gains1[index].value;
716 
718  {
719  qWarning() << "FCDProPlusInput::set_gain1: failed to set at " << cmd_value;
720  }
721 }
fcdpro_if_gain1_value value
Definition: fcdproconst.h:168
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_if_gain1 if_gains1[]
Definition: fcdproconst.h:336
static int fcdpro_if_gain1_nb_values()
hid_device * m_dev
Definition: fcdproinput.h:169
#define FCDPRO_HID_CMD_SET_IF_GAIN1
Definition: fcdprohidcmd.h:19
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_gain2()

void FCDProInput::set_gain2 ( int  index)

Definition at line 738 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN2, FCDProConstants::fcdpro_if_gain2_nb_values(), FCDProConstants::if_gains2, m_dev, and fcdpro_if_gain2::value.

Referenced by applySettings().

739 {
740  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain2_nb_values()))
741  {
742  return;
743  }
744 
745  quint8 cmd_value = FCDProConstants::if_gains2[index].value;
746 
748  {
749  qWarning() << "FCDProPlusInput::set_gain2: failed to set at " << cmd_value;
750  }
751 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_if_gain2 if_gains2[]
Definition: fcdproconst.h:337
#define FCDPRO_HID_CMD_SET_IF_GAIN2
Definition: fcdprohidcmd.h:22
static int fcdpro_if_gain2_nb_values()
fcdpro_if_gain2_value value
Definition: fcdproconst.h:220
hid_device * m_dev
Definition: fcdproinput.h:169
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_gain3()

void FCDProInput::set_gain3 ( int  index)

Definition at line 753 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN3, FCDProConstants::fcdpro_if_gain3_nb_values(), FCDProConstants::if_gains3, m_dev, and fcdpro_if_gain3::value.

Referenced by applySettings().

754 {
755  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain3_nb_values()))
756  {
757  return;
758  }
759 
760  quint8 cmd_value = FCDProConstants::if_gains3[index].value;
761 
763  {
764  qWarning() << "FCDProPlusInput::set_gain3: failed to set at " << cmd_value;
765  }
766 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_if_gain3 if_gains3[]
Definition: fcdproconst.h:338
static int fcdpro_if_gain3_nb_values()
#define FCDPRO_HID_CMD_SET_IF_GAIN3
Definition: fcdprohidcmd.h:23
fcdpro_if_gain3_value value
Definition: fcdproconst.h:234
hid_device * m_dev
Definition: fcdproinput.h:169
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_gain4()

void FCDProInput::set_gain4 ( int  index)

Definition at line 768 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN4, FCDProConstants::fcdpro_if_gain4_nb_values(), FCDProConstants::if_gains4, m_dev, and fcdpro_if_gain4::value.

Referenced by applySettings().

769 {
770  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain4_nb_values()))
771  {
772  return;
773  }
774 
775  quint8 cmd_value = FCDProConstants::if_gains4[index].value;
776 
778  {
779  qWarning() << "FCDProPlusInput::set_gain4: failed to set at " << cmd_value;
780  }
781 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
fcdpro_if_gain4_value value
Definition: fcdproconst.h:247
hid_device * m_dev
Definition: fcdproinput.h:169
static const fcdpro_if_gain4 if_gains4[]
Definition: fcdproconst.h:339
#define FCDPRO_HID_CMD_SET_IF_GAIN4
Definition: fcdprohidcmd.h:25
static int fcdpro_if_gain4_nb_values()
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_gain5()

void FCDProInput::set_gain5 ( int  index)

Definition at line 799 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN5, FCDProConstants::fcdpro_if_gain5_nb_values(), FCDProConstants::if_gains5, m_dev, and fcdpro_if_gain5::value.

Referenced by applySettings().

800 {
801  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain5_nb_values()))
802  {
803  return;
804  }
805 
806  quint8 cmd_value = FCDProConstants::if_gains5[index].value;
807 
809  {
810  qWarning() << "FCDProPlusInput::set_gain5: failed to set at " << cmd_value;
811  }
812 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
fcdpro_if_gain5_value value
Definition: fcdproconst.h:304
#define FCDPRO_HID_CMD_SET_IF_GAIN5
Definition: fcdprohidcmd.h:26
hid_device * m_dev
Definition: fcdproinput.h:169
static const fcdpro_if_gain5 if_gains5[]
Definition: fcdproconst.h:340
static int fcdpro_if_gain5_nb_values()
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_gain6()

void FCDProInput::set_gain6 ( int  index)

Definition at line 814 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN6, FCDProConstants::fcdpro_if_gain6_nb_values(), FCDProConstants::if_gains6, m_dev, and fcdpro_if_gain6::value.

Referenced by applySettings().

815 {
816  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain6_nb_values()))
817  {
818  return;
819  }
820 
821  quint8 cmd_value = FCDProConstants::if_gains6[index].value;
822 
824  {
825  qWarning() << "FCDProPlusInput::set_gain6: failed to set at " << cmd_value;
826  }
827 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_if_gain6 if_gains6[]
Definition: fcdproconst.h:341
static int fcdpro_if_gain6_nb_values()
fcdpro_if_gain6_value value
Definition: fcdproconst.h:319
hid_device * m_dev
Definition: fcdproinput.h:169
#define FCDPRO_HID_CMD_SET_IF_GAIN6
Definition: fcdprohidcmd.h:27
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_ifFilter()

void FCDProInput::set_ifFilter ( int  index)

Definition at line 783 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_FILTER, FCDProConstants::fcdpro_if_filter_nb_values(), FCDProConstants::if_filters, m_dev, and fcdpro_if_filter::value.

Referenced by applySettings().

784 {
785  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_filter_nb_values()))
786  {
787  return;
788  }
789 
790  quint8 cmd_value = FCDProConstants::if_filters[index].value;
791 
793  {
794  qWarning() << "FCDProPlusInput::set_ifFilter: failed to set at " << cmd_value;
795  }
796 
797 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
#define FCDPRO_HID_CMD_SET_IF_FILTER
Definition: fcdprohidcmd.h:24
static int fcdpro_if_filter_nb_values()
fcdpro_if_filter_value value
Definition: fcdproconst.h:289
static const fcdpro_if_filter if_filters[]
Definition: fcdproconst.h:335
hid_device * m_dev
Definition: fcdproinput.h:169
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_lnaEnhance()

void FCDProInput::set_lnaEnhance ( int  index)

Definition at line 618 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_LNA_ENHANCE, FCDProConstants::fcdpro_lna_enhance_nb_values(), FCDProConstants::lna_enhances, m_dev, and fcdpro_lna_enhance::value.

Referenced by applySettings().

619 {
620  if ((index < 0) || (index >= FCDProConstants::fcdpro_lna_enhance_nb_values()))
621  {
622  return;
623  }
624 
625  quint8 cmd_value = FCDProConstants::lna_enhances[index].value;
626 
628  {
629  qWarning() << "FCDProPlusInput::set_lnaEnhance: failed to set at " << cmd_value;
630  }
631 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static int fcdpro_lna_enhance_nb_values()
Definition: fcdproconst.cpp:39
#define FCDPRO_HID_CMD_SET_LNA_ENHANCE
Definition: fcdprohidcmd.h:13
hid_device * m_dev
Definition: fcdproinput.h:169
fcdpro_lna_enhance_value value
Definition: fcdproconst.h:47
static const fcdpro_lna_enhance lna_enhances[]
Definition: fcdproconst.h:327
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_lnaGain()

void FCDProInput::set_lnaGain ( int  index)

Definition at line 588 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_LNA_GAIN, FCDProConstants::fcdpro_lna_gain_nb_values(), FCDProConstants::lna_gains, m_dev, and fcdpro_lna_gain::value.

Referenced by applySettings().

589 {
590  if ((index < 0) || (index >= FCDProConstants::fcdpro_lna_gain_nb_values()))
591  {
592  return;
593  }
594 
595  quint8 cmd_value = FCDProConstants::lna_gains[index].value;
596 
598  {
599  qWarning() << "FCDProPlusInput::set_lnaGain: failed to set at " << cmd_value;
600  }
601 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_lna_gain lna_gains[]
Definition: fcdproconst.h:326
static int fcdpro_lna_gain_nb_values()
Definition: fcdproconst.cpp:26
#define FCDPRO_HID_CMD_SET_LNA_GAIN
Definition: fcdprohidcmd.h:12
hid_device * m_dev
Definition: fcdproinput.h:169
fcdpro_lna_gain_value value
Definition: fcdproconst.h:32
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_mixerFilter()

void FCDProInput::set_mixerFilter ( int  index)

Definition at line 663 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_MIXER_FILTER, FCDProConstants::fcdpro_mixer_filter_nb_values(), m_dev, FCDProConstants::mixer_filters, and fcdpro_mixer_filter::value.

Referenced by applySettings().

664 {
665  if ((index < 0) || (index >= FCDProConstants::fcdpro_mixer_filter_nb_values()))
666  {
667  return;
668  }
669 
670  quint8 cmd_value = FCDProConstants::mixer_filters[index].value;
671 
673  {
674  qWarning() << "FCDProPlusInput::set_mixerFilter: failed to set at " << cmd_value;
675  }
676 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
#define FCDPRO_HID_CMD_SET_MIXER_FILTER
Definition: fcdprohidcmd.h:18
fcdpro_mixer_filter_value value
Definition: fcdproconst.h:156
hid_device * m_dev
Definition: fcdproinput.h:169
static const fcdpro_mixer_filter mixer_filters[]
Definition: fcdproconst.h:332
static int fcdpro_mixer_filter_nb_values()
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_mixerGain()

void FCDProInput::set_mixerGain ( int  index)

Definition at line 648 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_MIXER_GAIN, FCDProConstants::fcdpro_mixer_gain_nb_values(), m_dev, FCDProConstants::mixer_gains, and fcdpro_mixer_gain::value.

Referenced by applySettings().

649 {
650  if ((index < 0) || (index >= FCDProConstants::fcdpro_mixer_gain_nb_values()))
651  {
652  return;
653  }
654 
655  quint8 cmd_value = FCDProConstants::mixer_gains[index].value;
656 
658  {
659  qWarning() << "FCDProPlusInput::set_mixerGain: failed to set at " << cmd_value;
660  }
661 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static int fcdpro_mixer_gain_nb_values()
#define FCDPRO_HID_CMD_SET_MIXER_GAIN
Definition: fcdprohidcmd.h:16
hid_device * m_dev
Definition: fcdproinput.h:169
fcdpro_mixer_gain_value value
Definition: fcdproconst.h:123
static const fcdpro_mixer_gain mixer_gains[]
Definition: fcdproconst.h:330
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_mode()

void FCDProInput::set_mode ( int  index)

Definition at line 693 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_GAIN_MODE, FCDProConstants::fcdpro_if_gain_mode_nb_values(), FCDProConstants::if_gain_modes, m_dev, and fcdpro_if_gain_mode::value.

Referenced by applySettings().

694 {
695  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_gain_mode_nb_values()))
696  {
697  return;
698  }
699 
700  quint8 cmd_value = FCDProConstants::if_gain_modes[index].value;
701 
703  {
704  qWarning() << "FCDProPlusInput::set_mode: failed to set at " << cmd_value;
705  }
706 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static const fcdpro_if_gain_mode if_gain_modes[]
Definition: fcdproconst.h:333
fcdpro_if_gain_mode_value value
Definition: fcdproconst.h:180
hid_device * m_dev
Definition: fcdproinput.h:169
static int fcdpro_if_gain_mode_nb_values()
#define FCDPRO_HID_CMD_SET_IF_GAIN_MODE
Definition: fcdprohidcmd.h:20
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_rcFilter()

void FCDProInput::set_rcFilter ( int  index)

Definition at line 723 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_IF_RC_FILTER, FCDProConstants::fcdpro_if_rc_filter_nb_values(), FCDProConstants::if_rc_filters, m_dev, and fcdpro_if_rc_filter::value.

Referenced by applySettings().

724 {
725  if ((index < 0) || (index >= FCDProConstants::fcdpro_if_rc_filter_nb_values()))
726  {
727  return;
728  }
729 
730  quint8 cmd_value = FCDProConstants::if_rc_filters[index].value;
731 
733  {
734  qWarning() << "FCDProPlusInput::set_rcFilter: failed to set at " << cmd_value;
735  }
736 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
fcdpro_if_rc_filter_value value
Definition: fcdproconst.h:206
#define FCDPRO_HID_CMD_SET_IF_RC_FILTER
Definition: fcdprohidcmd.h:21
static int fcdpro_if_rc_filter_nb_values()
hid_device * m_dev
Definition: fcdproinput.h:169
static const fcdpro_if_rc_filter if_rc_filters[]
Definition: fcdproconst.h:334
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ set_rfFilter()

void FCDProInput::set_rfFilter ( int  index)

Definition at line 603 of file fcdproinput.cpp.

References FCD_MODE_APP, fcdAppSetParam(), FCDPRO_HID_CMD_SET_RF_FILTER, FCDProConstants::fcdpro_rf_filter_nb_values(), m_dev, FCDProConstants::rf_filters, and fcdpro_rf_filter::value.

Referenced by applySettings().

604 {
605  if ((index < 0) || (index >= FCDProConstants::fcdpro_rf_filter_nb_values()))
606  {
607  return;
608  }
609 
610  quint8 cmd_value = FCDProConstants::rf_filters[index].value;
611 
613  {
614  qWarning() << "FCDProPlusInput::set_rfFilter: failed to set at " << cmd_value;
615  }
616 }
FCD_MODE_ENUM fcdAppSetParam(hid_device *phd, uint8_t u8Cmd, uint8_t *pu8Data, uint8_t u8len)
Write FCD parameter (e.g. gain or filter)
Definition: fcdhid.c:826
static int fcdpro_rf_filter_nb_values()
Definition: fcdproconst.cpp:99
static const fcdpro_rf_filter rf_filters[]
Definition: fcdproconst.h:329
#define FCDPRO_HID_CMD_SET_RF_FILTER
Definition: fcdprohidcmd.h:15
hid_device * m_dev
Definition: fcdproinput.h:169
fcdpro_rf_filter_value value
Definition: fcdproconst.h:111
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setCenterFrequency()

void FCDProInput::setCenterFrequency ( qint64  centerFrequency)
virtual

Implements DeviceSampleSource.

Definition at line 248 of file fcdproinput.cpp.

References FCDProInput::MsgConfigureFCDPro::create(), FCDProSettings::m_centerFrequency, DeviceSampleSource::m_guiMessageQueue, DeviceSampleSource::m_inputMessageQueue, m_settings, and MessageQueue::push().

249 {
250  FCDProSettings settings = m_settings;
251  settings.m_centerFrequency = centerFrequency;
252 
253  MsgConfigureFCDPro* message = MsgConfigureFCDPro::create(settings, false);
254  m_inputMessageQueue.push(message);
255 
256  if (m_guiMessageQueue)
257  {
258  MsgConfigureFCDPro* messageToGUI = MsgConfigureFCDPro::create(settings, false);
259  m_guiMessageQueue->push(messageToGUI);
260  }
261 }
void push(Message *message, bool emitSignal=true)
Push message onto queue.
MessageQueue m_inputMessageQueue
Input queue to the source.
FCDProSettings m_settings
Definition: fcdproinput.h:173
static MsgConfigureFCDPro * create(const FCDProSettings &settings, bool force)
Definition: fcdproinput.h:55
MessageQueue * m_guiMessageQueue
Input message queue to the GUI.
quint64 m_centerFrequency
+ Here is the call graph for this function:

◆ setMessageQueueToGUI()

virtual void FCDProInput::setMessageQueueToGUI ( MessageQueue queue)
inlinevirtual

Implements DeviceSampleSource.

Definition at line 120 of file fcdproinput.h.

120 { m_guiMessageQueue = queue; }
MessageQueue * m_guiMessageQueue
Input message queue to the GUI.

◆ setSampleRate()

virtual void FCDProInput::setSampleRate ( int  sampleRate)
inlinevirtual

For when the source sample rate is set externally.

Implements DeviceSampleSource.

Definition at line 123 of file fcdproinput.h.

123 { (void) sampleRate; }

◆ start()

bool FCDProInput::start ( )
virtual

Implements DeviceSampleSource.

Definition at line 113 of file fcdproinput.cpp.

References applySettings(), m_dev, m_fcdFIFO, m_FCDThread, m_running, DeviceSampleSource::m_sampleFifo, m_settings, SampleSinkFifo::setSize(), FCDProThread::startWork(), and stop().

114 {
115  qDebug() << "FCDProInput::start";
116 
117 // QMutexLocker mutexLocker(&m_mutex);
118 
119  if (!m_dev) {
120  return false;
121  }
122 
123  if (m_running) stop();
124 
125  /* Apply settings before streaming to avoid bus contention;
126  * there is very little spare bandwidth on a full speed USB device.
127  * Failure is harmless if no device is found
128  * ... This is rubbish...*/
129 
130  //applySettings(m_settings, true);
131 
132  if(!m_sampleFifo.setSize(96000*4))
133  {
134  qCritical("Could not allocate SampleFifo");
135  return false;
136  }
137 
140 
141 // mutexLocker.unlock();
142  applySettings(m_settings, true);
143 
144  qDebug("FCDProInput::started");
145  m_running = true;
146 
147  return true;
148 }
virtual void stop()
AudioFifo m_fcdFIFO
Definition: fcdproinput.h:171
void applySettings(const FCDProSettings &settings, bool force)
bool m_running
Definition: fcdproinput.h:176
SampleSinkFifo m_sampleFifo
bool setSize(int size)
FCDProSettings m_settings
Definition: fcdproinput.h:173
hid_device * m_dev
Definition: fcdproinput.h:169
void startWork()
FCDProThread * m_FCDThread
Definition: fcdproinput.h:174
+ Here is the call graph for this function:

◆ stop()

void FCDProInput::stop ( )
virtual

Implements DeviceSampleSource.

Definition at line 191 of file fcdproinput.cpp.

References m_FCDThread, m_running, and FCDProThread::stopWork().

Referenced by start(), and ~FCDProInput().

192 {
193 // QMutexLocker mutexLocker(&m_mutex);
194 
195  if (m_FCDThread)
196  {
198  // wait for thread to quit ?
199  delete m_FCDThread;
200  m_FCDThread = nullptr;
201  }
202 
203  m_running = false;
204 }
bool m_running
Definition: fcdproinput.h:176
FCDProThread * m_FCDThread
Definition: fcdproinput.h:174
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ webapiFormatDeviceSettings()

void FCDProInput::webapiFormatDeviceSettings ( SWGSDRangel::SWGDeviceSettings response,
const FCDProSettings settings 
)
private

Definition at line 978 of file fcdproinput.cpp.

References SWGSDRangel::SWGDeviceSettings::getFcdProSettings(), SWGSDRangel::SWGFCDProSettings::getFileRecordName(), SWGSDRangel::SWGFCDProSettings::getReverseApiAddress(), FCDProSettings::m_bandIndex, FCDProSettings::m_biasCurrentIndex, FCDProSettings::m_centerFrequency, FCDProSettings::m_dcBlock, FCDProSettings::m_fcPos, FCDProSettings::m_fileRecordName, FCDProSettings::m_gain1Index, FCDProSettings::m_gain2Index, FCDProSettings::m_gain3Index, FCDProSettings::m_gain4Index, FCDProSettings::m_gain5Index, FCDProSettings::m_gain6Index, FCDProSettings::m_ifFilterIndex, FCDProSettings::m_iqCorrection, FCDProSettings::m_lnaEnhanceIndex, FCDProSettings::m_lnaGainIndex, FCDProSettings::m_log2Decim, FCDProSettings::m_LOppmTenths, FCDProSettings::m_mixerFilterIndex, FCDProSettings::m_mixerGainIndex, FCDProSettings::m_modeIndex, FCDProSettings::m_rcFilterIndex, FCDProSettings::m_reverseAPIAddress, FCDProSettings::m_reverseAPIDeviceIndex, FCDProSettings::m_reverseAPIPort, FCDProSettings::m_rfFilterIndex, FCDProSettings::m_transverterDeltaFrequency, FCDProSettings::m_transverterMode, FCDProSettings::m_useReverseAPI, SWGSDRangel::SWGFCDProSettings::setBandIndex(), SWGSDRangel::SWGFCDProSettings::setBiasCurrentIndex(), SWGSDRangel::SWGFCDProSettings::setCenterFrequency(), SWGSDRangel::SWGFCDProSettings::setDcBlock(), SWGSDRangel::SWGFCDProSettings::setFcPos(), SWGSDRangel::SWGFCDProSettings::setFileRecordName(), SWGSDRangel::SWGFCDProSettings::setGain1Index(), SWGSDRangel::SWGFCDProSettings::setGain2Index(), SWGSDRangel::SWGFCDProSettings::setGain3Index(), SWGSDRangel::SWGFCDProSettings::setGain4Index(), SWGSDRangel::SWGFCDProSettings::setGain5Index(), SWGSDRangel::SWGFCDProSettings::setGain6Index(), SWGSDRangel::SWGFCDProSettings::setIfFilterIndex(), SWGSDRangel::SWGFCDProSettings::setIqCorrection(), SWGSDRangel::SWGFCDProSettings::setLnaEnhanceIndex(), SWGSDRangel::SWGFCDProSettings::setLnaGainIndex(), SWGSDRangel::SWGFCDProSettings::setLog2Decim(), SWGSDRangel::SWGFCDProSettings::setLOppmTenths(), SWGSDRangel::SWGFCDProSettings::setMixerFilterIndex(), SWGSDRangel::SWGFCDProSettings::setMixerGainIndex(), SWGSDRangel::SWGFCDProSettings::setModeIndex(), SWGSDRangel::SWGFCDProSettings::setRcFilterIndex(), SWGSDRangel::SWGFCDProSettings::setReverseApiAddress(), SWGSDRangel::SWGFCDProSettings::setReverseApiDeviceIndex(), SWGSDRangel::SWGFCDProSettings::setReverseApiPort(), SWGSDRangel::SWGFCDProSettings::setRfFilterIndex(), SWGSDRangel::SWGFCDProSettings::setTransverterDeltaFrequency(), SWGSDRangel::SWGFCDProSettings::setTransverterMode(), and SWGSDRangel::SWGFCDProSettings::setUseReverseApi().

Referenced by webapiSettingsGet(), and webapiSettingsPutPatch().

979 {
981  response.getFcdProSettings()->setLOppmTenths(settings.m_LOppmTenths);
982  response.getFcdProSettings()->setLnaGainIndex(settings.m_lnaGainIndex);
983  response.getFcdProSettings()->setRfFilterIndex(settings.m_rfFilterIndex);
985  response.getFcdProSettings()->setBandIndex(settings.m_bandIndex);
989  response.getFcdProSettings()->setModeIndex(settings.m_modeIndex);
990  response.getFcdProSettings()->setGain1Index(settings.m_gain1Index);
991  response.getFcdProSettings()->setGain2Index(settings.m_gain2Index);
992  response.getFcdProSettings()->setGain3Index(settings.m_gain3Index);
993  response.getFcdProSettings()->setGain4Index(settings.m_gain4Index);
994  response.getFcdProSettings()->setGain5Index(settings.m_gain5Index);
995  response.getFcdProSettings()->setGain6Index(settings.m_gain6Index);
996  response.getFcdProSettings()->setLog2Decim(settings.m_log2Decim);
997  response.getFcdProSettings()->setFcPos((int) settings.m_fcPos);
998  response.getFcdProSettings()->setRcFilterIndex(settings.m_rcFilterIndex);
999  response.getFcdProSettings()->setIfFilterIndex(settings.m_ifFilterIndex);
1000  response.getFcdProSettings()->setDcBlock(settings.m_dcBlock ? 1 : 0);
1001  response.getFcdProSettings()->setIqCorrection(settings.m_iqCorrection ? 1 : 0);
1003  response.getFcdProSettings()->setTransverterMode(settings.m_transverterMode ? 1 : 0);
1004 
1005  if (response.getFcdProSettings()->getFileRecordName()) {
1006  *response.getFcdProSettings()->getFileRecordName() = settings.m_fileRecordName;
1007  } else {
1008  response.getFcdProSettings()->setFileRecordName(new QString(settings.m_fileRecordName));
1009  }
1010 
1011  response.getFcdProSettings()->setUseReverseApi(settings.m_useReverseAPI ? 1 : 0);
1012 
1013  if (response.getFcdProSettings()->getReverseApiAddress()) {
1015  } else {
1016  response.getFcdProSettings()->setReverseApiAddress(new QString(settings.m_reverseAPIAddress));
1017  }
1018 
1021 }
void setGain1Index(qint32 gain1_index)
uint16_t m_reverseAPIPort
qint32 m_lnaEnhanceIndex
SWGFCDProSettings * getFcdProSettings()
void setMixerFilterIndex(qint32 mixer_filter_index)
void setGain6Index(qint32 gain6_index)
qint32 m_mixerGainIndex
void setIqCorrection(qint32 iq_correction)
void setGain5Index(qint32 gain5_index)
void setLOppmTenths(qint32 l_oppm_tenths)
quint32 m_log2Decim
void setTransverterDeltaFrequency(qint64 transverter_delta_frequency)
qint32 m_lnaGainIndex
void setReverseApiDeviceIndex(qint32 reverse_api_device_index)
void setRfFilterIndex(qint32 rf_filter_index)
qint32 m_ifFilterIndex
void setCenterFrequency(qint64 center_frequency)
void setBandIndex(qint32 band_index)
qint64 m_transverterDeltaFrequency
void setGain2Index(qint32 gain2_index)
void setGain4Index(qint32 gain4_index)
uint16_t m_reverseAPIDeviceIndex
void setModeIndex(qint32 mode_index)
void setRcFilterIndex(qint32 rc_filter_index)
void setBiasCurrentIndex(qint32 bias_current_index)
void setGain3Index(qint32 gain3_index)
void setLnaGainIndex(qint32 lna_gain_index)
qint32 m_LOppmTenths
void setMixerGainIndex(qint32 mixer_gain_index)
qint32 m_rfFilterIndex
qint32 m_mixerFilterIndex
void setUseReverseApi(qint32 use_reverse_api)
void setLnaEnhanceIndex(qint32 lna_enhance_index)
void setFileRecordName(QString *file_record_name)
void setTransverterMode(qint32 transverter_mode)
void setReverseApiPort(qint32 reverse_api_port)
QString m_reverseAPIAddress
void setReverseApiAddress(QString *reverse_api_address)
QString m_fileRecordName
void setLog2Decim(qint32 log2_decim)
qint32 m_rcFilterIndex
quint64 m_centerFrequency
qint32 m_biasCurrentIndex
void setIfFilterIndex(qint32 if_filter_index)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ webapiReverseSendSettings()

void FCDProInput::webapiReverseSendSettings ( QList< QString > &  deviceSettingsKeys,
const FCDProSettings settings,
bool  force 
)
private

Definition at line 1023 of file fcdproinput.cpp.

References SWGSDRangel::SWGDeviceSettings::asJson(), DeviceAPI::getDeviceSetIndex(), SWGSDRangel::SWGDeviceSettings::getFcdProSettings(), FCDProSettings::m_bandIndex, FCDProSettings::m_biasCurrentIndex, FCDProSettings::m_centerFrequency, FCDProSettings::m_dcBlock, m_deviceAPI, FCDProSettings::m_fcPos, FCDProSettings::m_fileRecordName, FCDProSettings::m_gain1Index, FCDProSettings::m_gain2Index, FCDProSettings::m_gain3Index, FCDProSettings::m_gain4Index, FCDProSettings::m_gain5Index, FCDProSettings::m_gain6Index, FCDProSettings::m_ifFilterIndex, FCDProSettings::m_iqCorrection, FCDProSettings::m_lnaEnhanceIndex, FCDProSettings::m_lnaGainIndex, FCDProSettings::m_log2Decim, FCDProSettings::m_LOppmTenths, FCDProSettings::m_mixerFilterIndex, FCDProSettings::m_mixerGainIndex, FCDProSettings::m_modeIndex, m_networkManager, m_networkRequest, FCDProSettings::m_rcFilterIndex, FCDProSettings::m_reverseAPIAddress, FCDProSettings::m_reverseAPIDeviceIndex, FCDProSettings::m_reverseAPIPort, FCDProSettings::m_rfFilterIndex, FCDProSettings::m_transverterDeltaFrequency, FCDProSettings::m_transverterMode, SWGSDRangel::SWGFCDProSettings::setBandIndex(), SWGSDRangel::SWGFCDProSettings::setBiasCurrentIndex(), SWGSDRangel::SWGFCDProSettings::setCenterFrequency(), SWGSDRangel::SWGFCDProSettings::setDcBlock(), SWGSDRangel::SWGDeviceSettings::setDeviceHwType(), SWGSDRangel::SWGDeviceSettings::setDirection(), SWGSDRangel::SWGDeviceSettings::setFcdProSettings(), SWGSDRangel::SWGFCDProSettings::setFcPos(), SWGSDRangel::SWGFCDProSettings::setFileRecordName(), SWGSDRangel::SWGFCDProSettings::setGain1Index(), SWGSDRangel::SWGFCDProSettings::setGain2Index(), SWGSDRangel::SWGFCDProSettings::setGain3Index(), SWGSDRangel::SWGFCDProSettings::setGain4Index(), SWGSDRangel::SWGFCDProSettings::setGain5Index(), SWGSDRangel::SWGFCDProSettings::setGain6Index(), SWGSDRangel::SWGFCDProSettings::setIfFilterIndex(), SWGSDRangel::SWGFCDProSettings::setIqCorrection(), SWGSDRangel::SWGFCDProSettings::setLnaEnhanceIndex(), SWGSDRangel::SWGFCDProSettings::setLnaGainIndex(), SWGSDRangel::SWGFCDProSettings::setLog2Decim(), SWGSDRangel::SWGFCDProSettings::setLOppmTenths(), SWGSDRangel::SWGFCDProSettings::setMixerFilterIndex(), SWGSDRangel::SWGFCDProSettings::setMixerGainIndex(), SWGSDRangel::SWGFCDProSettings::setModeIndex(), SWGSDRangel::SWGDeviceSettings::setOriginatorIndex(), SWGSDRangel::SWGFCDProSettings::setRcFilterIndex(), SWGSDRangel::SWGFCDProSettings::setRfFilterIndex(), SWGSDRangel::SWGFCDProSettings::setTransverterDeltaFrequency(), and SWGSDRangel::SWGFCDProSettings::setTransverterMode().

Referenced by applySettings().

1024 {
1026  swgDeviceSettings->setDirection(0); // single Rx
1027  swgDeviceSettings->setOriginatorIndex(m_deviceAPI->getDeviceSetIndex());
1028  swgDeviceSettings->setDeviceHwType(new QString("FCDPro"));
1029  swgDeviceSettings->setFcdProSettings(new SWGSDRangel::SWGFCDProSettings());
1030  SWGSDRangel::SWGFCDProSettings *swgFCDProSettings = swgDeviceSettings->getFcdProSettings();
1031 
1032  // transfer data that has been modified. When force is on transfer all data except reverse API data
1033 
1034  if (deviceSettingsKeys.contains("centerFrequency") || force) {
1035  swgFCDProSettings->setCenterFrequency(settings.m_centerFrequency);
1036  }
1037  if (deviceSettingsKeys.contains("LOppmTenths") || force) {
1038  swgFCDProSettings->setLOppmTenths(settings.m_LOppmTenths);
1039  }
1040  if (deviceSettingsKeys.contains("lnaGainIndex") || force) {
1041  swgFCDProSettings->setLnaGainIndex(settings.m_lnaGainIndex);
1042  }
1043  if (deviceSettingsKeys.contains("rfFilterIndex") || force) {
1044  swgFCDProSettings->setRfFilterIndex(settings.m_rfFilterIndex);
1045  }
1046  if (deviceSettingsKeys.contains("lnaEnhanceIndex") || force) {
1047  swgFCDProSettings->setLnaEnhanceIndex(settings.m_lnaEnhanceIndex);
1048  }
1049  if (deviceSettingsKeys.contains("bandIndex") || force) {
1050  swgFCDProSettings->setBandIndex(settings.m_bandIndex);
1051  }
1052  if (deviceSettingsKeys.contains("mixerGainIndex") || force) {
1053  swgFCDProSettings->setMixerGainIndex(settings.m_mixerGainIndex);
1054  }
1055  if (deviceSettingsKeys.contains("mixerFilterIndex") || force) {
1056  swgFCDProSettings->setMixerFilterIndex(settings.m_mixerFilterIndex);
1057  }
1058  if (deviceSettingsKeys.contains("biasCurrentIndex") || force) {
1059  swgFCDProSettings->setBiasCurrentIndex(settings.m_biasCurrentIndex);
1060  }
1061  if (deviceSettingsKeys.contains("modeIndex") || force) {
1062  swgFCDProSettings->setModeIndex(settings.m_modeIndex);
1063  }
1064  if (deviceSettingsKeys.contains("gain1Index") || force) {
1065  swgFCDProSettings->setGain1Index(settings.m_gain1Index);
1066  }
1067  if (deviceSettingsKeys.contains("gain2Index") || force) {
1068  swgFCDProSettings->setGain2Index(settings.m_gain2Index);
1069  }
1070  if (deviceSettingsKeys.contains("gain3Index") || force) {
1071  swgFCDProSettings->setGain3Index(settings.m_gain3Index);
1072  }
1073  if (deviceSettingsKeys.contains("gain4Index") || force) {
1074  swgFCDProSettings->setGain4Index(settings.m_gain4Index);
1075  }
1076  if (deviceSettingsKeys.contains("gain5Index") || force) {
1077  swgFCDProSettings->setGain5Index(settings.m_gain5Index);
1078  }
1079  if (deviceSettingsKeys.contains("gain6Index") || force) {
1080  swgFCDProSettings->setGain6Index(settings.m_gain6Index);
1081  }
1082  if (deviceSettingsKeys.contains("log2Decim") || force) {
1083  swgFCDProSettings->setLog2Decim(settings.m_log2Decim);
1084  }
1085  if (deviceSettingsKeys.contains("fcPos") || force) {
1086  swgFCDProSettings->setFcPos(settings.m_fcPos);
1087  }
1088  if (deviceSettingsKeys.contains("rcFilterIndex") || force) {
1089  swgFCDProSettings->setRcFilterIndex(settings.m_rcFilterIndex);
1090  }
1091  if (deviceSettingsKeys.contains("ifFilterIndex") || force) {
1092  swgFCDProSettings->setIfFilterIndex(settings.m_ifFilterIndex);
1093  }
1094  if (deviceSettingsKeys.contains("dcBlock") || force) {
1095  swgFCDProSettings->setDcBlock(settings.m_dcBlock ? 1 : 0);
1096  }
1097  if (deviceSettingsKeys.contains("iqCorrection") || force) {
1098  swgFCDProSettings->setIqCorrection(settings.m_iqCorrection ? 1 : 0);
1099  }
1100  if (deviceSettingsKeys.contains("transverterDeltaFrequency") || force) {
1101  swgFCDProSettings->setTransverterDeltaFrequency(settings.m_transverterDeltaFrequency);
1102  }
1103  if (deviceSettingsKeys.contains("transverterMode") || force) {
1104  swgFCDProSettings->setTransverterMode(settings.m_transverterMode ? 1 : 0);
1105  }
1106  if (deviceSettingsKeys.contains("fileRecordName") || force) {
1107  swgFCDProSettings->setFileRecordName(new QString(settings.m_fileRecordName));
1108  }
1109 
1110  QString deviceSettingsURL = QString("http://%1:%2/sdrangel/deviceset/%3/device/settings")
1111  .arg(settings.m_reverseAPIAddress)
1112  .arg(settings.m_reverseAPIPort)
1113  .arg(settings.m_reverseAPIDeviceIndex);
1114  m_networkRequest.setUrl(QUrl(deviceSettingsURL));
1115  m_networkRequest.setHeader(QNetworkRequest::ContentTypeHeader, "application/json");
1116 
1117  QBuffer *buffer=new QBuffer();
1118  buffer->open((QBuffer::ReadWrite));
1119  buffer->write(swgDeviceSettings->asJson().toUtf8());
1120  buffer->seek(0);
1121 
1122  // Always use PATCH to avoid passing reverse API settings
1123  m_networkManager->sendCustomRequest(m_networkRequest, "PATCH", buffer);
1124 
1125  delete swgDeviceSettings;
1126 }
void setGain1Index(qint32 gain1_index)
uint16_t m_reverseAPIPort
QNetworkAccessManager * m_networkManager
Definition: fcdproinput.h:178
qint32 m_lnaEnhanceIndex
SWGFCDProSettings * getFcdProSettings()
void setMixerFilterIndex(qint32 mixer_filter_index)
void setGain6Index(qint32 gain6_index)
qint32 m_mixerGainIndex
void setIqCorrection(qint32 iq_correction)
virtual QString asJson() override
QNetworkRequest m_networkRequest
Definition: fcdproinput.h:179
void setGain5Index(qint32 gain5_index)
void setLOppmTenths(qint32 l_oppm_tenths)
quint32 m_log2Decim
void setTransverterDeltaFrequency(qint64 transverter_delta_frequency)
qint32 m_lnaGainIndex
void setOriginatorIndex(qint32 originator_index)
void setRfFilterIndex(qint32 rf_filter_index)
qint32 m_ifFilterIndex
void setCenterFrequency(qint64 center_frequency)
void setBandIndex(qint32 band_index)
qint64 m_transverterDeltaFrequency
void setGain2Index(qint32 gain2_index)
int getDeviceSetIndex() const
Definition: deviceapi.h:131
void setGain4Index(qint32 gain4_index)
uint16_t m_reverseAPIDeviceIndex
void setModeIndex(qint32 mode_index)
void setRcFilterIndex(qint32 rc_filter_index)
void setBiasCurrentIndex(qint32 bias_current_index)
void setGain3Index(qint32 gain3_index)
void setLnaGainIndex(qint32 lna_gain_index)
qint32 m_LOppmTenths
void setMixerGainIndex(qint32 mixer_gain_index)
qint32 m_rfFilterIndex
qint32 m_mixerFilterIndex
void setFcdProSettings(SWGFCDProSettings *fcd_pro_settings)
void setLnaEnhanceIndex(qint32 lna_enhance_index)
void setFileRecordName(QString *file_record_name)
void setTransverterMode(qint32 transverter_mode)
QString m_reverseAPIAddress
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
QString m_fileRecordName
void setLog2Decim(qint32 log2_decim)
qint32 m_rcFilterIndex
void setDirection(qint32 direction)
quint64 m_centerFrequency
void setDeviceHwType(QString *device_hw_type)
qint32 m_biasCurrentIndex
void setIfFilterIndex(qint32 if_filter_index)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ webapiReverseSendStartStop()

void FCDProInput::webapiReverseSendStartStop ( bool  start)
private

Definition at line 1128 of file fcdproinput.cpp.

References SWGSDRangel::SWGDeviceSettings::asJson(), DeviceAPI::getDeviceSetIndex(), m_deviceAPI, m_networkManager, m_networkRequest, FCDProSettings::m_reverseAPIAddress, FCDProSettings::m_reverseAPIDeviceIndex, FCDProSettings::m_reverseAPIPort, m_settings, SWGSDRangel::SWGDeviceSettings::setDeviceHwType(), SWGSDRangel::SWGDeviceSettings::setDirection(), and SWGSDRangel::SWGDeviceSettings::setOriginatorIndex().

Referenced by handleMessage().

1129 {
1131  swgDeviceSettings->setDirection(0); // single Rx
1132  swgDeviceSettings->setOriginatorIndex(m_deviceAPI->getDeviceSetIndex());
1133  swgDeviceSettings->setDeviceHwType(new QString("FCDPro"));
1134 
1135  QString deviceSettingsURL = QString("http://%1:%2/sdrangel/deviceset/%3/device/run")
1139  m_networkRequest.setUrl(QUrl(deviceSettingsURL));
1140  m_networkRequest.setHeader(QNetworkRequest::ContentTypeHeader, "application/json");
1141 
1142  QBuffer *buffer=new QBuffer();
1143  buffer->open((QBuffer::ReadWrite));
1144  buffer->write(swgDeviceSettings->asJson().toUtf8());
1145  buffer->seek(0);
1146 
1147  if (start) {
1148  m_networkManager->sendCustomRequest(m_networkRequest, "POST", buffer);
1149  } else {
1150  m_networkManager->sendCustomRequest(m_networkRequest, "DELETE", buffer);
1151  }
1152 
1153  delete swgDeviceSettings;
1154 }
uint16_t m_reverseAPIPort
QNetworkAccessManager * m_networkManager
Definition: fcdproinput.h:178
virtual QString asJson() override
QNetworkRequest m_networkRequest
Definition: fcdproinput.h:179
void setOriginatorIndex(qint32 originator_index)
FCDProSettings m_settings
Definition: fcdproinput.h:173
int getDeviceSetIndex() const
Definition: deviceapi.h:131
uint16_t m_reverseAPIDeviceIndex
virtual bool start()
QString m_reverseAPIAddress
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
void setDirection(qint32 direction)
void setDeviceHwType(QString *device_hw_type)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ webapiRun()

int FCDProInput::webapiRun ( bool  run,
SWGSDRangel::SWGDeviceState response,
QString &  errorMessage 
)
virtual

Reimplemented from DeviceSampleSource.

Definition at line 838 of file fcdproinput.cpp.

References FCDProInput::MsgStartStop::create(), DeviceAPI::getDeviceEngineStateStr(), SWGSDRangel::SWGDeviceState::getState(), m_deviceAPI, DeviceSampleSource::m_guiMessageQueue, DeviceSampleSource::m_inputMessageQueue, and MessageQueue::push().

842 {
843  (void) errorMessage;
845  MsgStartStop *message = MsgStartStop::create(run);
846  m_inputMessageQueue.push(message);
847 
848  if (m_guiMessageQueue) // forward to GUI if any
849  {
850  MsgStartStop *msgToGUI = MsgStartStop::create(run);
851  m_guiMessageQueue->push(msgToGUI);
852  }
853 
854  return 200;
855 }
void push(Message *message, bool emitSignal=true)
Push message onto queue.
MessageQueue m_inputMessageQueue
Input queue to the source.
MessageQueue * m_guiMessageQueue
Input message queue to the GUI.
void getDeviceEngineStateStr(QString &state)
Definition: deviceapi.cpp:389
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
static MsgStartStop * create(bool startStop)
Definition: fcdproinput.h:96
+ Here is the call graph for this function:

◆ webapiRunGet()

int FCDProInput::webapiRunGet ( SWGSDRangel::SWGDeviceState response,
QString &  errorMessage 
)
virtual

Reimplemented from DeviceSampleSource.

Definition at line 829 of file fcdproinput.cpp.

References DeviceAPI::getDeviceEngineStateStr(), SWGSDRangel::SWGDeviceState::getState(), and m_deviceAPI.

832 {
833  (void) errorMessage;
835  return 200;
836 }
void getDeviceEngineStateStr(QString &state)
Definition: deviceapi.cpp:389
DeviceAPI * m_deviceAPI
Definition: fcdproinput.h:168
+ Here is the call graph for this function:

◆ webapiSettingsGet()

int FCDProInput::webapiSettingsGet ( SWGSDRangel::SWGDeviceSettings response,
QString &  errorMessage 
)
virtual

Reimplemented from DeviceSampleSource.

Definition at line 857 of file fcdproinput.cpp.

References SWGSDRangel::SWGDeviceSettings::getFcdProSettings(), SWGSDRangel::SWGFCDProSettings::init(), m_settings, SWGSDRangel::SWGDeviceSettings::setFcdProSettings(), and webapiFormatDeviceSettings().

860 {
861  (void) errorMessage;
863  response.getFcdProSettings()->init();
865  return 200;
866 }
SWGFCDProSettings * getFcdProSettings()
FCDProSettings m_settings
Definition: fcdproinput.h:173
void webapiFormatDeviceSettings(SWGSDRangel::SWGDeviceSettings &response, const FCDProSettings &settings)
void setFcdProSettings(SWGFCDProSettings *fcd_pro_settings)
+ Here is the call graph for this function:

◆ webapiSettingsPutPatch()

int FCDProInput::webapiSettingsPutPatch ( bool  force,
const QStringList &  deviceSettingsKeys,
SWGSDRangel::SWGDeviceSettings response,
QString &  errorMessage 
)
virtual

Reimplemented from DeviceSampleSource.

Definition at line 868 of file fcdproinput.cpp.

References FCDProInput::MsgConfigureFCDPro::create(), SWGSDRangel::SWGFCDProSettings::getBandIndex(), SWGSDRangel::SWGFCDProSettings::getBiasCurrentIndex(), SWGSDRangel::SWGFCDProSettings::getCenterFrequency(), SWGSDRangel::SWGFCDProSettings::getDcBlock(), SWGSDRangel::SWGDeviceSettings::getFcdProSettings(), SWGSDRangel::SWGFCDProSettings::getFcPos(), SWGSDRangel::SWGFCDProSettings::getFileRecordName(), SWGSDRangel::SWGFCDProSettings::getGain1Index(), SWGSDRangel::SWGFCDProSettings::getGain2Index(), SWGSDRangel::SWGFCDProSettings::getGain3Index(), SWGSDRangel::SWGFCDProSettings::getGain4Index(), SWGSDRangel::SWGFCDProSettings::getGain5Index(), SWGSDRangel::SWGFCDProSettings::getGain6Index(), SWGSDRangel::SWGFCDProSettings::getIfFilterIndex(), SWGSDRangel::SWGFCDProSettings::getIqCorrection(), SWGSDRangel::SWGFCDProSettings::getLnaEnhanceIndex(), SWGSDRangel::SWGFCDProSettings::getLnaGainIndex(), SWGSDRangel::SWGFCDProSettings::getLog2Decim(), SWGSDRangel::SWGFCDProSettings::getLOppmTenths(), SWGSDRangel::SWGFCDProSettings::getMixerFilterIndex(), SWGSDRangel::SWGFCDProSettings::getMixerGainIndex(), SWGSDRangel::SWGFCDProSettings::getModeIndex(), SWGSDRangel::SWGFCDProSettings::getRcFilterIndex(), SWGSDRangel::SWGFCDProSettings::getReverseApiAddress(), SWGSDRangel::SWGFCDProSettings::getReverseApiDeviceIndex(), SWGSDRangel::SWGFCDProSettings::getReverseApiPort(), SWGSDRangel::SWGFCDProSettings::getRfFilterIndex(), SWGSDRangel::SWGFCDProSettings::getTransverterDeltaFrequency(), SWGSDRangel::SWGFCDProSettings::getTransverterMode(), SWGSDRangel::SWGFCDProSettings::getUseReverseApi(), FCDProSettings::m_bandIndex, FCDProSettings::m_biasCurrentIndex, FCDProSettings::m_centerFrequency, FCDProSettings::m_dcBlock, FCDProSettings::m_fcPos, FCDProSettings::m_fileRecordName, FCDProSettings::m_gain1Index, FCDProSettings::m_gain2Index, FCDProSettings::m_gain3Index, FCDProSettings::m_gain4Index, FCDProSettings::m_gain5Index, FCDProSettings::m_gain6Index, DeviceSampleSource::m_guiMessageQueue, FCDProSettings::m_ifFilterIndex, DeviceSampleSource::m_inputMessageQueue, FCDProSettings::m_iqCorrection, FCDProSettings::m_lnaEnhanceIndex, FCDProSettings::m_lnaGainIndex, FCDProSettings::m_log2Decim, FCDProSettings::m_LOppmTenths, FCDProSettings::m_mixerFilterIndex, FCDProSettings::m_mixerGainIndex, FCDProSettings::m_modeIndex, FCDProSettings::m_rcFilterIndex, FCDProSettings::m_reverseAPIAddress, FCDProSettings::m_reverseAPIDeviceIndex, FCDProSettings::m_reverseAPIPort, FCDProSettings::m_rfFilterIndex, m_settings, FCDProSettings::m_transverterDeltaFrequency, FCDProSettings::m_transverterMode, FCDProSettings::m_useReverseAPI, MessageQueue::push(), and webapiFormatDeviceSettings().

873 {
874  (void) errorMessage;
875  FCDProSettings settings = m_settings;
876 
877  if (deviceSettingsKeys.contains("centerFrequency")) {
878  settings.m_centerFrequency = response.getFcdProSettings()->getCenterFrequency();
879  }
880  if (deviceSettingsKeys.contains("LOppmTenths")) {
881  settings.m_LOppmTenths = response.getFcdProSettings()->getLOppmTenths();
882  }
883  if (deviceSettingsKeys.contains("lnaGainIndex")) {
884  settings.m_lnaGainIndex = response.getFcdProSettings()->getLnaGainIndex();
885  }
886  if (deviceSettingsKeys.contains("rfFilterIndex")) {
887  settings.m_rfFilterIndex = response.getFcdProSettings()->getRfFilterIndex();
888  }
889  if (deviceSettingsKeys.contains("lnaEnhanceIndex")) {
890  settings.m_lnaEnhanceIndex = response.getFcdProSettings()->getLnaEnhanceIndex();
891  }
892  if (deviceSettingsKeys.contains("bandIndex")) {
893  settings.m_bandIndex = response.getFcdProSettings()->getBandIndex();
894  }
895  if (deviceSettingsKeys.contains("mixerGainIndex")) {
896  settings.m_mixerGainIndex = response.getFcdProSettings()->getMixerGainIndex();
897  }
898  if (deviceSettingsKeys.contains("mixerFilterIndex")) {
900  }
901  if (deviceSettingsKeys.contains("biasCurrentIndex")) {
903  }
904  if (deviceSettingsKeys.contains("modeIndex")) {
905  settings.m_modeIndex = response.getFcdProSettings()->getModeIndex();
906  }
907  if (deviceSettingsKeys.contains("gain1Index")) {
908  settings.m_gain1Index = response.getFcdProSettings()->getGain1Index();
909  }
910  if (deviceSettingsKeys.contains("gain2Index")) {
911  settings.m_gain2Index = response.getFcdProSettings()->getGain2Index();
912  }
913  if (deviceSettingsKeys.contains("gain3Index")) {
914  settings.m_gain3Index = response.getFcdProSettings()->getGain3Index();
915  }
916  if (deviceSettingsKeys.contains("gain4Index")) {
917  settings.m_gain4Index = response.getFcdProSettings()->getGain4Index();
918  }
919  if (deviceSettingsKeys.contains("gain5Index")) {
920  settings.m_gain5Index = response.getFcdProSettings()->getGain5Index();
921  }
922  if (deviceSettingsKeys.contains("gain6Index")) {
923  settings.m_gain6Index = response.getFcdProSettings()->getGain6Index();
924  }
925  if (deviceSettingsKeys.contains("log2Decim")) {
926  settings.m_log2Decim = response.getFcdProSettings()->getLog2Decim();
927  }
928  if (deviceSettingsKeys.contains("fcPos")) {
929  settings.m_fcPos = (FCDProSettings::fcPos_t) response.getFcdProSettings()->getFcPos();
930  }
931  if (deviceSettingsKeys.contains("rcFilterIndex")) {
932  settings.m_rcFilterIndex = response.getFcdProSettings()->getRcFilterIndex();
933  }
934  if (deviceSettingsKeys.contains("ifFilterIndex")) {
935  settings.m_ifFilterIndex = response.getFcdProSettings()->getIfFilterIndex();
936  }
937  if (deviceSettingsKeys.contains("dcBlock")) {
938  settings.m_dcBlock = response.getFcdProSettings()->getDcBlock() != 0;
939  }
940  if (deviceSettingsKeys.contains("iqCorrection")) {
941  settings.m_iqCorrection = response.getFcdProSettings()->getIqCorrection() != 0;
942  }
943  if (deviceSettingsKeys.contains("transverterDeltaFrequency")) {
945  }
946  if (deviceSettingsKeys.contains("transverterMode")) {
947  settings.m_transverterMode = response.getFcdProSettings()->getTransverterMode() != 0;
948  }
949  if (deviceSettingsKeys.contains("fileRecordName")) {
950  settings.m_fileRecordName = *response.getFcdProSettings()->getFileRecordName();
951  }
952  if (deviceSettingsKeys.contains("useReverseAPI")) {
953  settings.m_useReverseAPI = response.getFcdProSettings()->getUseReverseApi() != 0;
954  }
955  if (deviceSettingsKeys.contains("reverseAPIAddress")) {
957  }
958  if (deviceSettingsKeys.contains("reverseAPIPort")) {
959  settings.m_reverseAPIPort = response.getFcdProSettings()->getReverseApiPort();
960  }
961  if (deviceSettingsKeys.contains("reverseAPIDeviceIndex")) {
963  }
964 
965  MsgConfigureFCDPro *msg = MsgConfigureFCDPro::create(settings, force);
967 
968  if (m_guiMessageQueue) // forward to GUI if any
969  {
970  MsgConfigureFCDPro *msgToGUI = MsgConfigureFCDPro::create(settings, force);
971  m_guiMessageQueue->push(msgToGUI);
972  }
973 
974  webapiFormatDeviceSettings(response, settings);
975  return 200;
976 }
uint16_t m_reverseAPIPort
qint32 m_lnaEnhanceIndex
SWGFCDProSettings * getFcdProSettings()
void push(Message *message, bool emitSignal=true)
Push message onto queue.
qint32 m_mixerGainIndex
MessageQueue m_inputMessageQueue
Input queue to the source.
quint32 m_log2Decim
qint32 m_lnaGainIndex
qint32 m_ifFilterIndex
FCDProSettings m_settings
Definition: fcdproinput.h:173
qint64 m_transverterDeltaFrequency
uint16_t m_reverseAPIDeviceIndex
static MsgConfigureFCDPro * create(const FCDProSettings &settings, bool force)
Definition: fcdproinput.h:55
qint32 m_LOppmTenths
void webapiFormatDeviceSettings(SWGSDRangel::SWGDeviceSettings &response, const FCDProSettings &settings)
qint32 m_rfFilterIndex
MessageQueue * m_guiMessageQueue
Input message queue to the GUI.
qint32 m_mixerFilterIndex
QString m_reverseAPIAddress
QString m_fileRecordName
qint32 m_rcFilterIndex
quint64 m_centerFrequency
qint32 m_biasCurrentIndex
+ Here is the call graph for this function:

Member Data Documentation

◆ m_dev

hid_device* FCDProInput::m_dev
private

◆ m_deviceAPI

DeviceAPI* FCDProInput::m_deviceAPI
private

◆ m_deviceDescription

QString FCDProInput::m_deviceDescription
private

Definition at line 175 of file fcdproinput.h.

Referenced by getDeviceDescription().

◆ m_fcdAudioInput

AudioInput FCDProInput::m_fcdAudioInput
private

Definition at line 170 of file fcdproinput.h.

Referenced by closeFCDAudio(), and openFCDAudio().

◆ m_fcdFIFO

AudioFifo FCDProInput::m_fcdFIFO
private

Definition at line 171 of file fcdproinput.h.

Referenced by closeFCDAudio(), openFCDAudio(), and start().

◆ m_FCDThread

FCDProThread* FCDProInput::m_FCDThread
private

Definition at line 174 of file fcdproinput.h.

Referenced by applySettings(), start(), and stop().

◆ m_fileSink

FileRecord* FCDProInput::m_fileSink
private

File sink to record device I/Q output.

Definition at line 177 of file fcdproinput.h.

Referenced by applySettings(), handleMessage(), and ~FCDProInput().

◆ m_mutex

QMutex FCDProInput::m_mutex
private

Definition at line 172 of file fcdproinput.h.

◆ m_networkManager

QNetworkAccessManager* FCDProInput::m_networkManager
private

◆ m_networkRequest

QNetworkRequest FCDProInput::m_networkRequest
private

Definition at line 179 of file fcdproinput.h.

Referenced by webapiReverseSendSettings(), and webapiReverseSendStartStop().

◆ m_running

bool FCDProInput::m_running
private

Definition at line 176 of file fcdproinput.h.

Referenced by start(), stop(), and ~FCDProInput().

◆ m_settings

FCDProSettings FCDProInput::m_settings
private

The documentation for this class was generated from the following files: