diff options
author | Josh Blum <josh@joshknows.com> | 2011-02-17 18:55:13 -0800 |
---|---|---|
committer | Josh Blum <josh@joshknows.com> | 2011-02-17 18:55:13 -0800 |
commit | dd75aa585afb9e59fcbb61507ad1a44fa4a00d38 (patch) | |
tree | be25749e4aac04e7832375254440e70f41ff7511 | |
parent | 1628434a32321f8af6355f5eb828e8b06da52b90 (diff) | |
parent | 4613f454c781d258d6d9b210ff1b9043a2125981 (diff) | |
download | uhd-dd75aa585afb9e59fcbb61507ad1a44fa4a00d38.tar.gz uhd-dd75aa585afb9e59fcbb61507ad1a44fa4a00d38.tar.bz2 uhd-dd75aa585afb9e59fcbb61507ad1a44fa4a00d38.zip |
Merge branch 'sensors' into usrp2_dual_dsp
Conflicts:
host/include/uhd/usrp/dsp_props.hpp
host/include/uhd/usrp/mboard_props.hpp
-rw-r--r-- | host/examples/rx_samples_to_file.cpp | 1 | ||||
-rw-r--r-- | host/examples/rx_samples_to_udp.cpp | 1 | ||||
-rw-r--r-- | host/include/uhd/types/sensors.hpp | 19 | ||||
-rw-r--r-- | host/include/uhd/usrp/multi_usrp.hpp | 58 | ||||
-rw-r--r-- | host/lib/types/sensors.cpp | 17 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_basic_and_lf.cpp | 8 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_dbsrx.cpp | 10 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_dbsrx2.cpp | 10 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_rfx.cpp | 19 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_tvrx.cpp | 5 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_unknown.cpp | 8 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_wbx.cpp | 19 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_xcvr2450.cpp | 25 | ||||
-rw-r--r-- | host/lib/usrp/multi_usrp.cpp | 36 |
14 files changed, 171 insertions, 65 deletions
diff --git a/host/examples/rx_samples_to_file.cpp b/host/examples/rx_samples_to_file.cpp index 296f480b0..e202fcb1c 100644 --- a/host/examples/rx_samples_to_file.cpp +++ b/host/examples/rx_samples_to_file.cpp @@ -78,7 +78,6 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){ std::cout << boost::format("Actual RX Gain: %f dB...") % usrp->get_rx_gain() << std::endl << std::endl; boost::this_thread::sleep(boost::posix_time::seconds(1)); //allow for some setup time - std::cout << "LO Locked = " << usrp->get_rx_lo_locked() << std::endl; //setup streaming uhd::stream_cmd_t stream_cmd(uhd::stream_cmd_t::STREAM_MODE_NUM_SAMPS_AND_DONE); diff --git a/host/examples/rx_samples_to_udp.cpp b/host/examples/rx_samples_to_udp.cpp index 801d8e361..7ea775764 100644 --- a/host/examples/rx_samples_to_udp.cpp +++ b/host/examples/rx_samples_to_udp.cpp @@ -80,7 +80,6 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){ std::cout << boost::format("Actual RX Gain: %f dB...") % usrp->get_rx_gain() << std::endl << std::endl; boost::this_thread::sleep(boost::posix_time::seconds(1)); //allow for some setup time - std::cout << "LO Locked = " << usrp->get_rx_lo_locked() << std::endl; //setup streaming uhd::stream_cmd_t stream_cmd(uhd::stream_cmd_t::STREAM_MODE_NUM_SAMPS_AND_DONE); diff --git a/host/include/uhd/types/sensors.hpp b/host/include/uhd/types/sensors.hpp index 6f003bb40..b6215367f 100644 --- a/host/include/uhd/types/sensors.hpp +++ b/host/include/uhd/types/sensors.hpp @@ -37,12 +37,6 @@ namespace uhd{ */ struct UHD_API sensor_value_t{ - //! typedef for the signed integer type - typedef signed int_type; - - //! typedef for the real number type - typedef double real_type; - /*! * Create a sensor value from a boolean. * \param name the name of the sensor @@ -66,7 +60,7 @@ namespace uhd{ */ sensor_value_t( const std::string &name, - int_type value, + signed value, const std::string &unit, const std::string &formatter = "%d" ); @@ -80,7 +74,7 @@ namespace uhd{ */ sensor_value_t( const std::string &name, - real_type value, + double value, const std::string &unit, const std::string &formatter = "%f" ); @@ -97,6 +91,15 @@ namespace uhd{ const std::string &unit ); + //! convert the sensor value to a boolean + bool to_bool(void) const; + + //! convert the sensor value to an integer + signed to_int(void) const; + + //! convert the sensor value to real number + double to_real(void) const; + //! The name of the sensor value const std::string name; diff --git a/host/include/uhd/usrp/multi_usrp.hpp b/host/include/uhd/usrp/multi_usrp.hpp index 9215652a6..e2b26f5fb 100644 --- a/host/include/uhd/usrp/multi_usrp.hpp +++ b/host/include/uhd/usrp/multi_usrp.hpp @@ -25,6 +25,7 @@ #include <uhd/types/clock_config.hpp> #include <uhd/types/tune_request.hpp> #include <uhd/types/tune_result.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/usrp/subdev_spec.hpp> #include <uhd/usrp/dboard_iface.hpp> #include <boost/shared_ptr.hpp> @@ -235,6 +236,21 @@ public: */ virtual size_t get_num_mboards(void) = 0; + /*! + * Get a motherboard sensor value. + * \param name the name of the sensor + * \param mboard the motherboard index 0 to M-1 + * \return a sensor value object + */ + virtual sensor_value_t get_mboard_sensor(const std::string &name, size_t mboard = 0) = 0; + + /*! + * Get a list of possible motherboard sensor names. + * \param mboard the motherboard index 0 to M-1 + * \return a vector of sensor names + */ + virtual std::vector<std::string> get_mboard_sensor_names(size_t mboard = 0) = 0; + /******************************************************************* * RX methods ******************************************************************/ @@ -383,7 +399,9 @@ public: * \param chan the channel index 0 to N-1 * \return true for locked */ - virtual bool get_rx_lo_locked(size_t chan = 0) = 0; + UHD_DEPRECATED bool get_rx_lo_locked(size_t chan = 0){ + return this->get_rx_sensor("lo_locked", chan).to_bool(); + } /*! * Set the RX bandwidth on the subdevice. @@ -405,7 +423,9 @@ public: * \return the rssi in dB * \throw exception if RSSI readback not supported */ - virtual double read_rssi(size_t chan = 0) = 0; + UHD_DEPRECATED double read_rssi(size_t chan = 0){ + return this->get_rx_sensor("rssi", chan).to_real(); + } /*! * Get the dboard interface object for the RX subdevice. @@ -416,6 +436,21 @@ public: */ virtual dboard_iface::sptr get_rx_dboard_iface(size_t chan = 0) = 0; + /*! + * Get an RX subdevice sensor value. + * \param name the name of the sensor + * \param chan the channel index 0 to N-1 + * \return a sensor value object + */ + virtual sensor_value_t get_rx_sensor(const std::string &name, size_t chan = 0) = 0; + + /*! + * Get a list of possible RX subdevice sensor names. + * \param chan the channel index 0 to N-1 + * \return a vector of sensor names + */ + virtual std::vector<std::string> get_rx_sensor_names(size_t chan = 0) = 0; + /******************************************************************* * TX methods ******************************************************************/ @@ -564,7 +599,9 @@ public: * \param chan the channel index 0 to N-1 * \return true for locked */ - virtual bool get_tx_lo_locked(size_t chan = 0) = 0; + UHD_DEPRECATED bool get_tx_lo_locked(size_t chan = 0){ + return this->get_tx_sensor("lo_locked", chan).to_bool(); + } /*! * Set the TX bandwidth on the subdevice. @@ -588,6 +625,21 @@ public: * \return the dboard interface sptr */ virtual dboard_iface::sptr get_tx_dboard_iface(size_t chan = 0) = 0; + + /*! + * Get an TX subdevice sensor value. + * \param name the name of the sensor + * \param chan the channel index 0 to N-1 + * \return a sensor value object + */ + virtual sensor_value_t get_tx_sensor(const std::string &name, size_t chan = 0) = 0; + + /*! + * Get a list of possible TX subdevice sensor names. + * \param chan the channel index 0 to N-1 + * \return a vector of sensor names + */ + virtual std::vector<std::string> get_tx_sensor_names(size_t chan = 0) = 0; }; }} diff --git a/host/lib/types/sensors.cpp b/host/lib/types/sensors.cpp index 2bff136a4..5f7115d70 100644 --- a/host/lib/types/sensors.cpp +++ b/host/lib/types/sensors.cpp @@ -17,6 +17,7 @@ #include <uhd/types/sensors.hpp> #include <uhd/utils/exception.hpp> +#include <boost/lexical_cast.hpp> #include <boost/format.hpp> using namespace uhd; @@ -35,7 +36,7 @@ sensor_value_t::sensor_value_t( sensor_value_t::sensor_value_t( const std::string &name, - int_type value, + signed value, const std::string &unit, const std::string &formatter ): @@ -47,7 +48,7 @@ sensor_value_t::sensor_value_t( sensor_value_t::sensor_value_t( const std::string &name, - real_type value, + double value, const std::string &unit, const std::string &formatter ): @@ -79,3 +80,15 @@ std::string sensor_value_t::to_pp_string(void) const{ } UHD_THROW_INVALID_CODE_PATH(); } + +bool sensor_value_t::to_bool(void) const{ + return value == "true"; +} + +signed sensor_value_t::to_int(void) const{ + return boost::lexical_cast<signed>(value); +} + +double sensor_value_t::to_real(void) const{ + return boost::lexical_cast<double>(value); +} diff --git a/host/lib/usrp/dboard/db_basic_and_lf.cpp b/host/lib/usrp/dboard/db_basic_and_lf.cpp index b311576d2..b319289db 100644 --- a/host/lib/usrp/dboard/db_basic_and_lf.cpp +++ b/host/lib/usrp/dboard/db_basic_and_lf.cpp @@ -173,10 +173,6 @@ void basic_rx::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = true; //there is no LO, so it must be true! - return; - case SUBDEV_PROP_BANDWIDTH: val = subdev_bandwidth_scalar[get_subdev_name()]*_max_freq; return; @@ -284,10 +280,6 @@ void basic_tx::tx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = true; //there is no LO, so it must be true! - return; - case SUBDEV_PROP_BANDWIDTH: val = subdev_bandwidth_scalar[get_subdev_name()]*_max_freq; return; diff --git a/host/lib/usrp/dboard/db_dbsrx.cpp b/host/lib/usrp/dboard/db_dbsrx.cpp index 3ea9cea80..98d9479fc 100644 --- a/host/lib/usrp/dboard/db_dbsrx.cpp +++ b/host/lib/usrp/dboard/db_dbsrx.cpp @@ -25,6 +25,7 @@ #include <uhd/utils/algorithm.hpp> #include <uhd/utils/warning.hpp> #include <uhd/types/ranges.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/types/dict.hpp> #include <uhd/usrp/subdev_props.hpp> #include <uhd/usrp/dboard_base.hpp> @@ -561,8 +562,13 @@ void dbsrx::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: diff --git a/host/lib/usrp/dboard/db_dbsrx2.cpp b/host/lib/usrp/dboard/db_dbsrx2.cpp index defb70ff5..f4b797995 100644 --- a/host/lib/usrp/dboard/db_dbsrx2.cpp +++ b/host/lib/usrp/dboard/db_dbsrx2.cpp @@ -22,6 +22,7 @@ #include <uhd/utils/assert.hpp> #include <uhd/utils/algorithm.hpp> #include <uhd/types/ranges.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/types/dict.hpp> #include <uhd/usrp/subdev_props.hpp> #include <uhd/usrp/dboard_base.hpp> @@ -400,8 +401,13 @@ void dbsrx2::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: diff --git a/host/lib/usrp/dboard/db_rfx.cpp b/host/lib/usrp/dboard/db_rfx.cpp index 2c672ded8..3e3cf00f2 100644 --- a/host/lib/usrp/dboard/db_rfx.cpp +++ b/host/lib/usrp/dboard/db_rfx.cpp @@ -36,6 +36,7 @@ #include <uhd/types/dict.hpp> #include <uhd/usrp/subdev_props.hpp> #include <uhd/types/ranges.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/utils/assert.hpp> #include <uhd/utils/static.hpp> #include <uhd/utils/algorithm.hpp> @@ -449,8 +450,13 @@ void rfx_xcvr::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(dboard_iface::UNIT_RX); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(dboard_iface::UNIT_RX), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: @@ -546,8 +552,13 @@ void rfx_xcvr::tx_get(const wax::obj &key_, wax::obj &val){ val = true; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(dboard_iface::UNIT_TX); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(dboard_iface::UNIT_TX), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: diff --git a/host/lib/usrp/dboard/db_tvrx.cpp b/host/lib/usrp/dboard/db_tvrx.cpp index a9ce38000..578999432 100644 --- a/host/lib/usrp/dboard/db_tvrx.cpp +++ b/host/lib/usrp/dboard/db_tvrx.cpp @@ -32,6 +32,7 @@ #include <uhd/utils/algorithm.hpp> #include <uhd/utils/warning.hpp> #include <uhd/types/ranges.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/types/dict.hpp> #include <uhd/usrp/subdev_props.hpp> #include <uhd/usrp/dboard_base.hpp> @@ -463,10 +464,6 @@ void tvrx::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = true; - return; - case SUBDEV_PROP_BANDWIDTH: val = 6.0e6; return; diff --git a/host/lib/usrp/dboard/db_unknown.cpp b/host/lib/usrp/dboard/db_unknown.cpp index d91d58409..f0a4c000e 100644 --- a/host/lib/usrp/dboard/db_unknown.cpp +++ b/host/lib/usrp/dboard/db_unknown.cpp @@ -154,10 +154,6 @@ void unknown_rx::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = true; //there is no LO, so it must be true! - return; - case SUBDEV_PROP_BANDWIDTH: val = 0.0; return; @@ -256,10 +252,6 @@ void unknown_tx::tx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = true; //there is no LO, so it must be true! - return; - case SUBDEV_PROP_BANDWIDTH: val = 0.0; return; diff --git a/host/lib/usrp/dboard/db_wbx.cpp b/host/lib/usrp/dboard/db_wbx.cpp index 135997789..0bc2d0ca1 100644 --- a/host/lib/usrp/dboard/db_wbx.cpp +++ b/host/lib/usrp/dboard/db_wbx.cpp @@ -68,6 +68,7 @@ #include <uhd/types/dict.hpp> #include <uhd/usrp/subdev_props.hpp> #include <uhd/types/ranges.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/utils/assert.hpp> #include <uhd/utils/static.hpp> #include <uhd/utils/algorithm.hpp> @@ -521,8 +522,13 @@ void wbx_xcvr::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(dboard_iface::UNIT_RX); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(dboard_iface::UNIT_RX), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: @@ -622,8 +628,13 @@ void wbx_xcvr::tx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(dboard_iface::UNIT_TX); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(dboard_iface::UNIT_TX), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: diff --git a/host/lib/usrp/dboard/db_xcvr2450.cpp b/host/lib/usrp/dboard/db_xcvr2450.cpp index 6fb5a26a8..f4f74eb86 100644 --- a/host/lib/usrp/dboard/db_xcvr2450.cpp +++ b/host/lib/usrp/dboard/db_xcvr2450.cpp @@ -53,6 +53,7 @@ #include <uhd/utils/algorithm.hpp> #include <uhd/utils/warning.hpp> #include <uhd/types/ranges.hpp> +#include <uhd/types/sensors.hpp> #include <uhd/types/dict.hpp> #include <uhd/usrp/subdev_props.hpp> #include <uhd/usrp/dboard_base.hpp> @@ -616,12 +617,19 @@ void xcvr2450::rx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(); + case SUBDEV_PROP_SENSOR: + if (key.name == "lo_locked") + val = sensor_value_t("LO", this->get_locked(), "locked", "unlocked"); + else if (key.name == "rssi") + val = sensor_value_t("RSSI", this->get_rssi(), "dB"); + else + UHD_THROW_INVALID_CODE_PATH(); return; - case SUBDEV_PROP_RSSI: - val = this->get_rssi(); + case SUBDEV_PROP_SENSOR_NAMES:{ + prop_names_t names = list_of("lo_locked")("rssi"); + val = names; + } return; case SUBDEV_PROP_BANDWIDTH: @@ -719,8 +727,13 @@ void xcvr2450::tx_get(const wax::obj &key_, wax::obj &val){ val = false; return; - case SUBDEV_PROP_LO_LOCKED: - val = this->get_locked(); + case SUBDEV_PROP_SENSOR: + UHD_ASSERT_THROW(key.name == "lo_locked"); + val = sensor_value_t("LO", this->get_locked(), "locked", "unlocked"); + return; + + case SUBDEV_PROP_SENSOR_NAMES: + val = prop_names_t(1, "lo_locked"); return; case SUBDEV_PROP_BANDWIDTH: diff --git a/host/lib/usrp/multi_usrp.cpp b/host/lib/usrp/multi_usrp.cpp index 9f001595d..5130d3ae8 100644 --- a/host/lib/usrp/multi_usrp.cpp +++ b/host/lib/usrp/multi_usrp.cpp @@ -212,6 +212,14 @@ public: return (*_dev)[DEVICE_PROP_MBOARD_NAMES].as<prop_names_t>().size(); } + sensor_value_t get_mboard_sensor(const std::string &name, size_t mboard){ + return _mboard(mboard)[named_prop_t(MBOARD_PROP_SENSOR, name)].as<sensor_value_t>(); + } + + std::vector<std::string> get_mboard_sensor_names(size_t mboard){ + return _mboard(mboard)[MBOARD_PROP_SENSOR_NAMES].as<prop_names_t>(); + } + /******************************************************************* * RX methods ******************************************************************/ @@ -294,10 +302,6 @@ public: return _rx_subdev(chan)[SUBDEV_PROP_ANTENNA_NAMES].as<prop_names_t>(); } - bool get_rx_lo_locked(size_t chan){ - return _rx_subdev(chan)[SUBDEV_PROP_LO_LOCKED].as<bool>(); - } - void set_rx_bandwidth(double bandwidth, size_t chan){ _rx_subdev(chan)[SUBDEV_PROP_BANDWIDTH] = bandwidth; } @@ -306,14 +310,18 @@ public: return _rx_subdev(chan)[SUBDEV_PROP_BANDWIDTH].as<double>(); } - double read_rssi(size_t chan){ - return _rx_subdev(chan)[SUBDEV_PROP_RSSI].as<double>(); - } - dboard_iface::sptr get_rx_dboard_iface(size_t chan){ return _rx_dboard(chan)[DBOARD_PROP_DBOARD_IFACE].as<dboard_iface::sptr>(); } + sensor_value_t get_rx_sensor(const std::string &name, size_t chan){ + return _rx_subdev(chan)[named_prop_t(SUBDEV_PROP_SENSOR, name)].as<sensor_value_t>(); + } + + std::vector<std::string> get_rx_sensor_names(size_t chan){ + return _rx_subdev(chan)[SUBDEV_PROP_SENSOR_NAMES].as<prop_names_t>(); + } + /******************************************************************* * TX methods ******************************************************************/ @@ -396,10 +404,6 @@ public: return _tx_subdev(chan)[SUBDEV_PROP_ANTENNA_NAMES].as<prop_names_t>(); } - bool get_tx_lo_locked(size_t chan){ - return _tx_subdev(chan)[SUBDEV_PROP_LO_LOCKED].as<bool>(); - } - void set_tx_bandwidth(double bandwidth, size_t chan){ _tx_subdev(chan)[SUBDEV_PROP_BANDWIDTH] = bandwidth; } @@ -412,6 +416,14 @@ public: return _tx_dboard(chan)[DBOARD_PROP_DBOARD_IFACE].as<dboard_iface::sptr>(); } + sensor_value_t get_tx_sensor(const std::string &name, size_t chan){ + return _tx_subdev(chan)[named_prop_t(SUBDEV_PROP_SENSOR, name)].as<sensor_value_t>(); + } + + std::vector<std::string> get_tx_sensor_names(size_t chan){ + return _tx_subdev(chan)[SUBDEV_PROP_SENSOR_NAMES].as<prop_names_t>(); + } + private: device::sptr _dev; |