diff options
Diffstat (limited to 'mpm/include/mpm/ad9361/ad9361_ctrl.hpp')
-rw-r--r-- | mpm/include/mpm/ad9361/ad9361_ctrl.hpp | 30 |
1 files changed, 14 insertions, 16 deletions
diff --git a/mpm/include/mpm/ad9361/ad9361_ctrl.hpp b/mpm/include/mpm/ad9361/ad9361_ctrl.hpp index f79502add..8bcd7f7c4 100644 --- a/mpm/include/mpm/ad9361/ad9361_ctrl.hpp +++ b/mpm/include/mpm/ad9361/ad9361_ctrl.hpp @@ -8,24 +8,24 @@ // Relative to uhd/host/lib/usrp/common/ad9361_driver/ #include "../../../include/uhdlib/usrp/common/ad9361_ctrl.hpp" - #include <boost/make_shared.hpp> #include <boost/noncopyable.hpp> - #include <functional> #include <string> #include <vector> namespace mpm { namespace chips { - using uhd::usrp::ad9361_ctrl; -}}; +using uhd::usrp::ad9361_ctrl; +}}; // namespace mpm::chips -//TODO: pull in filter_info_base +// TODO: pull in filter_info_base #ifdef LIBMPM_PYTHON -void export_catalina(){ +void export_catalina() +{ LIBMPM_BOOST_PREAMBLE("ad9361") using namespace mpm::chips; - bp::class_<ad9361_ctrl, boost::noncopyable, boost::shared_ptr<ad9361_ctrl>>("ad9361_ctrl", bp::no_init) + bp::class_<ad9361_ctrl, boost::noncopyable, boost::shared_ptr<ad9361_ctrl>>( + "ad9361_ctrl", bp::no_init) .def("get_gain_names", &ad9361_ctrl::get_gain_names) .staticmethod("get_gain_names") // Make this "Python private" because the return value can't be serialized @@ -51,19 +51,17 @@ void export_catalina(){ .def("set_iq_balance_auto", &ad9361_ctrl::set_iq_balance_auto) .def("get_freq", &ad9361_ctrl::get_freq) .def("data_port_loopback", &ad9361_ctrl::data_port_loopback) - .def("get_rssi", +[](ad9361_ctrl& self, std::string which) { - return self.get_rssi(which).to_real(); - }) - .def("get_temperature", +[](ad9361_ctrl& self) { - return self.get_temperature().to_real(); - }) + .def("get_rssi", + +[](ad9361_ctrl& self, std::string which) { + return self.get_rssi(which).to_real(); + }) + .def("get_temperature", + +[](ad9361_ctrl& self) { return self.get_temperature().to_real(); }) .def("get_filter_names", &ad9361_ctrl::get_filter_names) // Make this "Python private" because the return value can't be serialized. .def("_get_filter", &ad9361_ctrl::get_filter) .def("set_filter", &ad9361_ctrl::set_filter) - .def("output_digital_test_tone", &ad9361_ctrl::output_digital_test_tone) - ; + .def("output_digital_test_tone", &ad9361_ctrl::output_digital_test_tone); } #endif - |