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.
Public Member Functions | Private Slots | Private Attributes | List of all members
BasicDeviceSettingsDialog Class Reference

#include <basicdevicesettingsdialog.h>

Inherits QDialog.

Public Member Functions

 BasicDeviceSettingsDialog (QWidget *parent=0)
 
 ~BasicDeviceSettingsDialog ()
 
bool hasChanged () const
 
bool useReverseAPI () const
 
const QString & getReverseAPIAddress () const
 
uint16_t getReverseAPIPort () const
 
uint16_t getReverseAPIDeviceIndex () const
 
void setUseReverseAPI (bool useReverseAPI)
 
void setReverseAPIAddress (const QString &address)
 
void setReverseAPIPort (uint16_t port)
 
void setReverseAPIDeviceIndex (uint16_t deviceIndex)
 

Private Slots

void on_reverseAPI_toggled (bool checked)
 
void on_reverseAPIAddress_editingFinished ()
 
void on_reverseAPIPort_editingFinished ()
 
void on_reverseAPIDeviceIndex_editingFinished ()
 
void accept ()
 

Private Attributes

Ui::BasicDeviceSettingsDialog * ui
 
bool m_useReverseAPI
 
QString m_reverseAPIAddress
 
uint16_t m_reverseAPIPort
 
uint16_t m_reverseAPIDeviceIndex
 
bool m_hasChanged
 

Detailed Description

Definition at line 12 of file basicdevicesettingsdialog.h.

Constructor & Destructor Documentation

◆ BasicDeviceSettingsDialog()

BasicDeviceSettingsDialog::BasicDeviceSettingsDialog ( QWidget *  parent = 0)
explicit

Definition at line 4 of file basicdevicesettingsdialog.cpp.

References setReverseAPIAddress(), setReverseAPIDeviceIndex(), setReverseAPIPort(), setUseReverseAPI(), and ui.

4  :
5  QDialog(parent),
6  ui(new Ui::BasicDeviceSettingsDialog),
7  m_hasChanged(false)
8 {
9  ui->setupUi(this);
10  setUseReverseAPI(false);
11  setReverseAPIAddress("127.0.0.1");
12  setReverseAPIPort(8888);
14 }
void setUseReverseAPI(bool useReverseAPI)
Ui::BasicDeviceSettingsDialog * ui
void setReverseAPIAddress(const QString &address)
void setReverseAPIDeviceIndex(uint16_t deviceIndex)
+ Here is the call graph for this function:

◆ ~BasicDeviceSettingsDialog()

BasicDeviceSettingsDialog::~BasicDeviceSettingsDialog ( )

Definition at line 16 of file basicdevicesettingsdialog.cpp.

References ui.

17 {
18  delete ui;
19 }
Ui::BasicDeviceSettingsDialog * ui

Member Function Documentation

◆ accept

void BasicDeviceSettingsDialog::accept ( )
privateslot

Definition at line 84 of file basicdevicesettingsdialog.cpp.

References m_hasChanged.

85 {
86  m_hasChanged = true;
87  QDialog::accept();
88 }

◆ getReverseAPIAddress()

const QString& BasicDeviceSettingsDialog::getReverseAPIAddress ( ) const
inline

Definition at line 21 of file basicdevicesettingsdialog.h.

Referenced by KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

+ Here is the caller graph for this function:

◆ getReverseAPIDeviceIndex()

uint16_t BasicDeviceSettingsDialog::getReverseAPIDeviceIndex ( ) const
inline

Definition at line 23 of file basicdevicesettingsdialog.h.

Referenced by KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

+ Here is the caller graph for this function:

◆ getReverseAPIPort()

uint16_t BasicDeviceSettingsDialog::getReverseAPIPort ( ) const
inline

Definition at line 22 of file basicdevicesettingsdialog.h.

Referenced by KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

+ Here is the caller graph for this function:

◆ hasChanged()

