11#ifndef INCLUDED_LIBCYBERRADIO_DRIVER_TRANSMITTERCOMPONENT_H
12#define INCLUDED_LIBCYBERRADIO_DRIVER_TRANSMITTERCOMPONENT_H
14#include "LibCyberRadio/Driver/CWToneGenComponent.h"
15#include "LibCyberRadio/Driver/RadioComponent.h"
16#include "LibCyberRadio/Common/BasicList.h"
73 double freqRangeMin = 20e6,
74 double freqRangeMax = 6000e6,
76 double freqUnits = 1e6,
77 double attRangeMin = 0.0,
78 double attRangeMax = 10.0,
81 int toneGenIndexBase = 1,
82 double frequency = 900e6,
83 double attenuation = 0.0);
105 virtual bool enable(
bool enabled =
true);
262 virtual bool enableCW(
int index,
bool enabled =
true);
321 virtual bool setCWPhase(
int index,
double phase);
368 double step,
double dwell);
436 double _freqRangeMin;
438 double _freqRangeMax;
452 int _toneGenIndexBase;
virtual int debug(const char *format,...)
Outputs debug information.
A configuration dictionary.
RadioComponent(const std::string &name="<unknown>", int index=0, RadioHandler *parent=NULL, bool debug=false)
Constructs a RadioComponent object.
Generic radio handler class.
virtual double getCWSweepStartFrequency(int index) const
Gets the start frequency for a signal sweep for a given CW tone generator.
virtual bool enable(bool enabled=true)
Enables this component.
virtual bool setConfiguration(ConfigurationDict &cfg)
Sets the configuration dictionary for this component.
virtual TransmitterComponent & operator=(const TransmitterComponent &other)
Assignment operator for TransmitterComponent objects.
virtual double getCWFrequency(int index) const
Gets the constant frequency for a given CW tone generator.
virtual double getAttenuation() const
Gets the attenuation.
virtual bool setAttenuation(double atten)
Sets the attenuation.
virtual bool executeEnableCommand(int index, bool &enabled)
Executes the tuner enable command.
TransmitterComponent(const std::string &name="TX", int index=1, RadioHandler *parent=NULL, bool debug=false, double freqRangeMin=20e6, double freqRangeMax=6000e6, double freqRes=1e6, double freqUnits=1e6, double attRangeMin=0.0, double attRangeMax=10.0, double attRes=1.0, int numToneGen=0, int toneGenIndexBase=1, double frequency=900e6, double attenuation=0.0)
Constructs a TransmitterComponent object.
virtual BasicDoubleList getFrequencyRange() const
Gets the transmitter center frequency range.
virtual bool setFrequency(double freq)
Sets the transmitter center frequency.
virtual bool executeAttenCommand(int index, double &atten)
Executes the tuner attenuation set command.
virtual double getCWSweepFrequencyStep(int index) const
Gets the frequency step for a signal sweep for a given CW tone generator.
virtual int getCWNum() const
Gets the number of CW tone generators associated with this transmitter.
virtual double getFrequency() const
Gets the transmitter center frequency.
virtual bool executeFreqCommand(int index, double &freq)
Executes the tuner frequency set command.
virtual double getCWSweepDwellRes() const
Gets the CW dwell time resolution.
virtual double getCWSweepStepRes() const
Gets the CW frequency step resolution.
virtual BasicDoubleList getCWPhaseRange() const
Gets the CW phase range.
virtual BasicDoubleList getAttenuationRange() const
Gets the attenuation range.
virtual bool setCWConfiguration(int index, ConfigurationDict &cfg)
Sets the configuration dictionary for a given CW tone generator.
virtual bool disableCW(int index)
Disables a given CW tone generator.
virtual BasicDoubleList getCWSweepStopRange() const
Gets the CW stop frequency range.
virtual bool setCWFrequencySweep(int index, double start, double stop, double step, double dwell)
Sets the parameters for a frequency sweep for a given CW tone generator.
virtual void queryConfiguration()
Tells the component to query its hardware configuration in order to create its configuration dictiona...
virtual ~TransmitterComponent()
Destroys a TransmitterComponent object.
virtual double getCWAmplitude(int index) const
Gets the signal amplitude for a given CW tone generator.
virtual BasicDoubleList getCWAmplitudeRange() const
Gets the CW amplitude range.
virtual double getCWPhase(int index) const
Gets the signal phase for a given CW tone generator.
virtual bool executeFreqQuery(int index, double &freq)
Executes the tuner frequency query command.
virtual void updateConfigurationDict()
Updates the configuration dictionary from component settings.
virtual double getCWSweepStartRes() const
Gets the CW start frequency resolution.
virtual BasicDoubleList getCWSweepStepRange() const
Gets the CW frequency step range.
virtual ConfigurationDict getCWConfiguration(int index) const
Gets the configuration for a given CW tone generator.
virtual double getAttenuationRes() const
Gets the attenuation resolution.
virtual BasicDoubleList getCWSweepStartRange() const
Gets the CW start frequency range.
virtual bool supportsCWSweep() const
Gets whether the transmitter supports CW tone sweeping.
virtual double getCWAmplitudeRes() const
Gets the CW amplitude resolution.
virtual bool setCWPhase(int index, double phase)
Sets the signal phase for a given CW tone generator.
virtual bool supportsCW() const
Gets whether the transmitter supports CW tone generation.
virtual bool enableCW(int index, bool enabled=true)
Enables a given CW tone generator.
virtual double getCWSweepStopFrequency(int index) const
Gets the stop frequency for a signal sweep for a given CW tone generator.
virtual double getCWFrequencyRes() const
Gets the CW frequency resolution.
virtual void initConfigurationDict()
Initializes the configuration dictionary, defining the allowed keys.
virtual BasicDoubleList getCWFrequencyRange() const
Gets the CW frequency range.
virtual double getCWSweepDwellTime(int index) const
Gets the dwell time for a signal sweep for a given CW tone generator.
virtual bool executeEnableQuery(int index, bool &enabled)
Executes the tuner enabled query command.
virtual double getFrequencyUnit() const
Gets the transmitter center frequency units.
virtual bool setCWFrequency(int index, double freq)
Sets the constant frequency for a given CW tone generator.
virtual double getCWSweepStopRes() const
Gets the CW stop frequency resolution.
virtual double getCWPhaseRes() const
Gets the CW phase resolution.
virtual BasicDoubleList getCWSweepDwellRange() const
Gets the CW dwell time range.
virtual bool executeAttenQuery(int index, double &atten)
Executes the tuner attenuation query command.
virtual BasicIntList getCWIndexRange() const
Gets the range of indices for CW tone generators.
virtual bool setCWAmplitude(int index, double amp)
Sets the signal amplitude for a given CW tone generator.
virtual double getFrequencyRes() const
Gets the transmitter center frequency resolution.
Provides programming elements for driving CRS NDR-class radios.
BASIC_DICT_CONTAINER< int, TransmitterComponent * > TransmitterComponentDict
A dictionary of tuner components, keyed by index.
BASIC_DICT_CONTAINER< int, CWToneGenComponent * > CWToneGenComponentDict
A dictionary of CW tone generator components, keyed by index.
Defines functionality for LibCyberRadio applications.
BASIC_LIST_CONTAINER< int > BasicIntList
Type representing a list of integers.
BASIC_LIST_CONTAINER< double > BasicDoubleList
Type representing a list of doubles.