diff options
Diffstat (limited to 'host/python')
-rw-r--r-- | host/python/CMakeLists.txt | 1 | ||||
-rw-r--r-- | host/python/pyuhd.cpp | 4 | ||||
-rw-r--r-- | host/python/uhd/__init__.py | 1 |
3 files changed, 6 insertions, 0 deletions
diff --git a/host/python/CMakeLists.txt b/host/python/CMakeLists.txt index 1e9fefa43..234870c5f 100644 --- a/host/python/CMakeLists.txt +++ b/host/python/CMakeLists.txt @@ -32,6 +32,7 @@ execute_process( add_library(pyuhd SHARED pyuhd.cpp ${CMAKE_SOURCE_DIR}/lib/property_tree_python.cpp + ${CMAKE_SOURCE_DIR}/lib/device_python.cpp ${CMAKE_SOURCE_DIR}/lib/usrp/multi_usrp_python.cpp ) # python expects extension modules with a particular suffix diff --git a/host/python/pyuhd.cpp b/host/python/pyuhd.cpp index eadb88d40..ca06f2d97 100644 --- a/host/python/pyuhd.cpp +++ b/host/python/pyuhd.cpp @@ -14,6 +14,7 @@ namespace py = pybind11; #include "cal/cal_python.hpp" +#include "device_python.hpp" #include "property_tree_python.hpp" #include "rfnoc/ddc_block_control_python.hpp" #include "rfnoc/duc_block_control_python.hpp" @@ -61,6 +62,9 @@ PYBIND11_MODULE(libpyuhd, m) // (otherwise we will see segmentation faults) init_numpy(); + // Register uhd::device::find + export_device(m); + // Register paths submodule auto paths_module = m.def_submodule("paths", "Path Utilities"); export_paths(paths_module); diff --git a/host/python/uhd/__init__.py b/host/python/uhd/__init__.py index bf11ac513..bfbe9a57f 100644 --- a/host/python/uhd/__init__.py +++ b/host/python/uhd/__init__.py @@ -14,6 +14,7 @@ from . import rfnoc from . import dsp from . import chdr from .libpyuhd.paths import * +from .libpyuhd import find from .property_tree import PropertyTree |