bool BasicDeviceSettingsDialog::hasChanged ( ) const
inline

Definition at line 19 of file basicdevicesettingsdialog.h.

◆ on_reverseAPI_toggled

void BasicDeviceSettingsDialog::on_reverseAPI_toggled ( bool  checked)
privateslot

Definition at line 50 of file basicdevicesettingsdialog.cpp.

References m_useReverseAPI.

51 {
52  m_useReverseAPI = checked;
53 }

◆ on_reverseAPIAddress_editingFinished

void BasicDeviceSettingsDialog::on_reverseAPIAddress_editingFinished ( )
privateslot

Definition at line 55 of file basicdevicesettingsdialog.cpp.

References m_reverseAPIAddress, and ui.

56 {
57  m_reverseAPIAddress = ui->reverseAPIAddress->text();
58 }
Ui::BasicDeviceSettingsDialog * ui

◆ on_reverseAPIDeviceIndex_editingFinished

void BasicDeviceSettingsDialog::on_reverseAPIDeviceIndex_editingFinished ( )
privateslot

Definition at line 72 of file basicdevicesettingsdialog.cpp.

References m_reverseAPIDeviceIndex, and ui.

73 {
74  bool dataOk;
75  int reverseAPIDeviceIndex = ui->reverseAPIDeviceIndex->text().toInt(&dataOk);
76 
77  if ((!dataOk) || (reverseAPIDeviceIndex < 0)) {
78  return;
79  } else {
80  m_reverseAPIDeviceIndex = reverseAPIDeviceIndex;
81  }
82 }
Ui::BasicDeviceSettingsDialog * ui

◆ on_reverseAPIPort_editingFinished

void BasicDeviceSettingsDialog::on_reverseAPIPort_editingFinished ( )
privateslot

Definition at line 60 of file basicdevicesettingsdialog.cpp.

References m_reverseAPIPort, and ui.

61 {
62  bool dataOk;
63  int reverseAPIPort = ui->reverseAPIPort->text().toInt(&dataOk);
64 
65  if((!dataOk) || (reverseAPIPort < 1024) || (reverseAPIPort > 65535)) {
66  return;
67  } else {
68  m_reverseAPIPort = reverseAPIPort;
69  }
70 }
Ui::BasicDeviceSettingsDialog * ui

◆ setReverseAPIAddress()

void BasicDeviceSettingsDialog::setReverseAPIAddress ( const QString &  address)

Definition at line 27 of file basicdevicesettingsdialog.cpp.

References m_reverseAPIAddress, and ui.

Referenced by BasicDeviceSettingsDialog(), KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

28 {
29  m_reverseAPIAddress = address;
30  ui->reverseAPIAddress->setText(m_reverseAPIAddress);
31 }
Ui::BasicDeviceSettingsDialog * ui
+ Here is the caller graph for this function:

◆ setReverseAPIDeviceIndex()

void BasicDeviceSettingsDialog::setReverseAPIDeviceIndex ( uint16_t  deviceIndex)

Definition at line 44 of file basicdevicesettingsdialog.cpp.

References arg(), m_reverseAPIDeviceIndex, and ui.

Referenced by BasicDeviceSettingsDialog(), KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

45 {
46  m_reverseAPIDeviceIndex = deviceIndex > 99 ? 99 : deviceIndex;
47  ui->reverseAPIDeviceIndex->setText(tr("%1").arg(m_reverseAPIDeviceIndex));
48 }
Ui::BasicDeviceSettingsDialog * ui
Fixed< IntType, IntBits > arg(const std::complex< Fixed< IntType, IntBits > > &val)
Definition: fixed.h:2401
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setReverseAPIPort()

void BasicDeviceSettingsDialog::setReverseAPIPort ( uint16_t  port)

Definition at line 33 of file basicdevicesettingsdialog.cpp.

References arg(), m_reverseAPIPort, and ui.

