libcyberradio  22.01.24
TransmitterComponent.cpp
1 /***************************************************************************
2  * \file TransmitterComponent.cpp
3  * \brief Defines the transmitter interface for the NDR651.
4  * \author DA
5  * \author NH
6  * \author MN
7  * \copyright (c) 2017 CyberRadio Solutions, Inc. All rights reserved.
8  *
9  ***************************************************************************/
10 
11 #include "LibCyberRadio/Driver/NDR651/CWToneGenComponent.h"
12 #include "LibCyberRadio/Driver/NDR651/TransmitterComponent.h"
13 #include "LibCyberRadio/Driver/RadioHandler.h"
14 #include <boost/format.hpp>
15 
16 
17 namespace LibCyberRadio
18 {
19  namespace Driver
20  {
21 
22  namespace NDR651
23  {
25  int index,
27  bool debug,
28  double frequency,
29  double attenuation) :
31  /* const std::string& name */ ( boost::format("NDR651-TX%02d") % index ).str(),
32  /* int index */ index,
33  /* RadioHandler* parent */ parent,
34  /* bool debug */ debug,
35  /* double freqRangeMin */ 20e6,
36  /* double freqRangeMax */ 6000e6,
37  /* double freqRes */ 1e6,
38  /* double freqUnits */ 1e6,
39  /* double attRangeMin */ 0.0,
40  /* double attRangeMax */ 10.0,
41  /* double attRes */ 1.0,
42  /* int numToneGen */ 2,
43  /* int toneGenIndexBase */ 1,
44  /* double frequency */ frequency,
45  /* double attenuation */ attenuation )
46  {
48  // Allocate CW tone generators
49  for (int toneGen = _toneGenIndexBase; toneGen < _toneGenIndexBase + _numToneGen;
50  toneGen++)
51  {
52  _cwToneGens[toneGen] = new CWToneGenComponent(
53  /* int index */ toneGen,
54  /* RadioHandler* parent */ parent,
55  /* bool debug */ debug,
56  /* int txIndex */ index,
57  /* double frequency */ 900e6,
58  /* double amplitude */ 0.0,
59  /* double phase */ 0.0,
60  /* double sweepStart */ 900e6,
61  /* double sweepStop */ 900e6,
62  /* double sweepStep */ 1.0,
63  /* double dwellTime */ 1000.0
64  );
65  }
66  }
67 
69  {
70  }
71 
73  ::LibCyberRadio::Driver::TransmitterComponent(other)
74  {
75  }
76 
78  {
79  ::LibCyberRadio::Driver::TransmitterComponent::operator=(other);
80  if ( this != &other )
81  {
82  }
83  return *this;
84  }
85 
86  } // namespace NDR651
87 
88  } // namespace Driver
89 
90 } // namespace LibCyberRadio
Continuous-wave (CW) tone generator component class for the NDR651.
TransmitterComponent(int index=1, ::LibCyberRadio::Driver::RadioHandler *parent=NULL, bool debug=false, double frequency=900e6, double attenuation=0.0)
Constructs a TransmitterComponent object.
Generic radio handler class.
Definition: RadioHandler.h:54
virtual int debug(const char *format,...)
Outputs debug information.
Definition: Debuggable.cpp:95
Transmitter component class for the NDR651.
Defines functionality for LibCyberRadio applications.
Definition: App.h:23
virtual ~TransmitterComponent()
Destroys a TransmitterComponent object.
virtual void initConfigurationDict()
Initializes the configuration dictionary, defining the allowed keys.
virtual TransmitterComponent & operator=(const TransmitterComponent &other)
Assignment operator for TransmitterComponent objects.