Skip to content

Commit

Permalink
AudioCATSISO enhancements
Browse files Browse the repository at this point in the history
  • Loading branch information
f4exb committed Mar 25, 2024
1 parent 346ff80 commit a728563
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 4 deletions.
4 changes: 2 additions & 2 deletions plugins/samplemimo/audiocatsiso/audiocatoutputworker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

#include "audiocatoutputworker.h"

#define AUDIOOUTPUT_THROTTLE_MS 50
#define AUDIOOUTPUT_THROTTLE_MS 100

AudioCATOutputWorker::AudioCATOutputWorker(SampleMOFifo* sampleFifo, AudioFifo *fifo, QObject* parent) :
QObject(parent),
Expand All @@ -41,7 +41,7 @@ AudioCATOutputWorker::AudioCATOutputWorker(SampleMOFifo* sampleFifo, AudioFifo *
m_sampleFifo(sampleFifo),
m_audioFifo(fifo)
{
m_audioBuffer.resize(1<<15);
m_audioBuffer.resize(12000);
m_audioBufferFill = 0;
setSamplerate(48000);
}
Expand Down
2 changes: 1 addition & 1 deletion plugins/samplemimo/audiocatsiso/audiocatsiso.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ MESSAGE_CLASS_DEFINITION(AudioCATSISO::MsgStartStop, Message)
AudioCATSISO::AudioCATSISO(DeviceAPI *deviceAPI) :
m_deviceAPI(deviceAPI),
m_inputFifo(48000),
m_outputFifo(48000),
m_outputFifo(24000),
m_settings(),
m_inputWorker(nullptr),
m_outputWorker(nullptr),
Expand Down
11 changes: 10 additions & 1 deletion plugins/samplemimo/audiocatsiso/audiocatsisogui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,14 @@ void AudioCATSISOGUI::on_streamLock_toggled(bool checked)
}
}

void AudioCATSISOGUI::on_freqRxToTx_clicked()
{
m_settings.m_txCenterFrequency = m_settings.m_rxCenterFrequency;
displayFrequency();
m_settingsKeys.append("txCenterFrequency");
sendSettings();
}

void AudioCATSISOGUI::on_centerFrequency_changed(quint64 value)
{
if (m_rxElseTx)
Expand Down Expand Up @@ -771,7 +779,8 @@ void AudioCATSISOGUI::makeUIConnections()
QObject::connect(ui->streamSide, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &AudioCATSISOGUI::on_streamSide_currentIndexChanged);
QObject::connect(ui->spectrumSide, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &AudioCATSISOGUI::on_spectrumSide_currentIndexChanged);
QObject::connect(ui->streamLock, &QToolButton::toggled, this, &AudioCATSISOGUI::on_streamLock_toggled);
QObject::connect(ui->startStop, &ButtonSwitch::toggled, this, &AudioCATSISOGUI::on_startStop_toggled);
QObject::connect(ui->freqRxToTx, &QPushButton::clicked, this, &AudioCATSISOGUI::on_freqRxToTx_clicked);
QObject::connect(ui->startStop, &ButtonSwitch::toggled, this, &AudioCATSISOGUI::on_startStop_toggled);
QObject::connect(ui->ptt, &ButtonSwitch::toggled, this, &AudioCATSISOGUI::on_ptt_toggled);
QObject::connect(ui->catConnect, &ButtonSwitch::toggled, this, &AudioCATSISOGUI::on_catConnect_toggled);
QObject::connect(ui->centerFrequency, &ValueDial::changed, this, &AudioCATSISOGUI::on_centerFrequency_changed);
Expand Down
1 change: 1 addition & 0 deletions plugins/samplemimo/audiocatsiso/audiocatsisogui.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ private slots:
void on_streamSide_currentIndexChanged(int index);
void on_spectrumSide_currentIndexChanged(int index);
void on_streamLock_toggled(bool checked);
void on_freqRxToTx_clicked();
void on_startStop_toggled(bool checked);
void on_ptt_toggled(bool checked);
void on_pttSpectrumLinkToggled(bool checked);
Expand Down
17 changes: 17 additions & 0 deletions plugins/samplemimo/audiocatsiso/audiocatsisogui.ui
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,23 @@
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="freqRxToTx">
<property name="toolTip">
<string>Send Rx frequency to Tx</string>
</property>
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../../../sdrgui/resources/res.qrc">
<normaloff>:/arrow_left.png</normaloff>:/arrow_left.png</iconset>
</property>
<property name="checkable">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="ButtonSwitch" name="txEnable">
<property name="toolTip">
Expand Down

0 comments on commit a728563

Please sign in to comment.