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.
devicebladerf2shared.h
Go to the documentation of this file.
1 // Copyright (C) 2018 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 DEVICES_BLADERF2_DEVICEBLADERF2SHARED_H_
19 #define DEVICES_BLADERF2_DEVICEBLADERF2SHARED_H_
20 
21 #include "util/message.h"
22 #include "devicebladerf2.h"
23 
24 class SampleSinkFifo;
25 class SampleSourceFifo;
26 class BladeRF2Input;
27 class BladeRF2Output;
28 
33 {
34 public:
37 
38  public:
39  uint64_t getCenterFrequency() const { return m_centerFrequency; }
40  int getLOppmTenths() const { return m_LOppmTenths; }
41  int getFcPos() const { return m_fcPos; }
42  int getDevSampleRate() const { return m_devSampleRate; }
43  bool getRxElseTx() const { return m_rxElseTx; }
44 
46  uint64_t centerFrequency,
47  int LOppmTenths,
48  int fcPos,
49  int devSampleRate,
50  bool rxElseTx)
51  {
52  return new MsgReportBuddyChange(
53  centerFrequency,
54  LOppmTenths,
55  fcPos,
56  devSampleRate,
57  rxElseTx);
58  }
59 
60  private:
63  int m_fcPos;
65  bool m_rxElseTx;
66 
68  uint64_t centerFrequency,
69  int LOppmTenths,
70  int fcPos,
71  int devSampleRate,
72  bool rxElseTx) :
73  Message(),
74  m_centerFrequency(centerFrequency),
75  m_LOppmTenths(LOppmTenths),
76  m_fcPos(fcPos),
77  m_devSampleRate(devSampleRate),
78  m_rxElseTx(rxElseTx)
79  { }
80  };
81 
84 
86  int m_channel;
89 
90  static const float m_sampleFifoLengthInSeconds;
91  static const int m_sampleFifoMinSize;
92  static const int m_sampleFifoMinSize32;
93 };
94 
95 
96 
97 #endif /* DEVICES_BLADERF2_DEVICEBLADERF2SHARED_H_ */
static const float m_sampleFifoLengthInSeconds
static const int m_sampleFifoMinSize
MsgReportBuddyChange(uint64_t centerFrequency, int LOppmTenths, int fcPos, int devSampleRate, bool rxElseTx)
#define DEVICES_API
Definition: export.h:76
static const int m_sampleFifoMinSize32
#define MESSAGE_CLASS_DECLARATION
Definition: message.h:43
int m_LOppmTenths
LO soft correction in tenths of ppm.
bool m_rxElseTx
tells which side initiated the message
static MsgReportBuddyChange * create(uint64_t centerFrequency, int LOppmTenths, int fcPos, int devSampleRate, bool rxElseTx)
int m_channel
allocated channel (-1 if none)
unsigned __int64 uint64_t
Definition: rtptypes_win.h:48