11 #ifndef INCLUDED_LIBCYBERRADIO_DRIVER_NBDDCCOMPONENT_H 12 #define INCLUDED_LIBCYBERRADIO_DRIVER_NBDDCCOMPONENT_H 14 #include "LibCyberRadio/Driver/RadioComponent.h" 15 #include "LibCyberRadio/Common/BasicDict.h" 16 #include "LibCyberRadio/Common/BasicList.h" 101 bool nbddcCommandSetsFreq =
false,
102 bool nbddcCommandSetsSource =
false,
103 bool selectableDataPort =
false,
104 double freqRangeMin = 0.0,
105 double freqRangeMax = 0.0,
106 double freqRes = 1.0,
107 double freqUnits = 1.0,
110 double frequency = 0.0,
112 int udpDestination = 0,
114 unsigned int streamId = 0);
135 virtual bool enable(
bool enabled =
true);
301 unsigned int& streamId,
323 unsigned int& streamId,
386 bool _nbddcCommandSetsFreq;
388 bool _nbddcCommandSetsSource;
390 bool _selectableDataPort;
392 double _freqRangeMin;
394 double _freqRangeMax;
412 unsigned int _streamId;
428 #endif // INCLUDED_LIBCYBERRADIO_DRIVER_NBDDCCOMPONENT_H NbddcComponent(const std::string &name="NBDDC", int index=1, RadioHandler *parent=NULL, bool debug=false, bool nbddcCommandSetsFreq=false, bool nbddcCommandSetsSource=false, bool selectableDataPort=false, double freqRangeMin=0.0, double freqRangeMax=0.0, double freqRes=1.0, double freqUnits=1.0, int source=1, int dataPort=1, double frequency=0.0, int rateIndex=0, int udpDestination=0, int vitaEnable=0, unsigned int streamId=0)
Constructs a NbddcComponent object.
virtual bool executeNbddcCommand(int index, int &rateIndex, int &udpDestination, bool &enabled, int &vitaEnable, unsigned int &streamId, double &frequency, int &source)
Executes the NBDDC configuration set command.
virtual int getRateIndex() const
Gets the NBDDC's rate index.
virtual int getDataPort() const
Gets the NBDDC's data port.
virtual void queryConfiguration()
Tells the component to query its hardware configuration in order to create its configuration dictiona...
virtual bool setVitaEnable(int enable)
Sets the NBDDC's VITA 49 setting.
Base hardware component class.
virtual bool executeNbddcQuery(int index, int &rateIndex, int &udpDestination, bool &enabled, int &vitaEnable, unsigned int &streamId, double &frequency, int &source)
Executes the NBDDC configuration query command.
BASIC_LIST_CONTAINER< double > BasicDoubleList
Type representing a list of doubles.
virtual double getFrequencyRes() const
Gets the tuned frequency resolution.
BASIC_DICT_CONTAINER< int, double > NbddcRateSet
A rate set for a NBDDC.
virtual double getFrequencyUnit() const
Gets the tuned frequency units.
virtual bool setUdpDestination(int dest)
Sets the NBDDC's UDP destination.
virtual int getUdpDestination() const
Gets the NBDDC's UDP destination.
virtual BasicDoubleList getRateList() const
Gets the list of allowed sample rates, based on the rate set.
virtual bool executeSourceCommand(int index, int &source)
Executes the NBDDC source set command.
virtual unsigned int getStreamId() const
Gets the NBDDC's VITA 49 stream ID.
virtual bool setDataPort(int port)
Sets the NBDDC's data port.
virtual int getSource() const
Gets the NBDDC's source (which tuner is supplying the signal).
virtual bool setRateIndex(int index)
Sets the NBDDC's rate index.
virtual int getVitaEnable() const
Gets the NBDDC's VITA 49 setting.
Generic radio handler class.
virtual int debug(const char *format,...)
Outputs debug information.
virtual void updateConfigurationDict()
Updates the configuration dictionary from component settings.
virtual bool executeDataPortCommand(int index, int &dataPort)
Executes the NBDDC data port set command.
virtual void initConfigurationDict()
Initializes the configuration dictionary, defining the allowed keys.
virtual BasicDoubleList getFrequencyRange() const
Gets the tunable frequency range.
Defines functionality for LibCyberRadio applications.
virtual NbddcComponent & operator=(const NbddcComponent &other)
Assignment operator for NbddcComponent objects.
virtual bool enable(bool enabled=true)
Enables this component.
A configuration dictionary.
virtual ~NbddcComponent()
Destroys a NbddcComponent object.
virtual double getFrequency() const
Gets the tuned frequency.
Base NBDDC component class.
virtual bool setStreamId(unsigned int sid)
Sets the NBDDC's VITA 49 stream ID.
virtual bool executeDataPortQuery(int index, int &dataPort)
Executes the NBDDC data port query command.
virtual NbddcRateSet getRateSet() const
Gets the NBDDC's rate set.
virtual bool setSource(int source)
Sets the NBDDC's source (which tuner is supplying the signal).
virtual bool setFrequency(double freq)
Sets the NBDDC tuned frequency.
virtual bool setConfiguration(ConfigurationDict &cfg)
Sets the configuration dictionary for this component.
virtual bool setRateSet(const NbddcRateSet &set)
Sets the NBDDC rate set.
BASIC_DICT_CONTAINER< int, NbddcComponent * > NbddcComponentDict
A dictionary of NBDDC components, keyed by index.
virtual bool executeFreqCommand(int index, double &freq)
Executes the NBDDC frequency set command.
virtual bool executeSourceQuery(int index, int &source)
Executes the NBDDC source query command.
virtual bool executeFreqQuery(int index, double &freq)
Executes the NBDDC frequency query command.