kopia lustrzana https://github.com/PianetaRadio/CatRadio
rodzic
c0d66fba54
commit
25e13f79d4
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE QtCreatorProject>
|
||||
<!-- Written by QtCreator 6.0.2, 2022-03-26T20:32:42. -->
|
||||
<!-- Written by QtCreator 6.0.2, 2022-03-27T13:55:03. -->
|
||||
<qtcreator>
|
||||
<data>
|
||||
<variable>EnvironmentId</variable>
|
||||
|
|
|
@ -447,6 +447,7 @@ void MainWindow::guiUpdate()
|
|||
if (rigGet.rptShift == RIG_RPT_SHIFT_MINUS) ui->radioButton_RPTshiftMinus->setChecked(true); //-
|
||||
else if (rigGet.rptShift == RIG_RPT_SHIFT_PLUS) ui->radioButton_RPTshiftPlus->setChecked(true); //+
|
||||
else ui->radioButton_RPTshiftSimplex->setChecked(true); //Simplex
|
||||
ui->spinBox_RPToffset->setValue(rigGet.rptOffset/1000); //Offset (kHz)
|
||||
|
||||
ui->comboBox_toneType->setCurrentIndex(rigGet.toneType);
|
||||
if (rigGet.toneType == 2 || rigGet.toneType ==3) ui->comboBox_toneFreq->setCurrentText(QString::number(rigGet.tone/10.0)); //CTCSS
|
||||
|
@ -920,6 +921,11 @@ void MainWindow::on_spinBox_WPM_valueChanged(int arg1)
|
|||
rigCmd.wpm = 1;
|
||||
}
|
||||
|
||||
void MainWindow::on_spinBox_RPToffset_valueChanged(int arg1)
|
||||
{
|
||||
rigSet.rptOffset = arg1*1000;
|
||||
rigCmd.rptOffset = 1;
|
||||
}
|
||||
|
||||
//***** Slider *****
|
||||
|
||||
|
|
|
@ -156,6 +156,8 @@ private slots:
|
|||
|
||||
void on_comboBox_toneFreq_activated(int index);
|
||||
|
||||
void on_spinBox_RPToffset_valueChanged(int arg1);
|
||||
|
||||
private:
|
||||
Ui::MainWindow *ui;
|
||||
QTimer *timer;
|
||||
|
|
|
@ -52,6 +52,9 @@
|
|||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<property name="bottomMargin">
|
||||
<number>10</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_Connect">
|
||||
<property name="text">
|
||||
|
@ -1469,7 +1472,7 @@
|
|||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout_3">
|
||||
<item row="0" column="0" colspan="2">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3" stretch="0,0,0,0,1">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_RPTshift">
|
||||
<property name="text">
|
||||
|
@ -1501,10 +1504,17 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QSpinBox" name="spinBox_RPToffset">
|
||||
<property name="maximum">
|
||||
<number>10000</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item row="1" column="0" colspan="2">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2" stretch="0,1,1,1">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_tone">
|
||||
<property name="text">
|
||||
|
@ -1515,11 +1525,24 @@
|
|||
<item>
|
||||
<widget class="QComboBox" name="comboBox_toneType"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="comboBox_toneFreq"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QComboBox" name="comboBox_toneFreq"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
|
|
|
@ -430,6 +430,13 @@ void RigDaemon::rigUpdate()
|
|||
if (retcode == RIG_OK) rigGet.rptShift = rigSet.rptShift;
|
||||
rigCmd.rptShift = 0;
|
||||
}
|
||||
//* Repeater offset
|
||||
if (rigCmd.rptOffset)
|
||||
{
|
||||
retcode = rig_set_rptr_offs(my_rig, RIG_VFO_CURR, rigSet.rptOffset);
|
||||
if (retcode == RIG_OK) rigGet.rptOffset = rigSet.rptOffset;
|
||||
rigCmd.rptOffset = 0;
|
||||
}
|
||||
//* Tone
|
||||
if (rigCmd.tone)
|
||||
{
|
||||
|
@ -597,6 +604,7 @@ void RigDaemon::rigUpdate()
|
|||
if ((commandPriority == 17 && !rigGet.ptt && rigCom.fullPoll) || commandPriority == 0) //&& mode=FM
|
||||
{
|
||||
rig_get_rptr_shift(my_rig, RIG_VFO_CURR, &rigGet.rptShift); //Repeater Shift
|
||||
rig_get_rptr_offs(my_rig, RIG_VFO_CURR, &rigGet.rptOffset); //Repeater Offset
|
||||
|
||||
int status = false;
|
||||
if (!(my_rig->caps->has_get_func & RIG_FUNC_TONE)) status = 1; //If get cap is not available skip
|
||||
|
|
|
@ -39,7 +39,7 @@ typedef struct {
|
|||
|
||||
typedef struct {
|
||||
powerstat_t onoff; //on/off status
|
||||
freq_t freqMain, freqSub; //Frequency
|
||||
freq_t freqMain, freqSub; //Frequency (Hz)
|
||||
rmode_t mode, modeSub; //Mode
|
||||
pbwidth_t bwidth, bwidthSub; //IF filter bandwidth
|
||||
int bwNarrow; //IF narrow filter
|
||||
|
@ -69,7 +69,8 @@ typedef struct {
|
|||
int notchFilter;
|
||||
int ifShift;
|
||||
rptr_shift_t rptShift; //Repeater shift
|
||||
int toneType; //0 none, 1 burst 1750, 2 CTCSS, 3 CTCSS SQL, 4 DCS, 5 DCS SQL
|
||||
shortfreq_t rptOffset; //Repeater offset (Hz)
|
||||
int toneType; //0 none, 1 burst 1750, 2 CTCSS, 3 CTCSS SQL, 4 DCS
|
||||
tone_t tone; //CTCSS or DCS tone
|
||||
} rigSettings;
|
||||
|
||||
|
@ -104,7 +105,7 @@ typedef struct {
|
|||
int noiseReduction, noiseReductionLevel;
|
||||
int notchFilter;
|
||||
int ifShift;
|
||||
int rptShift;
|
||||
int rptShift, rptOffset;
|
||||
int tone;
|
||||
int antList;
|
||||
int rangeList;
|
||||
|
|
Ładowanie…
Reference in New Issue