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.
freqtrackergui.h
Go to the documentation of this file.
1 // Copyright (C) 2019 Edouard Griffiths, F4EXB. //
3 // //
4 // This program is free software; you can redistribute it and/or modify //
5 // it under the terms of the GNU General Public License as published by //
6 // the Free Software Foundation as version 3 of the License, or //
7 // (at your option) any later version. //
8 // //
9 // This program is distributed in the hope that it will be useful, //
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of //
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
12 // GNU General Public License V3 for more details. //
13 // //
14 // You should have received a copy of the GNU General Public License //
15 // along with this program. If not, see <http://www.gnu.org/licenses/>. //
17 
18 #ifndef INCLUDE_FREQTRACKERGUI_H
19 #define INCLUDE_FREQTRACKERGUI_H
20 
21 #include <QIcon>
22 
24 #include "gui/rollupwidget.h"
25 #include "dsp/channelmarker.h"
26 #include "dsp/movingaverage.h"
27 #include "util/messagequeue.h"
28 #include "freqtrackersettings.h"
29 
30 class PluginAPI;
31 class DeviceUISet;
32 
33 class FreqTracker;
34 class BasebandSampleSink;
35 
36 namespace Ui {
37  class FreqTrackerGUI;
38 }
39 
41  Q_OBJECT
42 
43 public:
44  static FreqTrackerGUI* create(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, 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::FreqTrackerGUI* ui;
70 
75 
76  explicit FreqTrackerGUI(PluginAPI* pluginAPI, DeviceUISet *deviceUISet, BasebandSampleSink *rxChannel, QWidget* parent = 0);
77  virtual ~FreqTrackerGUI();
78 
79  void blockApplySettings(bool block);
80  void applySettings(bool force = false);
81  void displaySettings();
82 
83  void leaveEvent(QEvent*);
84  void enterEvent(QEvent*);
85 
86 private slots:
87  void on_deltaFrequency_changed(qint64 value);
88  void on_log2Decim_currentIndexChanged(int index);
89  void on_rfBW_valueChanged(int value);
90  void on_tracking_toggled(bool checked);
91  void on_alphaEMA_valueChanged(int value);
92  void on_trackerType_currentIndexChanged(int index);
93  void on_pllPskOrder_currentIndexChanged(int index);
94  void on_rrc_toggled(bool checked);
95  void on_rrcRolloff_valueChanged(int value);
96  void on_squelch_valueChanged(int value);
97  void on_squelchGate_valueChanged(int value);
98  void onWidgetRolled(QWidget* widget, bool rollDown);
99  void onMenuDialogCalled(const QPoint& p);
100  void handleInputMessages();
101  void tick();
102 };
103 
104 #endif // INCLUDE_FREQTRACKERGUI_H
Ui::FreqTrackerGUI * ui
FreqTrackerSettings m_settings
MessageQueue m_inputMessageQueue
unsigned int uint32_t
Definition: rtptypes_win.h:46
DeviceUISet * m_deviceUISet
FreqTracker * m_freqTracker
void * create(QString type)
virtual MessageQueue * getInputMessageQueue()
uint32_t m_tickCount
PluginAPI * m_pluginAPI
ChannelMarker m_channelMarker