Referenced by BasicDeviceSettingsDialog(), KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

34 {
35  if (port < 1024) {
36  return;
37  } else {
38  m_reverseAPIPort = port;
39  }
40 
41  ui->reverseAPIPort->setText(tr("%1").arg(m_reverseAPIPort));
42 }
Ui::BasicDeviceSettingsDialog * ui
Fixed< IntType, IntBits > arg(const std::complex< Fixed< IntType, IntBits > > &val)
Definition: fixed.h:2401
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setUseReverseAPI()

void BasicDeviceSettingsDialog::setUseReverseAPI ( bool  useReverseAPI)

Definition at line 21 of file basicdevicesettingsdialog.cpp.

References m_useReverseAPI, ui, and useReverseAPI().

Referenced by BasicDeviceSettingsDialog(), KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), and RemoteOutputSinkGui::openDeviceSettingsDialog().

22 {
24  ui->reverseAPI->setChecked(m_useReverseAPI);
25 }
Ui::BasicDeviceSettingsDialog * ui
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ useReverseAPI()

bool BasicDeviceSettingsDialog::useReverseAPI ( ) const
inline

Definition at line 20 of file basicdevicesettingsdialog.h.

Referenced by KiwiSDRGui::openDeviceSettingsDialog(), Bladerf1OutputGui::openDeviceSettingsDialog(), BladeRF2OutputGui::openDeviceSettingsDialog(), LocalOutputGui::openDeviceSettingsDialog(), FCDProPlusGui::openDeviceSettingsDialog(), PerseusGui::openDeviceSettingsDialog(), Bladerf1InputGui::openDeviceSettingsDialog(), SDRPlayGui::openDeviceSettingsDialog(), AirspyGui::openDeviceSettingsDialog(), PlutoSDROutputGUI::openDeviceSettingsDialog(), BladeRF2InputGui::openDeviceSettingsDialog(), XTRXOutputGUI::openDeviceSettingsDialog(), RTLSDRGui::openDeviceSettingsDialog(), AirspyHFGui::openDeviceSettingsDialog(), FileInputGUI::openDeviceSettingsDialog(), LimeSDROutputGUI::openDeviceSettingsDialog(), TestSourceGui::openDeviceSettingsDialog(), HackRFOutputGui::openDeviceSettingsDialog(), LimeSDRInputGUI::openDeviceSettingsDialog(), TestMIGui::openDeviceSettingsDialog(), HackRFInputGui::openDeviceSettingsDialog(), PlutoSDRInputGui::openDeviceSettingsDialog(), XTRXInputGUI::openDeviceSettingsDialog(), FCDProGui::openDeviceSettingsDialog(), LocalInputGui::openDeviceSettingsDialog(), RemoteInputGui::openDeviceSettingsDialog(), SoapySDROutputGui::openDeviceSettingsDialog(), SoapySDRInputGui::openDeviceSettingsDialog(), RemoteOutputSinkGui::openDeviceSettingsDialog(), and setUseReverseAPI().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_hasChanged

bool BasicDeviceSettingsDialog::m_hasChanged
private

Definition at line 42 of file basicdevicesettingsdialog.h.

Referenced by accept().

◆ m_reverseAPIAddress

QString BasicDeviceSettingsDialog::m_reverseAPIAddress
private

◆ m_reverseAPIDeviceIndex

uint16_t BasicDeviceSettingsDialog::m_reverseAPIDeviceIndex
private

◆ m_reverseAPIPort

uint16_t BasicDeviceSettingsDialog::m_reverseAPIPort
private

◆ m_useReverseAPI

bool BasicDeviceSettingsDialog::m_useReverseAPI
private

Definition at line 38 of file basicdevicesettingsdialog.h.

Referenced by on_reverseAPI_toggled(), and setUseReverseAPI().

◆ ui

Ui::BasicDeviceSettingsDialog* BasicDeviceSettingsDialog::ui
private

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