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.
bfmdemodgui.h
Go to the documentation of this file.
1 // Copyright (C) 2015 F4EXB //
3 // written by Edouard Griffiths //
4 // //
5 // This program is free software; you can redistribute it and/or modify //
6 // it under the terms of the GNU General Public License as published by //
7 // the Free Software Foundation as version 3 of the License, or //
8 // (at your option) any later version. //
9 // //
10 // This program is distributed in the hope that it will be useful, //
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of //
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
13 // GNU General Public License V3 for more details. //
14 // //
15 // You should have received a copy of the GNU General Public License //
16 // along with this program. If not, see <http://www.gnu.org/licenses/>. //
18 
19 #ifndef INCLUDE_BFMDEMODGUI_H
20 #define INCLUDE_BFMDEMODGUI_H
21 
23 #include "gui/rollupwidget.h"
24 #include "dsp/channelmarker.h"
25 #include "util/messagequeue.h"
26 #include "bfmdemodsettings.h"
27 
28 class PluginAPI;
29 class DeviceUISet;
30 class RDSParser;
31 
32 class SpectrumVis;
33 class BFMDemod;
34 class BasebandSampleSink;
35 
36 namespace Ui {
37  class BFMDemodGUI;
38 }
39 
40 class BFMDemodGUI : public RollupWidget, public PluginInstanceGUI {
41  Q_OBJECT
42 
43 public:
44  static BFMDemodGUI* create(PluginAPI* pluginAPI, DeviceUISet *deviceAPI, BasebandSampleSink *rxChannel);
45  virtual void destroy();
46 
47  void setName(const QString& name);
48  QString getName() const;
49  virtual qint64 getCenterFrequency() const;
50  virtual void setCenterFrequency(qint64 centerFrequency);
51 
52  void resetToDefaults();
53  QByteArray serialize() const;
54  bool deserialize(const QByteArray& data);
55  virtual MessageQueue *getInputMessageQueue() { return &m_inputMessageQueue; }
56  virtual bool handleMessage(const Message& message);
57 
58 public slots:
59  void channelMarkerChangedByCursor();
60  void channelMarkerHighlightedByCursor();
61 
62 private:
63  Ui::BFMDemodGUI* ui;
70 
72 
74  int m_rate;
75  std::vector<unsigned int> m_g14ComboIndex;
77 
78  explicit BFMDemodGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSampleSink *rxChannel, QWidget* parent = 0);
79  virtual ~BFMDemodGUI();
80 
81  void blockApplySettings(bool block);
82  void applySettings(bool force = false);
83  void displaySettings();
84  void rdsUpdate(bool force);
85  void rdsUpdateFixedFields();
86 
87  void leaveEvent(QEvent*);
88  void enterEvent(QEvent*);
89 
90  void changeFrequency(qint64 f);
91 
92 private slots:
93  void on_deltaFrequency_changed(qint64 value);
94  void on_rfBW_valueChanged(int value);
95  void on_afBW_valueChanged(int value);
96  void on_volume_valueChanged(int value);
97  void on_squelch_valueChanged(int value);
98  void on_audioStereo_toggled(bool stereo);
99  void on_lsbStereo_toggled(bool lsb);
100  void on_showPilot_clicked();
101  void on_rds_clicked();
102  void on_g14ProgServiceNames_currentIndexChanged(int index);
103  void on_clearData_clicked(bool checked);
104  void on_g00AltFrequenciesBox_activated(int index);
105  void on_g14MappedFrequencies_activated(int index);
106  void on_g14AltFrequencies_activated(int index);
107  void onWidgetRolled(QWidget* widget, bool rollDown);
108  void onMenuDialogCalled(const QPoint& p);
109  void handleInputMessages();
110  void audioSelect();
111  void tick();
112 };
113 
114 #endif // INCLUDE_BFMDEMODGUI_H
std::vector< unsigned int > m_g14ComboIndex
Definition: bfmdemodgui.h:75
BFMDemod * m_bfmDemod
Definition: bfmdemodgui.h:73
int m_rdsTimerCount
Definition: bfmdemodgui.h:69
bool m_doApplySettings
Definition: bfmdemodgui.h:68
BFMDemodSettings m_settings
Definition: bfmdemodgui.h:67
MessageQueue m_inputMessageQueue
Definition: bfmdemodgui.h:76
ChannelMarker m_channelMarker
Definition: bfmdemodgui.h:66
void * create(QString type)
virtual MessageQueue * getInputMessageQueue()
Definition: bfmdemodgui.h:55
DeviceUISet * m_deviceUISet
Definition: bfmdemodgui.h:65
PluginAPI * m_pluginAPI
Definition: bfmdemodgui.h:64
SpectrumVis * m_spectrumVis
Definition: bfmdemodgui.h:71
Ui::BFMDemodGUI * ui
Definition: bfmdemodgui.h:63