52 static KwargsList enumerate(
const std::string &args);
74 static Device *make(
const std::string &args);
81 static void unmake(
Device *device);
95 static std::vector<Device *> make(
const KwargsList &argsList);
105 static std::vector<Device *> make(
const std::vector<std::string> &argsList);
114 static void unmake(
const std::vector<Device *> &devices);
125 virtual std::string getDriverKey(
void)
const;
132 virtual std::string getHardwareKey(
void)
const;
141 virtual Kwargs getHardwareInfo(
void)
const;
153 virtual void setFrontendMapping(
const int direction,
const std::string &mapping);
160 virtual std::string getFrontendMapping(
const int direction)
const;
165 virtual size_t getNumChannels(
const int direction)
const;
177 virtual Kwargs getChannelInfo(
const int direction,
const size_t channel)
const;
185 virtual bool getFullDuplex(
const int direction,
const size_t channel)
const;
197 virtual std::vector<std::string> getStreamFormats(
const int direction,
const size_t channel)
const;
208 virtual std::string getNativeStreamFormat(
const int direction,
const size_t channel,
double &fullScale)
const;
216 virtual ArgInfoList getStreamArgsInfo(
const int direction,
const size_t channel)
const;
267 virtual Stream *setupStream(
269 const std::string &format,
270 const std::vector<size_t> &channels = std::vector<size_t>(),
278 virtual void closeStream(Stream *stream);
289 virtual size_t getStreamMTU(Stream *stream)
const;
308 virtual int activateStream(
311 const long long timeNs = 0,
312 const size_t numElems = 0);
328 virtual int deactivateStream(
331 const long long timeNs = 0);
352 virtual int readStream(
355 const size_t numElems,
358 const long timeoutUs = 100000);
379 virtual int writeStream(
381 const void *
const *buffs,
382 const size_t numElems,
384 const long long timeNs = 0,
385 const long timeoutUs = 100000);
407 virtual int readStreamStatus(
412 const long timeoutUs = 100000);
427 virtual size_t getNumDirectAccessBuffers(Stream *stream);
442 virtual int getDirectAccessBufferAddrs(Stream *stream,
const size_t handle,
void **buffs);
464 virtual int acquireReadBuffer(
470 const long timeoutUs = 100000);
479 virtual void releaseReadBuffer(
481 const size_t handle);
501 virtual int acquireWriteBuffer(
505 const long timeoutUs = 100000);
522 virtual void releaseWriteBuffer(
525 const size_t numElems,
527 const long long timeNs = 0);
539 virtual std::vector<std::string> listAntennas(
const int direction,
const size_t channel)
const;
547 virtual void setAntenna(
const int direction,
const size_t channel,
const std::string &name);
555 virtual std::string getAntenna(
const int direction,
const size_t channel)
const;
567 virtual bool hasDCOffsetMode(
const int direction,
const size_t channel)
const;
575 virtual void setDCOffsetMode(
const int direction,
const size_t channel,
const bool automatic);
583 virtual bool getDCOffsetMode(
const int direction,
const size_t channel)
const;
591 virtual bool hasDCOffset(
const int direction,
const size_t channel)
const;
599 virtual void setDCOffset(
const int direction,
const size_t channel,
const std::complex<double> &offset);
607 virtual std::complex<double> getDCOffset(
const int direction,
const size_t channel)
const;
615 virtual bool hasIQBalance(
const int direction,
const size_t channel)
const;
623 virtual void setIQBalance(
const int direction,
const size_t channel,
const std::complex<double> &balance);
631 virtual std::complex<double> getIQBalance(
const int direction,
const size_t channel)
const;
639 virtual bool hasIQBalanceMode(
const int direction,
const size_t channel)
const;
647 virtual void setIQBalanceMode(
const int direction,
const size_t channel,
const bool automatic);
655 virtual bool getIQBalanceMode(
const int direction,
const size_t channel)
const;
663 virtual bool hasFrequencyCorrection(
const int direction,
const size_t channel)
const;
671 virtual void setFrequencyCorrection(
const int direction,
const size_t channel,
const double value);
679 virtual double getFrequencyCorrection(
const int direction,
const size_t channel)
const;
692 virtual std::vector<std::string> listGains(
const int direction,
const size_t channel)
const;
700 virtual bool hasGainMode(
const int direction,
const size_t channel)
const;
708 virtual void setGainMode(
const int direction,
const size_t channel,
const bool automatic);
716 virtual bool getGainMode(
const int direction,
const size_t channel)
const;
725 virtual void setGain(
const int direction,
const size_t channel,
const double value);
734 virtual void setGain(
const int direction,
const size_t channel,
const std::string &name,
const double value);
742 virtual double getGain(
const int direction,
const size_t channel)
const;
751 virtual double getGain(
const int direction,
const size_t channel,
const std::string &name)
const;
759 virtual Range getGainRange(
const int direction,
const size_t channel)
const;
768 virtual Range getGainRange(
const int direction,
const size_t channel,
const std::string &name)
const;
801 virtual void setFrequency(
const int direction,
const size_t channel,
const double frequency,
const Kwargs &args =
Kwargs());
819 virtual void setFrequency(
const int direction,
const size_t channel,
const std::string &name,
const double frequency,
const Kwargs &args =
Kwargs());
829 virtual double getFrequency(
const int direction,
const size_t channel)
const;
838 virtual double getFrequency(
const int direction,
const size_t channel,
const std::string &name)
const;
847 virtual std::vector<std::string> listFrequencies(
const int direction,
const size_t channel)
const;
855 virtual RangeList getFrequencyRange(
const int direction,
const size_t channel)
const;
864 virtual RangeList getFrequencyRange(
const int direction,
const size_t channel,
const std::string &name)
const;
872 virtual ArgInfoList getFrequencyArgsInfo(
const int direction,
const size_t channel)
const;
884 virtual void setSampleRate(
const int direction,
const size_t channel,
const double rate);
892 virtual double getSampleRate(
const int direction,
const size_t channel)
const;
901 virtual std::vector<double> listSampleRates(
const int direction,
const size_t channel)
const;
909 virtual RangeList getSampleRateRange(
const int direction,
const size_t channel)
const;
921 virtual void setBandwidth(
const int direction,
const size_t channel,
const double bw);
929 virtual double getBandwidth(
const int direction,
const size_t channel)
const;
938 virtual std::vector<double> listBandwidths(
const int direction,
const size_t channel)
const;
946 virtual RangeList getBandwidthRange(
const int direction,
const size_t channel)
const;
956 virtual void setMasterClockRate(
const double rate);
962 virtual double getMasterClockRate(
void)
const;
968 virtual RangeList getMasterClockRates(
void)
const;
974 virtual void setReferenceClockRate(
const double rate);
980 virtual double getReferenceClockRate(
void)
const;
986 virtual RangeList getReferenceClockRates(
void)
const;
992 virtual std::vector<std::string> listClockSources(
void)
const;
998 virtual void setClockSource(
const std::string &source);
1004 virtual std::string getClockSource(
void)
const;
1014 virtual std::vector<std::string> listTimeSources(
void)
const;
1020 virtual void setTimeSource(
const std::string &source);
1026 virtual std::string getTimeSource(
void)
const;
1033 virtual bool hasHardwareTime(
const std::string &what =
"")
const;
1041 virtual long long getHardwareTime(
const std::string &what =
"")
const;
1049 virtual void setHardwareTime(
const long long timeNs,
const std::string &what =
"");
1059 virtual void setCommandTime(
const long long timeNs,
const std::string &what =
"");
1070 virtual std::vector<std::string> listSensors(
void)
const;
1078 virtual ArgInfo getSensorInfo(
const std::string &key)
const;
1087 virtual std::string readSensor(
const std::string &key)
const;
1095 template <
typename Type>
1096 Type readSensor(
const std::string &key)
const;
1105 virtual std::vector<std::string> listSensors(
const int direction,
const size_t channel)
const;
1115 virtual ArgInfo getSensorInfo(
const int direction,
const size_t channel,
const std::string &key)
const;
1126 virtual std::string readSensor(
const int direction,
const size_t channel,
const std::string &key)
const;
1136 template <
typename Type>
1137 Type readSensor(
const int direction,
const size_t channel,
const std::string &key)
const;
1147 virtual std::vector<std::string> listRegisterInterfaces(
void)
const;
1157 virtual void writeRegister(
const std::string &name,
const unsigned addr,
const unsigned value);
1165 virtual unsigned readRegister(
const std::string &name,
const unsigned addr)
const;
1175 virtual void writeRegister(
const unsigned addr,
const unsigned value);
1183 virtual unsigned readRegister(
const unsigned addr)
const;
1193 virtual void writeRegisters(
const std::string &name,
const unsigned addr,
const std::vector<unsigned> &value);
1202 virtual std::vector<unsigned> readRegisters(
const std::string &name,
const unsigned addr,
const size_t length)
const;
1220 virtual void writeSetting(
const std::string &key,
const std::string &value);
1228 template <
typename Type>
1229 void writeSetting(
const std::string &key,
const Type &value);
1236 virtual std::string readSetting(
const std::string &key)
const;
1244 template <
typename Type>
1245 Type readSetting(
const std::string &key);
1253 virtual ArgInfoList getSettingInfo(
const int direction,
const size_t channel)
const;
1263 virtual void writeSetting(
const int direction,
const size_t channel,
const std::string &key,
const std::string &value);
1273 template <
typename Type>
1274 void writeSetting(
const int direction,
const size_t channel,
const std::string &key,
const Type &value);
1283 virtual std::string readSetting(
const int direction,
const size_t channel,
const std::string &key)
const;
1293 template <
typename Type>
1294 Type readSetting(
const int direction,
const size_t channel,
const std::string &key);
1303 virtual std::vector<std::string> listGPIOBanks(
void)
const;
1310 virtual void writeGPIO(
const std::string &bank,
const unsigned value);
1318 virtual void writeGPIO(
const std::string &bank,
const unsigned value,
const unsigned mask);
1325 virtual unsigned readGPIO(
const std::string &bank)
const;
1333 virtual void writeGPIODir(
const std::string &bank,
const unsigned dir);
1342 virtual void writeGPIODir(
const std::string &bank,
const unsigned dir,
const unsigned mask);
1350 virtual unsigned readGPIODir(
const std::string &bank)
const;
1363 virtual void writeI2C(
const int addr,
const std::string &data);
1373 virtual std::string readI2C(
const int addr,
const size_t numBytes);
1393 virtual unsigned transactSPI(
const int addr,
const unsigned data,
const size_t numBits);
1403 virtual std::vector<std::string> listUARTs(
void)
const;
1412 virtual void writeUART(
const std::string &which,
const std::string &data);
1422 virtual std::string readUART(
const std::string &which,
const long timeoutUs = 100000)
const;
1434 virtual void* getNativeDeviceHandle(
void)
const;
1439 template <
typename Type>
1442 return SoapySDR::StringToSetting<Type>(this->
readSensor(key));
1445 template <
typename Type>
1448 return SoapySDR::StringToSetting<Type>(this->readSensor(direction, channel, key));
1451 template <
typename Type>
1457 template <
typename Type>
1460 return SoapySDR::StringToSetting<Type>(this->readSetting(key));
1463 template <
typename Type>
1469 template <
typename Type>
1472 return SoapySDR::StringToSetting<Type>(this->readSetting(direction, channel, key));