diff --git a/plugins/channel/bfm/bfmdemod.cpp b/plugins/channel/bfm/bfmdemod.cpp
index 80a9ac6cc..47d19d721 100644
--- a/plugins/channel/bfm/bfmdemod.cpp
+++ b/plugins/channel/bfm/bfmdemod.cpp
@@ -75,9 +75,16 @@ void BFMDemod::configure(MessageQueue* messageQueue,
Real volume,
Real squelch,
bool audioStereo,
- bool showPilot)
+ bool showPilot,
+ bool rdsActive)
{
- Message* cmd = MsgConfigureBFMDemod::create(rfBandwidth, afBandwidth, volume, squelch, audioStereo, showPilot);
+ Message* cmd = MsgConfigureBFMDemod::create(rfBandwidth,
+ afBandwidth,
+ volume,
+ squelch,
+ audioStereo,
+ showPilot,
+ rdsActive);
messageQueue->push(cmd);
}
@@ -256,6 +263,7 @@ bool BFMDemod::handleMessage(const Message& cmd)
m_config.m_squelch = cfg.getSquelch();
m_config.m_audioStereo = cfg.getAudioStereo();
m_config.m_showPilot = cfg.getShowPilot();
+ m_config.m_rdsActive = cfg.getRDSActive();
apply();
@@ -264,7 +272,8 @@ bool BFMDemod::handleMessage(const Message& cmd)
<< " m_volume: " << m_config.m_volume
<< " m_squelch: " << m_config.m_squelch
<< " m_audioStereo: " << m_config.m_audioStereo
- << " m_showPilot: " << m_config.m_showPilot;
+ << " m_showPilot: " << m_config.m_showPilot
+ << " m_rdsActive: " << m_config.m_rdsActive;
return true;
}
@@ -356,5 +365,5 @@ void BFMDemod::apply()
m_running.m_audioSampleRate = m_config.m_audioSampleRate;
m_running.m_audioStereo = m_config.m_audioStereo;
m_running.m_showPilot = m_config.m_showPilot;
-
+ m_running.m_rdsActive = m_config.m_rdsActive;
}
diff --git a/plugins/channel/bfm/bfmdemod.h b/plugins/channel/bfm/bfmdemod.h
index d63be9c27..5b44a0d49 100644
--- a/plugins/channel/bfm/bfmdemod.h
+++ b/plugins/channel/bfm/bfmdemod.h
@@ -44,7 +44,8 @@ public:
Real volume,
Real squelch,
bool audioStereo,
- bool showPilot);
+ bool showPilot,
+ bool rdsActive);
int getSampleRate() const { return m_config.m_inputSampleRate; }
virtual void feed(const SampleVector::const_iterator& begin, const SampleVector::const_iterator& end, bool po);
@@ -67,15 +68,23 @@ private:
Real getSquelch() const { return m_squelch; }
bool getAudioStereo() const { return m_audioStereo; }
bool getShowPilot() const { return m_showPilot; }
+ bool getRDSActive() const { return m_rdsActive; }
static MsgConfigureBFMDemod* create(Real rfBandwidth,
Real afBandwidth,
Real volume,
Real squelch,
bool audioStereo,
- bool showPilot)
+ bool showPilot,
+ bool rdsActive)
{
- return new MsgConfigureBFMDemod(rfBandwidth, afBandwidth, volume, squelch, audioStereo, showPilot);
+ return new MsgConfigureBFMDemod(rfBandwidth,
+ afBandwidth,
+ volume,
+ squelch,
+ audioStereo,
+ showPilot,
+ rdsActive);
}
private:
@@ -85,20 +94,23 @@ private:
Real m_squelch;
bool m_audioStereo;
bool m_showPilot;
+ bool m_rdsActive;
MsgConfigureBFMDemod(Real rfBandwidth,
Real afBandwidth,
Real volume,
Real squelch,
bool audioStereo,
- bool showPilot) :
+ bool showPilot,
+ bool rdsActive) :
Message(),
m_rfBandwidth(rfBandwidth),
m_afBandwidth(afBandwidth),
m_volume(volume),
m_squelch(squelch),
m_audioStereo(audioStereo),
- m_showPilot(showPilot)
+ m_showPilot(showPilot),
+ m_rdsActive(rdsActive)
{ }
};
@@ -123,6 +135,7 @@ private:
quint32 m_audioSampleRate;
bool m_audioStereo;
bool m_showPilot;
+ bool m_rdsActive;
Config() :
m_inputSampleRate(-1),
@@ -133,7 +146,8 @@ private:
m_volume(0),
m_audioSampleRate(0),
m_audioStereo(false),
- m_showPilot(false)
+ m_showPilot(false),
+ m_rdsActive(false)
{ }
};
diff --git a/plugins/channel/bfm/bfmdemodgui.cpp b/plugins/channel/bfm/bfmdemodgui.cpp
index 8fef0db39..266a6c7d2 100644
--- a/plugins/channel/bfm/bfmdemodgui.cpp
+++ b/plugins/channel/bfm/bfmdemodgui.cpp
@@ -243,6 +243,11 @@ void BFMDemodGUI::on_showPilot_clicked()
applySettings();
}
+void BFMDemodGUI::on_rds_clicked()
+{
+ applySettings();
+}
+
void BFMDemodGUI::onWidgetRolled(QWidget* widget, bool rollDown)
{
}
@@ -338,7 +343,8 @@ void BFMDemodGUI::applySettings()
ui->volume->value() / 10.0,
ui->squelch->value(),
ui->audioStereo->isChecked(),
- ui->showPilot->isChecked());
+ ui->showPilot->isChecked(),
+ ui->rds->isChecked());
}
}
diff --git a/plugins/channel/bfm/bfmdemodgui.h b/plugins/channel/bfm/bfmdemodgui.h
index 4aaad51c1..9b9b9e45d 100644
--- a/plugins/channel/bfm/bfmdemodgui.h
+++ b/plugins/channel/bfm/bfmdemodgui.h
@@ -63,6 +63,7 @@ private slots:
void on_squelch_valueChanged(int value);
void on_audioStereo_toggled(bool stereo);
void on_showPilot_clicked();
+ void on_rds_clicked();
void onWidgetRolled(QWidget* widget, bool rollDown);
void onMenuDoubleClicked();
void tick();
diff --git a/plugins/channel/bfm/bfmdemodgui.ui b/plugins/channel/bfm/bfmdemodgui.ui
index 396c00e4a..0c1e2c0ad 100644
--- a/plugins/channel/bfm/bfmdemodgui.ui
+++ b/plugins/channel/bfm/bfmdemodgui.ui
@@ -6,7 +6,7 @@
0
0
- 308
+ 335
333
@@ -21,7 +21,7 @@
10
20
- 281
+ 311
121
@@ -203,6 +203,20 @@
+ -
+
+
+ Toggle RDS subsystem activation
+
+
+ .
+
+
+
+ :/rds.png:/rds.png
+
+
+
@@ -386,12 +400,12 @@
10
160
- 281
+ 311
151
- Channel Spectrum
+ Baseband Spectrum
diff --git a/sdrbase/resources/rds.png b/sdrbase/resources/rds.png
new file mode 100644
index 000000000..405c04ab5
Binary files /dev/null and b/sdrbase/resources/rds.png differ
diff --git a/sdrbase/resources/res.qrc b/sdrbase/resources/res.qrc
index 03ce4800e..cd631d96d 100644
--- a/sdrbase/resources/res.qrc
+++ b/sdrbase/resources/res.qrc
@@ -46,5 +46,6 @@
flip_lr.png
flip_rl.png
carrier.png
+ rds.png