summaryrefslogtreecommitdiff
path: root/gnuradio-runtime
diff options
context:
space:
mode:
Diffstat (limited to 'gnuradio-runtime')
-rw-r--r--gnuradio-runtime/CMakeLists.txt6
-rw-r--r--gnuradio-runtime/include/gnuradio/CMakeLists.txt2
-rw-r--r--gnuradio-runtime/include/gnuradio/basic_block.h4
-rw-r--r--gnuradio-runtime/include/gnuradio/block.h2
-rw-r--r--gnuradio-runtime/include/gnuradio/block_gateway.h311
-rw-r--r--gnuradio-runtime/include/gnuradio/feval.h175
-rw-r--r--gnuradio-runtime/include/gnuradio/logger.h5
-rw-r--r--gnuradio-runtime/include/gnuradio/py_feval.h86
-rw-r--r--gnuradio-runtime/include/pmt/pmt.h3
-rw-r--r--gnuradio-runtime/lib/CMakeLists.txt5
-rw-r--r--gnuradio-runtime/lib/block.cc2
-rw-r--r--gnuradio-runtime/lib/block_gateway_impl.cc139
-rw-r--r--gnuradio-runtime/lib/block_gateway_impl.h57
-rw-r--r--gnuradio-runtime/lib/feval.cc74
-rw-r--r--gnuradio-runtime/lib/pmt/pmt.cc5
-rw-r--r--gnuradio-runtime/python/gnuradio/__init__.py2
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/CMakeLists.txt7
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/__init__.py16
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/CMakeLists.txt90
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/basic_block_python.cc283
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/block_detail_python.cc358
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/block_gateway_python.cc96
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/block_python.cc501
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/buffer_python.cc234
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc70
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/basic_block_pydoc_template.h156
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_detail_pydoc_template.h183
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_pydoc_template.h294
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/buffer_pydoc_template.h144
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/constants_pydoc_template.h51
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/endianness_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/expj_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/flowgraph_pydoc_template.h156
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_nco_pydoc_template.h84
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_pydoc_template.h39
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_vco_pydoc_template.h48
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/hier_block2_pydoc_template.h126
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/high_res_timer_pydoc_template.h27
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/io_signature_pydoc_template.h45
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/logger_pydoc_template.h147
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/math_pydoc_template.h75
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/message_pydoc_template.h54
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_accepter_pydoc_template.h27
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_handler_pydoc_template.h27
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_queue_pydoc_template.h51
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/nco_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/prefs_pydoc_template.h63
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/random_pydoc_template.h51
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_impl_pydoc_template.h39
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_pydoc_template.h18
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpccallbackregister_base_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcmanager_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcregisterhelpers_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_aggregator_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_base_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_booter_aggregator_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/runtime_types_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sincos_pydoc_template.h21
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sptr_magic_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_block_pydoc_template.h33
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_decimator_pydoc_template.h36
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_interpolator_pydoc_template.h36
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sys_paths_pydoc_template.h24
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tag_checker_pydoc_template.h27
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tagged_stream_block_pydoc_template.h30
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tags_pydoc_template.h27
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/thrift_application_base_pydoc_template.h15
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/top_block_pydoc_template.h63
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tpb_detail_pydoc_template.h36
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/endianness_python.cc35
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/expj_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/flowgraph_python.cc226
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_nco_python.cc161
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_python.cc68
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_vco_python.cc89
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/hier_block2_python.cc227
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/high_res_timer_python.cc46
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/io_signature_python.cc90
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/logger_python.cc162
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/math_python.cc148
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/message_python.cc91
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_msgq_python.cc33
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_passing_python.cc51
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_producer_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_queue_python.cc42
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/msg_accepter_python.cc55
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/msg_handler_python.cc48
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/msg_queue_python.cc77
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/nco_python.cc30
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/prefs_python.cc134
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/python_bindings.cc209
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc77
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/realtime_impl_python.cc81
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/realtime_python.cc40
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/rpccallbackregister_base_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/rpcmanager_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/rpcregisterhelpers_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_aggregator_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_base_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_booter_aggregator_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/runtime_types_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/sincos_python.cc48
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/sptr_magic_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/sync_block_python.cc82
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/sync_decimator_python.cc86
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/sync_interpolator_python.cc89
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/sys_paths_python.cc41
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/tag_checker_python.cc57
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/tagged_stream_block_python.cc81
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/tags_python.cc55
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_body_wrapper_python.cc20
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_group_python.cc37
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_python.cc53
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/thrift_application_base_python.cc28
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/top_block_python.cc154
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/bindings/tpb_detail_python.cc56
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/gateway.py349
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/hier_block2.py16
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/qa_feval.py99
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/qa_flowgraph.py2
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/tag_utils.py38
-rw-r--r--gnuradio-runtime/python/gnuradio/gr/top_block.py17
-rw-r--r--gnuradio-runtime/python/pmt/CMakeLists.txt4
-rw-r--r--gnuradio-runtime/python/pmt/__init__.py6
-rw-r--r--gnuradio-runtime/python/pmt/bindings/CMakeLists.txt18
-rw-r--r--gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pool_pydoc_template.h27
-rw-r--r--gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pydoc_template.h882
-rw-r--r--gnuradio-runtime/python/pmt/bindings/docstrings/pmt_sugar_pydoc_template.h78
-rw-r--r--gnuradio-runtime/python/pmt/bindings/pmt_pool_python.cc42
-rw-r--r--gnuradio-runtime/python/pmt/bindings/pmt_python.cc1558
-rw-r--r--gnuradio-runtime/python/pmt/bindings/pmt_sugar_python.cc217
-rw-r--r--gnuradio-runtime/python/pmt/bindings/python_bindings.cc46
-rw-r--r--gnuradio-runtime/python/pmt/pmt_to_python.py4
-rw-r--r--gnuradio-runtime/swig/CMakeLists.txt102
-rw-r--r--gnuradio-runtime/swig/basic_block.i54
-rw-r--r--gnuradio-runtime/swig/block.i108
-rw-r--r--gnuradio-runtime/swig/block_detail.i44
-rw-r--r--gnuradio-runtime/swig/block_gateway.i37
-rw-r--r--gnuradio-runtime/swig/buffer.i55
-rw-r--r--gnuradio-runtime/swig/constants.i20
-rw-r--r--gnuradio-runtime/swig/feval.i86
-rw-r--r--gnuradio-runtime/swig/gnuradio.i70
-rw-r--r--gnuradio-runtime/swig/gr_ctrlport.i88
-rw-r--r--gnuradio-runtime/swig/gr_extras.i57
-rw-r--r--gnuradio-runtime/swig/gr_logger.i74
-rw-r--r--gnuradio-runtime/swig/gr_shared_ptr.i43
-rw-r--r--gnuradio-runtime/swig/gr_swig_block_magic.i56
-rw-r--r--gnuradio-runtime/swig/gr_types.i86
-rw-r--r--gnuradio-runtime/swig/hier_block2.i97
-rw-r--r--gnuradio-runtime/swig/io_signature.i57
-rw-r--r--gnuradio-runtime/swig/message.i66
-rw-r--r--gnuradio-runtime/swig/msg_handler.i21
-rw-r--r--gnuradio-runtime/swig/msg_queue.i96
-rw-r--r--gnuradio-runtime/swig/pmt_swig.i325
-rw-r--r--gnuradio-runtime/swig/prefs.i51
-rw-r--r--gnuradio-runtime/swig/realtime.i30
-rw-r--r--gnuradio-runtime/swig/runtime_swig.i87
-rw-r--r--gnuradio-runtime/swig/sync_block.i18
-rw-r--r--gnuradio-runtime/swig/sync_decimator.i19
-rw-r--r--gnuradio-runtime/swig/sync_interpolator.i19
-rw-r--r--gnuradio-runtime/swig/tagged_stream_block.i19
-rw-r--r--gnuradio-runtime/swig/tags.i21
-rw-r--r--gnuradio-runtime/swig/top_block.i96
164 files changed, 10701 insertions, 3070 deletions
diff --git a/gnuradio-runtime/CMakeLists.txt b/gnuradio-runtime/CMakeLists.txt
index c03b5ffe4d..e4d5e1df54 100644
--- a/gnuradio-runtime/CMakeLists.txt
+++ b/gnuradio-runtime/CMakeLists.txt
@@ -28,6 +28,7 @@ GR_REGISTER_COMPONENT("gnuradio-runtime" ENABLE_GNURADIO_RUNTIME
PYTHONINTERP_FOUND
MPLIB_FOUND
LOG4CPP_FOUND
+ pybind11_FOUND
)
get_filename_component(GNURADIO_RUNTIME_PYTHONPATH
@@ -38,12 +39,8 @@ get_filename_component(GNURADIO_RUNTIME_PYTHONPATH
# Register controlport component
########################################################################
-FIND_PACKAGE(SWIG)
-
GR_REGISTER_COMPONENT("gr-ctrlport" ENABLE_GR_CTRLPORT
Boost_FOUND
- SWIG_FOUND
- SWIG_VERSION_CHECK
ENABLE_GNURADIO_RUNTIME
)
@@ -81,7 +78,6 @@ add_subdirectory(include)
add_subdirectory(lib)
add_subdirectory(apps)
if(ENABLE_PYTHON)
- add_subdirectory(swig)
add_subdirectory(python)
add_subdirectory(examples)
endif(ENABLE_PYTHON)
diff --git a/gnuradio-runtime/include/gnuradio/CMakeLists.txt b/gnuradio-runtime/include/gnuradio/CMakeLists.txt
index 056af5d6f4..d8e9c193ee 100644
--- a/gnuradio-runtime/include/gnuradio/CMakeLists.txt
+++ b/gnuradio-runtime/include/gnuradio/CMakeLists.txt
@@ -23,7 +23,6 @@ install(FILES
constants.h
endianness.h
expj.h
- feval.h
flowgraph.h
fxpt.h
fxpt_nco.h
@@ -42,7 +41,6 @@ install(FILES
msg_queue.h
nco.h
prefs.h
- py_feval.h
pycallback_object.h
random.h
realtime.h
diff --git a/gnuradio-runtime/include/gnuradio/basic_block.h b/gnuradio-runtime/include/gnuradio/basic_block.h
index 651fda2136..47d939a5bc 100644
--- a/gnuradio-runtime/include/gnuradio/basic_block.h
+++ b/gnuradio-runtime/include/gnuradio/basic_block.h
@@ -18,9 +18,9 @@
#include <gnuradio/runtime_types.h>
#include <gnuradio/sptr_magic.h>
#include <gnuradio/thread/thread.h>
-#include <boost/function.hpp>
#include <boost/thread/condition_variable.hpp>
#include <deque>
+#include <functional>
#include <map>
#include <string>
@@ -42,7 +42,7 @@ namespace gr {
class GR_RUNTIME_API basic_block : public msg_accepter,
public std::enable_shared_from_this<basic_block>
{
- typedef boost::function<void(pmt::pmt_t)> msg_handler_t;
+ typedef std::function<void(pmt::pmt_t)> msg_handler_t;
private:
typedef std::map<pmt::pmt_t, msg_handler_t, pmt::comparator> d_msg_handlers_t;
diff --git a/gnuradio-runtime/include/gnuradio/block.h b/gnuradio-runtime/include/gnuradio/block.h
index 2a47a05715..4f4bfb6953 100644
--- a/gnuradio-runtime/include/gnuradio/block.h
+++ b/gnuradio-runtime/include/gnuradio/block.h
@@ -60,7 +60,7 @@ class GR_RUNTIME_API block : public basic_block
{
public:
//! Magic return values from general_work
- enum { WORK_CALLED_PRODUCE = -2, WORK_DONE = -1 };
+ enum work_return_t { WORK_CALLED_PRODUCE = -2, WORK_DONE = -1 };
/*!
* \brief enum to represent different tag propagation policies.
diff --git a/gnuradio-runtime/include/gnuradio/block_gateway.h b/gnuradio-runtime/include/gnuradio/block_gateway.h
index bcf3a7b27d..d42dfbb620 100644
--- a/gnuradio-runtime/include/gnuradio/block_gateway.h
+++ b/gnuradio-runtime/include/gnuradio/block_gateway.h
@@ -1,6 +1,6 @@
/* -*- c++ -*- */
/*
- * Copyright 2011-2013,2017 Free Software Foundation, Inc.
+ * Copyright 2011-2013,2017,2020 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
@@ -13,332 +13,107 @@
#include <gnuradio/api.h>
#include <gnuradio/block.h>
-#include <gnuradio/feval.h>
+#include <string>
-namespace gr {
-
-/*!
- * The work type enum tells the gateway what kind of block to
- * implement. The choices are familiar gnuradio block overloads
- * (sync, decim, interp).
- */
-enum block_gw_work_type {
- GR_BLOCK_GW_WORK_GENERAL,
- GR_BLOCK_GW_WORK_SYNC,
- GR_BLOCK_GW_WORK_DECIM,
- GR_BLOCK_GW_WORK_INTERP,
-};
-
-//! Magic return values from general_work, \ref gr::block::WORK_CALLED_PRODUCE
-enum block_gw_work_return_type { WORK_CALLED_PRODUCE = -2, WORK_DONE = -1 };
-enum tag_propagation_policy_t {
- TPP_DONT = 0,
- TPP_ALL_TO_ALL = 1,
- TPP_ONE_TO_ONE = 2,
- TPP_CUSTOM = 3
-};
-
-/*!
- * Shared message structure between python and gateway.
- * Each action type represents a scheduler-called function.
- */
-struct block_gw_message_type {
- enum action_type {
- ACTION_GENERAL_WORK, // dispatch work
- ACTION_WORK, // dispatch work
- ACTION_FORECAST, // dispatch forecast
- ACTION_START, // dispatch start
- ACTION_STOP, // dispatch stop
- };
-
- action_type action;
-
- int general_work_args_noutput_items;
- std::vector<int> general_work_args_ninput_items;
- std::vector<void*> general_work_args_input_items; // TODO this should be const void*,
- // but swig can't int cast it right
- std::vector<void*> general_work_args_output_items;
- int general_work_args_return_value;
-
- int work_args_ninput_items;
- int work_args_noutput_items;
- std::vector<void*> work_args_input_items; // TODO this should be const void*, but swig
- // can't int cast it right
- std::vector<void*> work_args_output_items;
- int work_args_return_value;
-
- int forecast_args_noutput_items;
- std::vector<int> forecast_args_ninput_items_required;
-
- bool start_args_return_value;
+#include <pybind11/pybind11.h> // must be first
+#include <pybind11/stl.h>
+namespace py = pybind11;
- bool stop_args_return_value;
-};
+namespace gr {
/*!
* The gateway block which performs all the magic.
*
* The gateway provides access to all the gr::block routines.
- * The methods prefixed with gr::block__ are renamed
- * to class methods without the prefix in python.
*/
+typedef enum {
+ GW_BLOCK_GENERAL = 0,
+ GW_BLOCK_SYNC,
+ GW_BLOCK_DECIM,
+ GW_BLOCK_INTERP
+} gw_block_t;
+
class GR_RUNTIME_API block_gateway : virtual public gr::block
{
+private:
+ py::handle d_py_handle;
+
public:
// gr::block_gateway::sptr
typedef std::shared_ptr<block_gateway> sptr;
/*!
* Make a new gateway block.
- * \param handler the swig director object with callback
+ * \param py_object the pybind11 object with callback
* \param name the name of the block (Ex: "Shirley")
* \param in_sig the input signature for this block
* \param out_sig the output signature for this block
- * \param work_type the type of block overload to implement
- * \param factor the decimation or interpolation factor
* \return a new gateway block
*/
- static sptr make(gr::feval_ll* handler,
+ static sptr make(const py::object& py_handle,
const std::string& name,
gr::io_signature::sptr in_sig,
- gr::io_signature::sptr out_sig,
- const block_gw_work_type work_type,
- const unsigned factor);
-
- //! Provide access to the shared message object
- virtual block_gw_message_type& block_message(void) = 0;
-
- long block__unique_id(void) const { return gr::block::unique_id(); }
-
- std::string block__name(void) const { return gr::block::name(); }
+ gr::io_signature::sptr out_sig);
- unsigned block__history(void) const { return gr::block::history(); }
-
- void block__set_history(unsigned history) { return gr::block::set_history(history); }
-
- void block__set_block_alias(std::string alias)
- {
- return gr::block::set_block_alias(alias);
- }
-
- std::string block__alias(void) const { return gr::block::alias(); }
-
- void block__set_processor_affinity(std::vector<int> mask)
- {
- return gr::block::set_processor_affinity(mask);
- }
-
- void block__set_fixed_rate(bool fixed_rate)
- {
- return gr::block::set_fixed_rate(fixed_rate);
- }
-
- bool block__fixed_rate(void) const { return gr::block::fixed_rate(); }
-
- void block__set_output_multiple(int multiple)
- {
- return gr::block::set_output_multiple(multiple);
- }
-
- void block__set_min_output_buffer(int port, long size)
- {
- return gr::block::set_min_output_buffer(port, size);
- }
-
- void block__set_min_output_buffer(long size)
- {
- return gr::block::set_min_output_buffer(size);
- }
-
- long block__max_output_buffer(size_t i) { return gr::block::max_output_buffer(i); }
-
- void block__set_max_output_buffer(long max_output_buffer)
- {
- gr::block::set_max_output_buffer(max_output_buffer);
- }
-
- void block__set_max_output_buffer(int port, long max_output_buffer)
- {
- gr::block::set_max_output_buffer(port, max_output_buffer);
- }
-
- int block__output_multiple(void) const { return gr::block::output_multiple(); }
-
- void block__consume(int which_input, int how_many_items)
- {
- return gr::block::consume(which_input, how_many_items);
- }
-
- void block__consume_each(int how_many_items)
- {
- return gr::block::consume_each(how_many_items);
- }
- void block__produce(int which_output, int how_many_items)
- {
- return gr::block::produce(which_output, how_many_items);
- }
-
- void block__set_relative_rate(double relative_rate)
- {
- return gr::block::set_relative_rate(relative_rate);
- }
-
- void block__set_inverse_relative_rate(double inverse_relative_rate)
- {
- return gr::block::set_inverse_relative_rate(inverse_relative_rate);
- }
-
- void block__set_relative_rate(uint64_t interpolation, uint64_t decimation)
- {
- return gr::block::set_relative_rate(interpolation, decimation);
- }
-
- double block__relative_rate(void) const { return gr::block::relative_rate(); }
-
- uint64_t block__relative_rate_i(void) const { return gr::block::relative_rate_i(); }
-
- uint64_t block__relative_rate_d(void) const { return gr::block::relative_rate_d(); }
-
- uint64_t block__nitems_read(unsigned int which_input)
- {
- return gr::block::nitems_read(which_input);
- }
-
- uint64_t block__nitems_written(unsigned int which_output)
- {
- return gr::block::nitems_written(which_output);
- }
-
- block::tag_propagation_policy_t block__tag_propagation_policy(void)
- {
- return gr::block::tag_propagation_policy();
- }
-
- void block__set_tag_propagation_policy(block::tag_propagation_policy_t p)
- {
- return gr::block::set_tag_propagation_policy(p);
- }
-
- void block__add_item_tag(unsigned int which_output, const tag_t& tag)
+ // Protected members of gr::block trampolined here for python blocks to use
+ void _add_item_tag(unsigned int which_output, const tag_t& tag)
{
return gr::block::add_item_tag(which_output, tag);
}
- void block__add_item_tag(unsigned int which_output,
- uint64_t abs_offset,
- const pmt::pmt_t& key,
- const pmt::pmt_t& value,
- const pmt::pmt_t& srcid = pmt::PMT_F)
+ void _add_item_tag(unsigned int which_output,
+ uint64_t abs_offset,
+ const pmt::pmt_t& key,
+ const pmt::pmt_t& value,
+ const pmt::pmt_t& srcid = pmt::PMT_F)
{
return gr::block::add_item_tag(which_output, abs_offset, key, value, srcid);
}
- std::vector<tag_t> block__get_tags_in_range(unsigned int which_input,
- uint64_t abs_start,
- uint64_t abs_end)
+
+ std::vector<tag_t>
+ _get_tags_in_range(unsigned int which_input, uint64_t abs_start, uint64_t abs_end)
{
std::vector<gr::tag_t> tags;
gr::block::get_tags_in_range(tags, which_input, abs_start, abs_end);
return tags;
}
- std::vector<tag_t> block__get_tags_in_range(unsigned int which_input,
- uint64_t abs_start,
- uint64_t abs_end,
- const pmt::pmt_t& key)
+ std::vector<tag_t> _get_tags_in_range(unsigned int which_input,
+ uint64_t abs_start,
+ uint64_t abs_end,
+ const pmt::pmt_t& key)
{
std::vector<gr::tag_t> tags;
gr::block::get_tags_in_range(tags, which_input, abs_start, abs_end, key);
return tags;
}
- std::vector<tag_t> block__get_tags_in_window(unsigned int which_input,
- uint64_t rel_start,
- uint64_t rel_end)
+ std::vector<tag_t>
+ _get_tags_in_window(unsigned int which_input, uint64_t rel_start, uint64_t rel_end)
{
std::vector<gr::tag_t> tags;
gr::block::get_tags_in_window(tags, which_input, rel_start, rel_end);
return tags;
}
- std::vector<tag_t> block__get_tags_in_window(unsigned int which_input,
- uint64_t rel_start,
- uint64_t rel_end,
- const pmt::pmt_t& key)
+ std::vector<tag_t> _get_tags_in_window(unsigned int which_input,
+ uint64_t rel_start,
+ uint64_t rel_end,
+ const pmt::pmt_t& key)
{
std::vector<gr::tag_t> tags;
gr::block::get_tags_in_window(tags, which_input, rel_start, rel_end, key);
return tags;
}
- /* Message passing interface */
- void block__message_port_register_in(pmt::pmt_t port_id)
- {
- gr::basic_block::message_port_register_in(port_id);
- }
-
- void block__message_port_register_out(pmt::pmt_t port_id)
- {
- gr::basic_block::message_port_register_out(port_id);
- }
-
- void block__message_port_pub(pmt::pmt_t port_id, pmt::pmt_t msg)
- {
- gr::basic_block::message_port_pub(port_id, msg);
- }
-
- void block__message_port_sub(pmt::pmt_t port_id, pmt::pmt_t target)
- {
- gr::basic_block::message_port_sub(port_id, target);
- }
-
- void block__message_port_unsub(pmt::pmt_t port_id, pmt::pmt_t target)
- {
- gr::basic_block::message_port_unsub(port_id, target);
- }
-
- pmt::pmt_t block__message_subscribers(pmt::pmt_t which_port)
- {
- return gr::basic_block::message_subscribers(which_port);
- }
-
- pmt::pmt_t block__message_ports_in() { return gr::basic_block::message_ports_in(); }
-
- pmt::pmt_t block__message_ports_out() { return gr::basic_block::message_ports_out(); }
-
- void set_msg_handler_feval(pmt::pmt_t which_port, gr::feval_p* msg_handler)
- {
- if (msg_queue.find(which_port) == msg_queue.end()) {
- throw std::runtime_error(
- "attempt to set_msg_handler_feval() on bad input message port!");
- }
- d_msg_handlers_feval[which_port] = msg_handler;
- }
+ virtual void set_msg_handler_pybind(pmt::pmt_t which_port,
+ std::string& handler_name) = 0;
protected:
- typedef std::map<pmt::pmt_t, feval_p*, pmt::comparator> msg_handlers_feval_t;
- msg_handlers_feval_t d_msg_handlers_feval;
-
- bool has_msg_handler(pmt::pmt_t which_port)
- {
- if (d_msg_handlers_feval.find(which_port) != d_msg_handlers_feval.end()) {
- return true;
- } else {
- return gr::basic_block::has_msg_handler(which_port);
- }
- }
-
- void dispatch_msg(pmt::pmt_t which_port, pmt::pmt_t msg)
- {
- // Is there a handler?
- if (d_msg_handlers_feval.find(which_port) != d_msg_handlers_feval.end()) {
- d_msg_handlers_feval[which_port]->calleval(msg); // Yes, invoke it.
- } else {
- // Pass to generic dispatcher if not found
- gr::basic_block::dispatch_msg(which_port, msg);
- }
- }
+ virtual bool has_msg_handler(pmt::pmt_t which_port) = 0;
+ virtual void dispatch_msg(pmt::pmt_t which_port, pmt::pmt_t msg) = 0;
};
} /* namespace gr */
diff --git a/gnuradio-runtime/include/gnuradio/feval.h b/gnuradio-runtime/include/gnuradio/feval.h
deleted file mode 100644
index 0148aea89c..0000000000
--- a/gnuradio-runtime/include/gnuradio/feval.h
+++ /dev/null
@@ -1,175 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2006,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#ifndef INCLUDED_GR_FEVAL_H
-#define INCLUDED_GR_FEVAL_H
-
-#include <gnuradio/api.h>
-#include <gnuradio/gr_complex.h>
-#include <pmt/pmt.h>
-
-namespace gr {
-
-/*!
- * \brief base class for evaluating a function: double -> double
- * \ingroup misc
- *
- * This class is designed to be subclassed in Python or C++ and is
- * callable from both places. It uses SWIG's "director" feature to
- * implement the magic.
- *
- * It's slow. Don't use it in a performance critical path.
- *
- * Override eval to define the behavior.
- * Use calleval to invoke eval (this kludge is required to allow a
- * python specific "shim" to be inserted.
- */
-class GR_RUNTIME_API feval_dd
-{
-protected:
- /*!
- * \brief override this to define the function
- */
- virtual double eval(double x);
-
-public:
- feval_dd() {}
- virtual ~feval_dd();
-
- virtual double calleval(double x); // invoke "eval"
-};
-
-/*!
- * \brief base class for evaluating a function: complex -> complex
- * \ingroup misc
- *
- * This class is designed to be subclassed in Python or C++ and is
- * callable from both places. It uses SWIG's "director" feature to
- * implement the magic.
- *
- * It's slow. Don't use it in a performance critical path.
- *
- * Override eval to define the behavior.
- * Use calleval to invoke eval (this kludge is required to allow a
- * python specific "shim" to be inserted.
- */
-class GR_RUNTIME_API feval_cc
-{
-protected:
- /*!
- * \brief override this to define the function
- */
- virtual gr_complex eval(gr_complex x);
-
-public:
- feval_cc() {}
- virtual ~feval_cc();
-
- virtual gr_complex calleval(gr_complex x); // invoke "eval"
-};
-
-/*!
- * \brief base class for evaluating a function: long -> long
- * \ingroup misc
- *
- * This class is designed to be subclassed in Python or C++ and is
- * callable from both places. It uses SWIG's "director" feature to
- * implement the magic.
- *
- * It's slow. Don't use it in a performance critical path.
- *
- * Override eval to define the behavior.
- * Use calleval to invoke eval (this kludge is required to allow a
- * python specific "shim" to be inserted.
- */
-class GR_RUNTIME_API feval_ll
-{
-protected:
- /*!
- * \brief override this to define the function
- */
- virtual long eval(long x);
-
-public:
- feval_ll() {}
- virtual ~feval_ll();
-
- virtual long calleval(long x); // invoke "eval"
-};
-
-/*!
- * \brief base class for evaluating a function: void -> void
- * \ingroup misc
- *
- * This class is designed to be subclassed in Python or C++ and is
- * callable from both places. It uses SWIG's "director" feature to
- * implement the magic.
- *
- * It's slow. Don't use it in a performance critical path.
- *
- * Override eval to define the behavior.
- * Use calleval to invoke eval (this kludge is required to allow a
- * python specific "shim" to be inserted.
- */
-class GR_RUNTIME_API feval
-{
-protected:
- /*!
- * \brief override this to define the function
- */
- virtual void eval();
-
-public:
- feval() {}
- virtual ~feval();
-
- virtual void calleval(); // invoke "eval"
-};
-
-/*!
- * \brief base class for evaluating a function: pmt -> void
- * \ingroup misc
- *
- * This class is designed to be subclassed in Python or C++ and is
- * callable from both places. It uses SWIG's "director" feature to
- * implement the magic.
- *
- * It's slow. Don't use it in a performance critical path.
- *
- * Override eval to define the behavior.
- * Use calleval to invoke eval (this kludge is required to allow a
- * python specific "shim" to be inserted.
- */
-class GR_RUNTIME_API feval_p
-{
-protected:
- /*!
- * \brief override this to define the function
- */
- virtual void eval(pmt::pmt_t x);
-
-public:
- feval_p() {}
- virtual ~feval_p();
-
- virtual void calleval(pmt::pmt_t x); // invoke "eval"
-};
-
-/*!
- * \brief trivial examples / test cases showing C++ calling Python code
- */
-GR_RUNTIME_API double feval_dd_example(feval_dd* f, double x);
-GR_RUNTIME_API gr_complex feval_cc_example(feval_cc* f, gr_complex x);
-GR_RUNTIME_API long feval_ll_example(feval_ll* f, long x);
-GR_RUNTIME_API void feval_example(feval* f);
-
-} /* namespace gr */
-
-#endif /* INCLUDED_GR_FEVAL_H */
diff --git a/gnuradio-runtime/include/gnuradio/logger.h b/gnuradio-runtime/include/gnuradio/logger.h
index f2d053c084..2fa0bd6eef 100644
--- a/gnuradio-runtime/include/gnuradio/logger.h
+++ b/gnuradio-runtime/include/gnuradio/logger.h
@@ -352,13 +352,12 @@ private:
void set_config4rpc(std::string set) { printf("Set string was:%s\n", set.c_str()); }
- /*! \brief destructor stops watch thread before exits */
- ~logger_config() { stop_watch(); }
-
/*! \brief Instance getter for singleton. Only used by class. */
static logger_config& get_instance(void);
public:
+ /*! \brief destructor stops watch thread before exits */
+ ~logger_config() { stop_watch(); }
/*! \brief Getter for config filename */
static std::string get_filename();
/*! \brief Getter for watch period */
diff --git a/gnuradio-runtime/include/gnuradio/py_feval.h b/gnuradio-runtime/include/gnuradio/py_feval.h
deleted file mode 100644
index 50af37ec03..0000000000
--- a/gnuradio-runtime/include/gnuradio/py_feval.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2006,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#ifndef INCLUDED_GR_PY_FEVAL_H
-#define INCLUDED_GR_PY_FEVAL_H
-
-#include <gnuradio/feval.h>
-#include <Python.h>
-#include <pmt/pmt.h>
-
-class ensure_py_gil_state
-{
- PyGILState_STATE d_gstate;
-
-public:
- ensure_py_gil_state() { d_gstate = PyGILState_Ensure(); }
- ~ensure_py_gil_state() { PyGILState_Release(d_gstate); }
-};
-
-namespace gr {
-
-class GR_RUNTIME_API py_feval_dd : public feval_dd
-{
-public:
- double calleval(double x)
- {
- ensure_py_gil_state _lock;
- return eval(x);
- }
- virtual ~py_feval_dd(){};
-};
-
-class GR_RUNTIME_API py_feval_cc : public feval_cc
-{
-public:
- gr_complex calleval(gr_complex x)
- {
- ensure_py_gil_state _lock;
- return eval(x);
- }
- virtual ~py_feval_cc(){};
-};
-
-class GR_RUNTIME_API py_feval_ll : public feval_ll
-{
-public:
- long calleval(long x)
- {
- ensure_py_gil_state _lock;
- return eval(x);
- }
- virtual ~py_feval_ll(){};
-};
-
-class GR_RUNTIME_API py_feval : public feval
-{
-public:
- void calleval()
- {
- ensure_py_gil_state _lock;
- eval();
- }
- virtual ~py_feval(){};
-};
-
-class GR_RUNTIME_API py_feval_p : public feval_p
-{
-public:
- void calleval(pmt::pmt_t x)
- {
- ensure_py_gil_state _lock;
- eval(x);
- }
- virtual ~py_feval_p(){};
-};
-
-} /* namespace gr */
-
-#endif /* INCLUDED_GR_PY_FEVAL_H */
diff --git a/gnuradio-runtime/include/pmt/pmt.h b/gnuradio-runtime/include/pmt/pmt.h
index 079e466898..a977a23eaa 100644
--- a/gnuradio-runtime/include/pmt/pmt.h
+++ b/gnuradio-runtime/include/pmt/pmt.h
@@ -41,11 +41,12 @@ namespace pmt {
/*!
* \brief base class of all pmt types
*/
-class pmt_base : boost::noncopyable
+class PMT_API pmt_base
{
public:
pmt_base(){};
+ pmt_base(const pmt_base&) = delete;
virtual ~pmt_base();
virtual bool is_bool() const { return false; }
diff --git a/gnuradio-runtime/lib/CMakeLists.txt b/gnuradio-runtime/lib/CMakeLists.txt
index ee89f363ce..65673ad699 100644
--- a/gnuradio-runtime/lib/CMakeLists.txt
+++ b/gnuradio-runtime/lib/CMakeLists.txt
@@ -47,7 +47,6 @@ add_library(gnuradio-runtime
block_gateway_impl.cc
block_registry.cc
buffer.cc
- feval.cc
flat_flowgraph.cc
flowgraph.cc
hier_block2.cc
@@ -196,10 +195,14 @@ target_link_libraries(gnuradio-runtime PUBLIC
Boost::thread
Log4Cpp::log4cpp
MPLib::mplib
+ ${PYTHON_LIBRARIES}
)
target_include_directories(gnuradio-runtime
PUBLIC
+ ${PYTHON_INCLUDE_DIR}
+ ${PYTHON_NUMPY_INCLUDE_DIR}
+ ${pybind11_INCLUDE_DIR}
$<INSTALL_INTERFACE:${CMAKE_INSTALL_PREFIX}/include>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/../include>
$<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/../include>
diff --git a/gnuradio-runtime/lib/block.cc b/gnuradio-runtime/lib/block.cc
index ebfeba23ba..b6137f7a51 100644
--- a/gnuradio-runtime/lib/block.cc
+++ b/gnuradio-runtime/lib/block.cc
@@ -49,7 +49,7 @@ block::block(const std::string& name,
{
global_block_registry.register_primitive(alias(), this);
message_port_register_in(d_system_port);
- set_msg_handler(d_system_port, boost::bind(&block::system_handler, this, _1));
+ set_msg_handler(d_system_port, [this](pmt::pmt_t msg) { this->system_handler(msg); });
}
block::~block() { global_block_registry.unregister_primitive(symbol_name()); }
diff --git a/gnuradio-runtime/lib/block_gateway_impl.cc b/gnuradio-runtime/lib/block_gateway_impl.cc
index 4acb464511..f4550a8bdc 100644
--- a/gnuradio-runtime/lib/block_gateway_impl.cc
+++ b/gnuradio-runtime/lib/block_gateway_impl.cc
@@ -1,93 +1,44 @@
+/* -*- c++ -*- */
/*
- * Copyright 2011-2013 Free Software Foundation, Inc.
+ * Copyright 2013,2020 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
* SPDX-License-Identifier: GPL-3.0-or-later
*
*/
-
#include "block_gateway_impl.h"
+#include <pybind11/embed.h>
+
#include <gnuradio/io_signature.h>
-#include <boost/bind.hpp>
#include <iostream>
namespace gr {
-/***********************************************************************
- * Helper routines
- **********************************************************************/
-template <typename OutType, typename InType>
-void copy_pointers(OutType& out, const InType& in)
-{
- out.resize(in.size());
- for (size_t i = 0; i < in.size(); i++) {
- out[i] = (void*)(in[i]);
- }
-}
-
-
-block_gateway::sptr block_gateway::make(feval_ll* handler,
+block_gateway::sptr block_gateway::make(const py::object& p,
const std::string& name,
gr::io_signature::sptr in_sig,
- gr::io_signature::sptr out_sig,
- const block_gw_work_type work_type,
- const unsigned factor)
+ gr::io_signature::sptr out_sig)
{
- return block_gateway::sptr(
- new block_gateway_impl(handler, name, in_sig, out_sig, work_type, factor));
+ return block_gateway::sptr(new block_gateway_impl(p, name, in_sig, out_sig));
}
-block_gateway_impl::block_gateway_impl(feval_ll* handler,
+block_gateway_impl::block_gateway_impl(const py::handle& p,
const std::string& name,
gr::io_signature::sptr in_sig,
- gr::io_signature::sptr out_sig,
- const block_gw_work_type work_type,
- const unsigned factor)
- : block(name, in_sig, out_sig), _handler(handler), _work_type(work_type)
+ gr::io_signature::sptr out_sig)
+ : block(name, in_sig, out_sig)
{
- switch (_work_type) {
- case GR_BLOCK_GW_WORK_GENERAL:
- _decim = 1; // not relevant, but set anyway
- _interp = 1; // not relevant, but set anyway
- break;
-
- case GR_BLOCK_GW_WORK_SYNC:
- _decim = 1;
- _interp = 1;
- this->set_fixed_rate(true);
- break;
-
- case GR_BLOCK_GW_WORK_DECIM:
- _decim = factor;
- _interp = 1;
- break;
-
- case GR_BLOCK_GW_WORK_INTERP:
- _decim = 1;
- _interp = factor;
- this->set_output_multiple(_interp);
- break;
- }
+ _py_handle = p;
}
void block_gateway_impl::forecast(int noutput_items, gr_vector_int& ninput_items_required)
{
- switch (_work_type) {
- case GR_BLOCK_GW_WORK_GENERAL:
- _message.action = block_gw_message_type::ACTION_FORECAST;
- _message.forecast_args_noutput_items = noutput_items;
- _message.forecast_args_ninput_items_required = ninput_items_required;
- _handler->calleval(0);
- ninput_items_required = _message.forecast_args_ninput_items_required;
- return;
+ py::gil_scoped_acquire acquire;
- default:
- unsigned ninputs = ninput_items_required.size();
- for (unsigned i = 0; i < ninputs; i++)
- ninput_items_required[i] = fixed_rate_noutput_to_ninput(noutput_items);
- return;
- }
+ py::object ret_ninput_items_required =
+ _py_handle.attr("handle_forecast")(noutput_items, ninput_items_required.size());
+ ninput_items_required = ret_ninput_items_required.cast<std::vector<int>>();
}
int block_gateway_impl::general_work(int noutput_items,
@@ -95,63 +46,29 @@ int block_gateway_impl::general_work(int noutput_items,
gr_vector_const_void_star& input_items,
gr_vector_void_star& output_items)
{
- switch (_work_type) {
- case GR_BLOCK_GW_WORK_GENERAL:
- _message.action = block_gw_message_type::ACTION_GENERAL_WORK;
- _message.general_work_args_noutput_items = noutput_items;
- _message.general_work_args_ninput_items = ninput_items;
- copy_pointers(_message.general_work_args_input_items, input_items);
- _message.general_work_args_output_items = output_items;
- _handler->calleval(0);
- return _message.general_work_args_return_value;
-
- default:
- int r = work(noutput_items, input_items, output_items);
- if (r > 0)
- consume_each(r * _decim / _interp);
- return r;
- }
-}
-
-int block_gateway_impl::work(int noutput_items,
- gr_vector_const_void_star& input_items,
- gr_vector_void_star& output_items)
-{
- _message.action = block_gw_message_type::ACTION_WORK;
- _message.work_args_ninput_items = fixed_rate_noutput_to_ninput(noutput_items);
- if (_message.work_args_ninput_items == 0)
- return -1;
- _message.work_args_noutput_items = noutput_items;
- copy_pointers(_message.work_args_input_items, input_items);
- _message.work_args_output_items = output_items;
- _handler->calleval(0);
- return _message.work_args_return_value;
-}
+ py::gil_scoped_acquire acquire;
-int block_gateway_impl::fixed_rate_noutput_to_ninput(int noutput_items)
-{
- return (noutput_items * _decim / _interp) + history() - 1;
-}
+ py::object ret = _py_handle.attr("handle_general_work")(
+ noutput_items, ninput_items, input_items, output_items);
-int block_gateway_impl::fixed_rate_ninput_to_noutput(int ninput_items)
-{
- return std::max(0, ninput_items - (int)history() + 1) * _interp / _decim;
+ return ret.cast<int>();
+ ;
}
bool block_gateway_impl::start(void)
{
- _message.action = block_gw_message_type::ACTION_START;
- _handler->calleval(0);
- return _message.start_args_return_value;
+ py::gil_scoped_acquire acquire;
+
+ py::object ret = _py_handle.attr("start")();
+ return ret.cast<bool>();
}
bool block_gateway_impl::stop(void)
{
- _message.action = block_gw_message_type::ACTION_STOP;
- _handler->calleval(0);
- return _message.stop_args_return_value;
-}
+ py::gil_scoped_acquire acquire;
-block_gw_message_type& block_gateway_impl::block_message(void) { return _message; }
+ py::object ret = _py_handle.attr("stop")();
+ return ret.cast<bool>();
+}
} /* namespace gr */
diff --git a/gnuradio-runtime/lib/block_gateway_impl.h b/gnuradio-runtime/lib/block_gateway_impl.h
index a87f0ec1e5..dc609a1248 100644
--- a/gnuradio-runtime/lib/block_gateway_impl.h
+++ b/gnuradio-runtime/lib/block_gateway_impl.h
@@ -1,6 +1,6 @@
/* -*- c++ -*- */
/*
- * Copyright 2013 Free Software Foundation, Inc.
+ * Copyright 2013,2020 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
@@ -21,12 +21,10 @@ namespace gr {
class block_gateway_impl : public block_gateway
{
public:
- block_gateway_impl(feval_ll* handler,
+ block_gateway_impl(const py::handle& p,
const std::string& name,
gr::io_signature::sptr in_sig,
- gr::io_signature::sptr out_sig,
- const block_gw_work_type work_type,
- const unsigned factor);
+ gr::io_signature::sptr out_sig);
/*******************************************************************
* Overloads for various scheduler-called functions
@@ -38,23 +36,48 @@ public:
gr_vector_const_void_star& input_items,
gr_vector_void_star& output_items);
- int work(int noutput_items,
- gr_vector_const_void_star& input_items,
- gr_vector_void_star& output_items);
-
- int fixed_rate_noutput_to_ninput(int noutput_items);
- int fixed_rate_ninput_to_noutput(int ninput_items);
-
bool start(void);
bool stop(void);
+ void set_msg_handler_pybind(pmt::pmt_t which_port, std::string& handler_name)
+ {
+ if (msg_queue.find(which_port) == msg_queue.end()) {
+ throw std::runtime_error(
+ "attempt to set_msg_handler_pybind() on invalid input message port!");
+ }
+ d_msg_handlers_pybind[which_port] = handler_name;
+ }
+
+protected:
+ // Message handlers back into python using pybind API
+ typedef std::map<pmt::pmt_t, std::string, pmt::comparator> msg_handlers_pybind_t;
+ msg_handlers_pybind_t d_msg_handlers_pybind;
+
+ bool has_msg_handler(pmt::pmt_t which_port)
+ {
+ if (d_msg_handlers_pybind.find(which_port) != d_msg_handlers_pybind.end()) {
+ return true;
+ } else {
+ return gr::basic_block::has_msg_handler(which_port);
+ }
+ }
- block_gw_message_type& block_message(void);
+ void dispatch_msg(pmt::pmt_t which_port, pmt::pmt_t msg)
+ {
+ // Is there a handler?
+ if (d_msg_handlers_pybind.find(which_port) != d_msg_handlers_pybind.end()) {
+ // d_msg_handlers_pybind[which_port]->calleval(msg); // Yes, invoke it.
+ py::gil_scoped_acquire acquire;
+ // std::string handler_name(d_msg_handlers_pybind[which_port]);
+ py::object ret =
+ _py_handle.attr(d_msg_handlers_pybind[which_port].c_str())(msg);
+ } else {
+ // Pass to generic dispatcher if not found
+ gr::basic_block::dispatch_msg(which_port, msg);
+ }
+ }
private:
- feval_ll* _handler;
- block_gw_message_type _message;
- const block_gw_work_type _work_type;
- unsigned _decim, _interp;
+ py::handle _py_handle;
};
} /* namespace gr */
diff --git a/gnuradio-runtime/lib/feval.cc b/gnuradio-runtime/lib/feval.cc
deleted file mode 100644
index 63e3fa419d..0000000000
--- a/gnuradio-runtime/lib/feval.cc
+++ /dev/null
@@ -1,74 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2006,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <gnuradio/feval.h>
-
-namespace gr {
-
-feval_dd::~feval_dd() {}
-
-double feval_dd::eval(double x) { return 0; }
-
-double feval_dd::calleval(double x) { return eval(x); }
-
-// ----------------------------------------------------------------
-
-feval_cc::~feval_cc() {}
-
-gr_complex feval_cc::eval(gr_complex x) { return 0; }
-
-gr_complex feval_cc::calleval(gr_complex x) { return eval(x); }
-
-// ----------------------------------------------------------------
-
-feval_ll::~feval_ll() {}
-
-long feval_ll::eval(long x) { return 0; }
-
-long feval_ll::calleval(long x) { return eval(x); }
-
-// ----------------------------------------------------------------
-
-feval::~feval() {}
-
-void feval::eval(void)
-{
- // nop
-}
-
-void feval::calleval(void) { eval(); }
-
-// ----------------------------------------------------------------
-
-feval_p::~feval_p() {}
-
-void feval_p::eval(pmt::pmt_t x)
-{
- // nop
-}
-
-void feval_p::calleval(pmt::pmt_t x) { eval(x); }
-
-/*
- * Trivial examples showing C++ (transparently) calling Python
- */
-double feval_dd_example(feval_dd* f, double x) { return f->calleval(x); }
-
-gr_complex feval_cc_example(feval_cc* f, gr_complex x) { return f->calleval(x); }
-
-long feval_ll_example(feval_ll* f, long x) { return f->calleval(x); }
-
-void feval_example(feval* f) { f->calleval(); }
-
-} /* namespace gr */
diff --git a/gnuradio-runtime/lib/pmt/pmt.cc b/gnuradio-runtime/lib/pmt/pmt.cc
index a421b55ba9..102c8b0fa2 100644
--- a/gnuradio-runtime/lib/pmt/pmt.cc
+++ b/gnuradio-runtime/lib/pmt/pmt.cc
@@ -298,6 +298,11 @@ pmt_t pmt_from_complex(double re, double im)
return pmt_t(new pmt_complex(std::complex<double>(re, im)));
}
+pmt_t pmt_from_complex(const std::complex<double>& z)
+{
+ return pmt_t(new pmt_complex(z));
+}
+
pmt_t from_complex(const std::complex<double>& z) { return pmt_t(new pmt_complex(z)); }
std::complex<double> to_complex(pmt_t x)
diff --git a/gnuradio-runtime/python/gnuradio/__init__.py b/gnuradio-runtime/python/gnuradio/__init__.py
index 7e7b6d8bc4..28a493fa6b 100644
--- a/gnuradio-runtime/python/gnuradio/__init__.py
+++ b/gnuradio-runtime/python/gnuradio/__init__.py
@@ -42,6 +42,6 @@ if path.endswith(path_ending):
__path__.append(os.path.join(build_path, 'gr-vocoder', 'python'))
__path__.append(os.path.join(build_path, 'gr-channels', 'python'))
__path__.append(os.path.join(build_path, 'gr-fec', 'python'))
- __path__.append(os.path.join(build_path, 'gr-utils', 'python'))
+ __path__.append(os.path.join(build_path, 'gr-utils'))
__path__.append(os.path.join(build_path, 'gr-uhd', 'python'))
__path__.append(os.path.join(build_path, 'gr-zeromq', 'python'))
diff --git a/gnuradio-runtime/python/gnuradio/gr/CMakeLists.txt b/gnuradio-runtime/python/gnuradio/gr/CMakeLists.txt
index 459c8bc022..4633445f17 100644
--- a/gnuradio-runtime/python/gnuradio/gr/CMakeLists.txt
+++ b/gnuradio-runtime/python/gnuradio/gr/CMakeLists.txt
@@ -29,11 +29,6 @@ if(ENABLE_TESTING)
set(GR_TEST_PYTHON_DIRS
${CMAKE_BINARY_DIR}/gruel/src/python
${CMAKE_BINARY_DIR}/gnuradio-runtime/python
- ${CMAKE_BINARY_DIR}/gnuradio-runtime/swig
- ${CMAKE_BINARY_DIR}/gr-blocks/swig
- ${CMAKE_BINARY_DIR}/gr-fft/swig
- ${CMAKE_BINARY_DIR}/gr-filter/swig
- ${CMAKE_BINARY_DIR}/gr-analog/swig
)
include(GrTest)
file(GLOB py_qa_test_files "qa_*.py")
@@ -42,3 +37,5 @@ if(ENABLE_TESTING)
GR_ADD_TEST(${py_qa_test_name} ${QA_PYTHON_EXECUTABLE} -B ${py_qa_test_file})
endforeach(py_qa_test_file)
endif(ENABLE_TESTING)
+
+add_subdirectory(bindings)
diff --git a/gnuradio-runtime/python/gnuradio/gr/__init__.py b/gnuradio-runtime/python/gnuradio/gr/__init__.py
index a1c1d3f397..2217907222 100644
--- a/gnuradio-runtime/python/gnuradio/gr/__init__.py
+++ b/gnuradio-runtime/python/gnuradio/gr/__init__.py
@@ -16,19 +16,19 @@ from __future__ import absolute_import
from __future__ import unicode_literals
# This is the main GNU Radio python module.
-# We pull the swig output and the other modules into the gnuradio.gr namespace
+# We pull the pybind output and the other modules into the gnuradio.gr namespace
-# If gnuradio is installed then the swig output will be in this directory.
-# Otherwise it will reside in ../../../swig.
+# If gnuradio is installed then the pybind output will be in this directory.
+# Otherwise it will reside in bindings/.
import os, sys
try:
- from .runtime_swig import *
+ from .gr_python import *
except ImportError:
dirname, filename = os.path.split(os.path.abspath(__file__))
- __path__.append(os.path.join(dirname, "..", "..", "..", "swig"))
- from .runtime_swig import *
+ __path__.append(os.path.join(dirname, "bindings"))
+ from .gr_python import *
from .exceptions import *
from .top_block import *
@@ -36,8 +36,8 @@ from .hier_block2 import *
from .tag_utils import *
from .gateway import basic_block, sync_block, decim_block, interp_block, py_io_signature
-# Force the preference database to be initialized
-prefs = prefs.singleton
+# # Force the preference database to be initialized
+# prefs = prefs.singleton
log = gr.logger("log")
log.set_level(prefs().get_string("LOG", "log_level", "notset"))
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/CMakeLists.txt b/gnuradio-runtime/python/gnuradio/gr/bindings/CMakeLists.txt
new file mode 100644
index 0000000000..a5704a0d90
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/CMakeLists.txt
@@ -0,0 +1,90 @@
+include(GrPybind)
+
+########################################################################
+# Python Bindings
+########################################################################
+
+list(APPEND gr_python_files
+messages/msg_accepter_msgq_python.cc
+messages/msg_accepter_python.cc
+messages/msg_passing_python.cc
+messages/msg_producer_python.cc
+messages/msg_queue_python.cc
+ # attributes_python.cc
+ basic_block_python.cc
+ block_python.cc
+ block_detail_python.cc
+ block_gateway_python.cc
+ # block_registry_python.cc
+ buffer_python.cc
+ constants_python.cc
+ endianness_python.cc
+ expj_python.cc
+ flowgraph_python.cc
+ fxpt_python.cc
+ fxpt_nco_python.cc
+ fxpt_vco_python.cc
+ # gr_complex_python.cc
+ hier_block2_python.cc
+ high_res_timer_python.cc
+ io_signature_python.cc
+ logger_python.cc
+ math_python.cc
+
+ message_python.cc
+ msg_accepter_python.cc
+ # msg_accepter_msgq_python.cc
+ # msg_passing_python.cc
+ # msg_producer_python.cc
+ msg_queue_python.cc
+ # misc_python.cc
+ msg_accepter_python.cc
+ msg_handler_python.cc
+ msg_queue_python.cc
+ nco_python.cc
+ prefs_python.cc
+ # pycallback_object_python.cc
+ random_python.cc
+ realtime_python.cc
+ # realtime_impl_python.cc
+ # rpcbufferedget_python.cc
+ # rpccallbackregister_base_python.cc
+ # rpcmanager_python.cc
+ # rpcmanager_base_python.cc
+ # rpcpmtconverters_thrift_python.cc
+ # rpcregisterhelpers_python.cc
+ # rpcserver_aggregator_python.cc
+ # rpcserver_base_python.cc
+ # rpcserver_booter_aggregator_python.cc
+ # rpcserver_booter_base_python.cc
+ # rpcserver_booter_thrift_python.cc
+ # rpcserver_selector_python.cc
+ # rpcserver_thrift_python.cc
+ runtime_types_python.cc
+ sincos_python.cc
+ sptr_magic_python.cc
+ sync_block_python.cc
+ sync_decimator_python.cc
+ sync_interpolator_python.cc
+ sys_paths_python.cc
+ tag_checker_python.cc
+ tagged_stream_block_python.cc
+ tags_python.cc
+ # thread_python.cc
+ # thread_body_wrapper_python.cc
+ # thread_group_python.cc
+ # thrift_application_base_python.cc
+ # thrift_server_template_python.cc
+ top_block_python.cc
+ tpb_detail_python.cc
+ # types_python.cc
+ # unittests_python.cc
+ # xoroshiro128p_python.cc
+ python_bindings.cc)
+
+GR_PYBIND_MAKE_CHECK_HASH(gr
+ ../../../..
+ gr::gr
+ "${gr_python_files}")
+
+install(TARGETS gr_python DESTINATION ${GR_PYTHON_DIR}/gnuradio/gr COMPONENT pythonapi)
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/basic_block_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/basic_block_python.cc
new file mode 100644
index 0000000000..f66019d0c2
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/basic_block_python.cc
@@ -0,0 +1,283 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(basic_block.h) */
+/* BINDTOOL_HEADER_FILE_HASH(549c06530e2afdf6f2c989017cb5f36e) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/basic_block.h>
+// pydoc.h is automatically generated in the build directory
+#include <basic_block_pydoc.h>
+
+void bind_basic_block(py::module& m)
+{
+
+ using basic_block = ::gr::basic_block;
+
+
+ py::class_<basic_block, gr::msg_accepter, std::shared_ptr<basic_block>>(
+ m, "basic_block", D(basic_block))
+
+
+ .def("message_subscribers",
+ &basic_block::message_subscribers,
+ py::arg("port"),
+ D(basic_block, message_subscribers))
+
+
+ .def("unique_id", &basic_block::unique_id, D(basic_block, unique_id))
+
+
+ .def("symbolic_id", &basic_block::symbolic_id, D(basic_block, symbolic_id))
+
+
+ .def("name", &basic_block::name, D(basic_block, name))
+
+
+ .def("symbol_name", &basic_block::symbol_name, D(basic_block, symbol_name))
+
+
+ .def("identifier", &basic_block::identifier, D(basic_block, identifier))
+
+
+ .def("input_signature",
+ &basic_block::input_signature,
+ D(basic_block, input_signature))
+
+
+ .def("output_signature",
+ &basic_block::output_signature,
+ D(basic_block, output_signature))
+
+
+ .def("to_basic_block",
+ &basic_block::to_basic_block,
+ D(basic_block, to_basic_block))
+
+
+ .def("alias_set", &basic_block::alias_set, D(basic_block, alias_set))
+
+
+ .def("alias", &basic_block::alias, D(basic_block, alias))
+
+
+ .def("alias_pmt", &basic_block::alias_pmt, D(basic_block, alias_pmt))
+
+
+ .def("set_block_alias",
+ &basic_block::set_block_alias,
+ py::arg("name"),
+ D(basic_block, set_block_alias))
+
+
+ .def("message_port_register_in",
+ &basic_block::message_port_register_in,
+ py::arg("port_id"),
+ D(basic_block, message_port_register_in))
+
+
+ .def("message_port_register_out",
+ &basic_block::message_port_register_out,
+ py::arg("port_id"),
+ D(basic_block, message_port_register_out))
+
+
+ .def("message_port_pub",
+ &basic_block::message_port_pub,
+ py::arg("port_id"),
+ py::arg("msg"),
+ D(basic_block, message_port_pub))
+
+
+ .def("message_port_sub",
+ &basic_block::message_port_sub,
+ py::arg("port_id"),
+ py::arg("target"),
+ D(basic_block, message_port_sub))
+
+
+ .def("message_port_unsub",
+ &basic_block::message_port_unsub,
+ py::arg("port_id"),
+ py::arg("target"),
+ D(basic_block, message_port_unsub))
+
+
+ .def("message_port_is_hier",
+ &basic_block::message_port_is_hier,
+ py::arg("port_id"),
+ D(basic_block, message_port_is_hier))
+
+
+ .def("message_port_is_hier_in",
+ &basic_block::message_port_is_hier_in,
+ py::arg("port_id"),
+ D(basic_block, message_port_is_hier_in))
+
+
+ .def("message_port_is_hier_out",
+ &basic_block::message_port_is_hier_out,
+ py::arg("port_id"),
+ D(basic_block, message_port_is_hier_out))
+
+
+ .def("message_ports_in",
+ &basic_block::message_ports_in,
+ D(basic_block, message_ports_in))
+
+
+ .def("message_ports_out",
+ &basic_block::message_ports_out,
+ D(basic_block, message_ports_out))
+
+
+ .def("_post",
+ &basic_block::_post,
+ py::arg("which_port"),
+ py::arg("msg"),
+ D(basic_block, _post))
+
+
+ .def("empty_p",
+ (bool (basic_block::*)(pmt::pmt_t)) & basic_block::empty_p,
+ py::arg("which_port"),
+ D(basic_block, empty_p, 0))
+
+
+ .def("empty_p",
+ (bool (basic_block::*)()) & basic_block::empty_p,
+ D(basic_block, empty_p, 1))
+
+
+ .def("empty_handled_p",
+ (bool (basic_block::*)(pmt::pmt_t)) & basic_block::empty_handled_p,
+ py::arg("which_port"),
+ D(basic_block, empty_handled_p, 0))
+
+
+ .def("empty_handled_p",
+ (bool (basic_block::*)()) & basic_block::empty_handled_p,
+ D(basic_block, empty_handled_p, 1))
+
+
+ .def("nmsgs", &basic_block::nmsgs, py::arg("which_port"), D(basic_block, nmsgs))
+
+
+ .def("insert_tail",
+ &basic_block::insert_tail,
+ py::arg("which_port"),
+ py::arg("msg"),
+ D(basic_block, insert_tail))
+
+
+ .def("delete_head_nowait",
+ &basic_block::delete_head_nowait,
+ py::arg("which_port"),
+ D(basic_block, delete_head_nowait))
+
+
+ .def("get_iterator",
+ &basic_block::get_iterator,
+ py::arg("which_port"),
+ D(basic_block, get_iterator))
+
+
+ .def("erase_msg",
+ &basic_block::erase_msg,
+ py::arg("which_port"),
+ py::arg("it"),
+ D(basic_block, erase_msg))
+
+
+ .def("has_msg_port",
+ &basic_block::has_msg_port,
+ py::arg("which_port"),
+ D(basic_block, has_msg_port))
+
+
+ .def("get_msg_map", &basic_block::get_msg_map, D(basic_block, get_msg_map))
+
+
+ // .def("add_rpc_variable",&basic_block::add_rpc_variable,
+ // py::arg("s"),
+ // D(basic_block,add_rpc_variable)
+ // )
+
+
+ // .def("setup_rpc",&basic_block::setup_rpc,
+ // D(basic_block,setup_rpc)
+ // )
+
+
+ // .def("is_rpc_set",&basic_block::is_rpc_set,
+ // D(basic_block,is_rpc_set)
+ // )
+
+
+ // .def("rpc_set",&basic_block::rpc_set,
+ // D(basic_block,rpc_set)
+ // )
+
+
+ .def("check_topology",
+ &basic_block::check_topology,
+ py::arg("ninputs"),
+ py::arg("noutputs"),
+ D(basic_block, check_topology))
+
+
+ .def("set_processor_affinity",
+ &basic_block::set_processor_affinity,
+ py::arg("mask"),
+ D(basic_block, set_processor_affinity))
+
+
+ .def("unset_processor_affinity",
+ &basic_block::unset_processor_affinity,
+ D(basic_block, unset_processor_affinity))
+
+
+ .def("processor_affinity",
+ &basic_block::processor_affinity,
+ D(basic_block, processor_affinity))
+
+
+ .def("set_log_level",
+ &basic_block::set_log_level,
+ py::arg("level"),
+ D(basic_block, set_log_level))
+
+
+ .def("log_level", &basic_block::log_level, D(basic_block, log_level))
+
+ ;
+
+
+ m.def("basic_block_ncurrently_allocated",
+ &::gr::basic_block_ncurrently_allocated,
+ D(basic_block_ncurrently_allocated));
+
+
+ py::module m_messages = m.def_submodule("messages");
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/block_detail_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/block_detail_python.cc
new file mode 100644
index 0000000000..219c95b153
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/block_detail_python.cc
@@ -0,0 +1,358 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(block_detail.h) */
+/* BINDTOOL_HEADER_FILE_HASH(274b4f673ac76cedd3ef6d466afab2fc) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/block_detail.h>
+#include <gnuradio/buffer.h>
+// pydoc.h is automatically generated in the build directory
+#include <block_detail_pydoc.h>
+
+void bind_block_detail(py::module& m)
+{
+
+ using block_detail = ::gr::block_detail;
+
+
+ py::class_<block_detail, std::shared_ptr<block_detail>>(
+ m, "block_detail", D(block_detail))
+
+
+ .def("ninputs", &block_detail::ninputs, D(block_detail, ninputs))
+
+
+ .def("noutputs", &block_detail::noutputs, D(block_detail, noutputs))
+
+
+ .def("sink_p", &block_detail::sink_p, D(block_detail, sink_p))
+
+
+ .def("source_p", &block_detail::source_p, D(block_detail, source_p))
+
+
+ .def("set_done",
+ &block_detail::set_done,
+ py::arg("done"),
+ D(block_detail, set_done))
+
+
+ .def("done", &block_detail::done, D(block_detail, done))
+
+
+ .def("set_input",
+ &block_detail::set_input,
+ py::arg("which"),
+ py::arg("reader"),
+ D(block_detail, set_input))
+
+
+ .def("input", &block_detail::input, py::arg("which"), D(block_detail, input))
+
+
+ .def("set_output",
+ &block_detail::set_output,
+ py::arg("which"),
+ py::arg("buffer"),
+ D(block_detail, set_output))
+
+
+ .def("output", &block_detail::output, py::arg("which"), D(block_detail, output))
+
+
+ .def("consume",
+ &block_detail::consume,
+ py::arg("which_input"),
+ py::arg("how_many_items"),
+ D(block_detail, consume))
+
+
+ .def("consume_each",
+ &block_detail::consume_each,
+ py::arg("how_many_items"),
+ D(block_detail, consume_each))
+
+
+ .def("produce",
+ &block_detail::produce,
+ py::arg("which_output"),
+ py::arg("how_many_items"),
+ D(block_detail, produce))
+
+
+ .def("produce_each",
+ &block_detail::produce_each,
+ py::arg("how_many_items"),
+ D(block_detail, produce_each))
+
+
+ .def("nitems_read",
+ &block_detail::nitems_read,
+ py::arg("which_input"),
+ D(block_detail, nitems_read))
+
+
+ .def("nitems_written",
+ &block_detail::nitems_written,
+ py::arg("which_output"),
+ D(block_detail, nitems_written))
+
+
+ .def("reset_nitem_counters",
+ &block_detail::reset_nitem_counters,
+ D(block_detail, reset_nitem_counters))
+
+
+ .def("clear_tags", &block_detail::clear_tags, D(block_detail, clear_tags))
+
+
+ .def("add_item_tag",
+ &block_detail::add_item_tag,
+ py::arg("which_output"),
+ py::arg("tag"),
+ D(block_detail, add_item_tag))
+
+
+ .def("remove_item_tag",
+ &block_detail::remove_item_tag,
+ py::arg("which_input"),
+ py::arg("tag"),
+ py::arg("id"),
+ D(block_detail, remove_item_tag))
+
+
+ .def("get_tags_in_range",
+ (void (block_detail::*)(std::vector<gr::tag_t, std::allocator<gr::tag_t>>&,
+ unsigned int,
+ uint64_t,
+ uint64_t,
+ long int)) &
+ block_detail::get_tags_in_range,
+ py::arg("v"),
+ py::arg("which_input"),
+ py::arg("abs_start"),
+ py::arg("abs_end"),
+ py::arg("id"),
+ D(block_detail, get_tags_in_range, 0))
+
+
+ .def("get_tags_in_range",
+ (void (block_detail::*)(std::vector<gr::tag_t, std::allocator<gr::tag_t>>&,
+ unsigned int,
+ uint64_t,
+ uint64_t,
+ pmt::pmt_t const&,
+ long int)) &
+ block_detail::get_tags_in_range,
+ py::arg("v"),
+ py::arg("which_input"),
+ py::arg("abs_start"),
+ py::arg("abs_end"),
+ py::arg("key"),
+ py::arg("id"),
+ D(block_detail, get_tags_in_range, 1))
+
+
+ .def("set_processor_affinity",
+ &block_detail::set_processor_affinity,
+ py::arg("mask"),
+ D(block_detail, set_processor_affinity))
+
+
+ .def("unset_processor_affinity",
+ &block_detail::unset_processor_affinity,
+ D(block_detail, unset_processor_affinity))
+
+
+ .def("thread_priority",
+ &block_detail::thread_priority,
+ D(block_detail, thread_priority))
+
+
+ .def("set_thread_priority",
+ &block_detail::set_thread_priority,
+ py::arg("priority"),
+ D(block_detail, set_thread_priority))
+
+
+ .def("start_perf_counters",
+ &block_detail::start_perf_counters,
+ D(block_detail, start_perf_counters))
+
+
+ .def("stop_perf_counters",
+ &block_detail::stop_perf_counters,
+ py::arg("noutput_items"),
+ py::arg("nproduced"),
+ D(block_detail, stop_perf_counters))
+
+
+ .def("reset_perf_counters",
+ &block_detail::reset_perf_counters,
+ D(block_detail, reset_perf_counters))
+
+
+ .def("pc_noutput_items",
+ &block_detail::pc_noutput_items,
+ D(block_detail, pc_noutput_items))
+
+
+ .def("pc_nproduced", &block_detail::pc_nproduced, D(block_detail, pc_nproduced))
+
+
+ .def("pc_input_buffers_full",
+ (float (block_detail::*)(size_t)) & block_detail::pc_input_buffers_full,
+ py::arg("which"),
+ D(block_detail, pc_input_buffers_full, 0))
+
+
+ .def("pc_input_buffers_full",
+ (std::vector<float, std::allocator<float>>(block_detail::*)()) &
+ block_detail::pc_input_buffers_full,
+ D(block_detail, pc_input_buffers_full, 1))
+
+
+ .def("pc_output_buffers_full",
+ (float (block_detail::*)(size_t)) & block_detail::pc_output_buffers_full,
+ py::arg("which"),
+ D(block_detail, pc_output_buffers_full, 0))
+
+
+ .def("pc_output_buffers_full",
+ (std::vector<float, std::allocator<float>>(block_detail::*)()) &
+ block_detail::pc_output_buffers_full,
+ D(block_detail, pc_output_buffers_full, 1))
+
+
+ .def("pc_work_time", &block_detail::pc_work_time, D(block_detail, pc_work_time))
+
+
+ .def("pc_noutput_items_avg",
+ &block_detail::pc_noutput_items_avg,
+ D(block_detail, pc_noutput_items_avg))
+
+
+ .def("pc_nproduced_avg",
+ &block_detail::pc_nproduced_avg,
+ D(block_detail, pc_nproduced_avg))
+
+
+ .def("pc_input_buffers_full_avg",
+ (float (block_detail::*)(size_t)) & block_detail::pc_input_buffers_full_avg,
+ py::arg("which"),
+ D(block_detail, pc_input_buffers_full_avg, 0))
+
+
+ .def("pc_input_buffers_full_avg",
+ (std::vector<float, std::allocator<float>>(block_detail::*)()) &
+ block_detail::pc_input_buffers_full_avg,
+ D(block_detail, pc_input_buffers_full_avg, 1))
+
+
+ .def("pc_output_buffers_full_avg",
+ (float (block_detail::*)(size_t)) & block_detail::pc_output_buffers_full_avg,
+ py::arg("which"),
+ D(block_detail, pc_output_buffers_full_avg, 0))
+
+
+ .def("pc_output_buffers_full_avg",
+ (std::vector<float, std::allocator<float>>(block_detail::*)()) &
+ block_detail::pc_output_buffers_full_avg,
+ D(block_detail, pc_output_buffers_full_avg, 1))
+
+
+ .def("pc_work_time_avg",
+ &block_detail::pc_work_time_avg,
+ D(block_detail, pc_work_time_avg))
+
+
+ .def("pc_throughput_avg",
+ &block_detail::pc_throughput_avg,
+ D(block_detail, pc_throughput_avg))
+
+
+ .def("pc_noutput_items_var",
+ &block_detail::pc_noutput_items_var,
+ D(block_detail, pc_noutput_items_var))
+
+
+ .def("pc_nproduced_var",
+ &block_detail::pc_nproduced_var,
+ D(block_detail, pc_nproduced_var))
+
+
+ .def("pc_input_buffers_full_var",
+ (float (block_detail::*)(size_t)) & block_detail::pc_input_buffers_full_var,
+ py::arg("which"),
+ D(block_detail, pc_input_buffers_full_var, 0))
+
+
+ .def("pc_input_buffers_full_var",
+ (std::vector<float, std::allocator<float>>(block_detail::*)()) &
+ block_detail::pc_input_buffers_full_var,
+ D(block_detail, pc_input_buffers_full_var, 1))
+
+
+ .def("pc_output_buffers_full_var",
+ (float (block_detail::*)(size_t)) & block_detail::pc_output_buffers_full_var,
+ py::arg("which"),
+ D(block_detail, pc_output_buffers_full_var, 0))
+
+
+ .def("pc_output_buffers_full_var",
+ (std::vector<float, std::allocator<float>>(block_detail::*)()) &
+ block_detail::pc_output_buffers_full_var,
+ D(block_detail, pc_output_buffers_full_var, 1))
+
+
+ .def("pc_work_time_var",
+ &block_detail::pc_work_time_var,
+ D(block_detail, pc_work_time_var))
+
+
+ .def("pc_work_time_total",
+ &block_detail::pc_work_time_total,
+ D(block_detail, pc_work_time_total))
+
+
+ .def("consumed", &block_detail::consumed, D(block_detail, consumed))
+
+ ;
+
+
+ m.def("make_block_detail",
+ &::gr::make_block_detail,
+ py::arg("ninputs"),
+ py::arg("noutputs"),
+ D(make_block_detail));
+
+
+ m.def("block_detail_ncurrently_allocated",
+ &::gr::block_detail_ncurrently_allocated,
+ D(block_detail_ncurrently_allocated));
+
+
+ py::module m_thread = m.def_submodule("thread");
+
+
+ py::module m_messages = m.def_submodule("messages");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/block_gateway_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/block_gateway_python.cc
new file mode 100644
index 0000000000..5766677bbe
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/block_gateway_python.cc
@@ -0,0 +1,96 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/block_gateway.h>
+
+void bind_block_gateway(py::module& m)
+{
+ using block_gateway = gr::block_gateway;
+ py::class_<block_gateway, gr::block, gr::basic_block, std::shared_ptr<block_gateway>>(
+ m, "block_gateway")
+
+ .def(py::init(&block_gateway::make),
+ py::arg("p"),
+ py::arg("name"),
+ py::arg("in_sig"),
+ py::arg("out_sig"))
+
+ .def("add_item_tag",
+ (void (block_gateway::*)(unsigned int, const gr::tag_t&)) &
+ block_gateway::_add_item_tag,
+ py::arg("which_output"),
+ py::arg("tag"))
+
+ .def("add_item_tag",
+ (void (block_gateway::*)(unsigned int,
+ uint64_t,
+ const pmt::pmt_t&,
+ const pmt::pmt_t&,
+ const pmt::pmt_t&)) &
+ block_gateway::_add_item_tag,
+ py::arg("which_output"),
+ py::arg("abs_offset"),
+ py::arg("key"),
+ py::arg("value"),
+ py::arg("srcid") = pmt::PMT_F)
+
+
+ .def(
+ "get_tags_in_range",
+ (std::vector<gr::tag_t>(block_gateway::*)(unsigned int, uint64_t, uint64_t)) &
+ block_gateway::_get_tags_in_range,
+ py::arg("which_input"),
+ py::arg("abs_start"),
+ py::arg("abs_end"))
+
+ .def("get_tags_in_range",
+ (std::vector<gr::tag_t>(block_gateway::*)(
+ unsigned int, uint64_t, uint64_t, const pmt::pmt_t&)) &
+ block_gateway::_get_tags_in_range,
+ py::arg("which_input"),
+ py::arg("abs_start"),
+ py::arg("abs_end"),
+ py::arg("key"))
+
+ .def(
+ "get_tags_in_window",
+ (std::vector<gr::tag_t>(block_gateway::*)(unsigned int, uint64_t, uint64_t)) &
+ block_gateway::_get_tags_in_range,
+ py::arg("which_input"),
+ py::arg("rel_start"),
+ py::arg("rel_end"))
+
+ .def("get_tags_in_window",
+ (std::vector<gr::tag_t>(block_gateway::*)(
+ unsigned int, uint64_t, uint64_t, const pmt::pmt_t&)) &
+ block_gateway::_get_tags_in_range,
+ py::arg("which_input"),
+ py::arg("rel_start"),
+ py::arg("rel_end"),
+ py::arg("key"))
+
+ .def("set_msg_handler_pybind",
+ &block_gateway::set_msg_handler_pybind,
+ py::arg("which_port"),
+ py::arg("handler_name"))
+
+ ;
+ py::enum_<gr::gw_block_t>(m, "gw_block_t")
+ .value("GW_BLOCK_GENERAL", gr::GW_BLOCK_GENERAL)
+ .value("GW_BLOCK_SYNC", gr::GW_BLOCK_SYNC)
+ .value("GW_BLOCK_DECIM", gr::GW_BLOCK_DECIM)
+ .value("GW_BLOCK_INTERP", gr::GW_BLOCK_INTERP)
+ .export_values();
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/block_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/block_python.cc
new file mode 100644
index 0000000000..56a172364f
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/block_python.cc
@@ -0,0 +1,501 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(block.h) */
+/* BINDTOOL_HEADER_FILE_HASH(3e181f6028976ba3727d29f45ebaa6cf) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/block.h>
+// pydoc.h is automatically generated in the build directory
+#include <gnuradio/block_detail.h>
+#include <block_pydoc.h>
+
+void bind_block(py::module& m)
+{
+
+ using block = ::gr::block;
+
+
+ py::class_<block, gr::basic_block, std::shared_ptr<block>>(m, "block", D(block))
+
+
+ .def("history", &block::history, D(block, history))
+
+
+ .def(
+ "set_history", &block::set_history, py::arg("history"), D(block, set_history))
+
+
+ .def("declare_sample_delay",
+ (void (block::*)(int, unsigned int)) & block::declare_sample_delay,
+ py::arg("which"),
+ py::arg("delay"),
+ D(block, declare_sample_delay, 0))
+
+
+ .def("declare_sample_delay",
+ (void (block::*)(unsigned int)) & block::declare_sample_delay,
+ py::arg("delay"),
+ D(block, declare_sample_delay, 1))
+
+
+ .def("sample_delay",
+ &block::sample_delay,
+ py::arg("which"),
+ D(block, sample_delay))
+
+
+ .def("fixed_rate", &block::fixed_rate, D(block, fixed_rate))
+
+
+ .def("forecast",
+ &block::forecast,
+ py::arg("noutput_items"),
+ py::arg("ninput_items_required"),
+ D(block, forecast))
+
+
+ .def("general_work",
+ &block::general_work,
+ py::arg("noutput_items"),
+ py::arg("ninput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(block, general_work))
+
+
+ .def("start", &block::start, D(block, start))
+
+
+ .def("stop", &block::stop, D(block, stop))
+
+
+ .def("set_output_multiple",
+ &block::set_output_multiple,
+ py::arg("multiple"),
+ D(block, set_output_multiple))
+
+
+ .def("output_multiple", &block::output_multiple, D(block, output_multiple))
+
+
+ .def("output_multiple_set",
+ &block::output_multiple_set,
+ D(block, output_multiple_set))
+
+
+ .def("set_alignment",
+ &block::set_alignment,
+ py::arg("multiple"),
+ D(block, set_alignment))
+
+
+ .def("alignment", &block::alignment, D(block, alignment))
+
+
+ .def("set_unaligned",
+ &block::set_unaligned,
+ py::arg("na"),
+ D(block, set_unaligned))
+
+
+ .def("unaligned", &block::unaligned, D(block, unaligned))
+
+
+ .def("set_is_unaligned",
+ &block::set_is_unaligned,
+ py::arg("u"),
+ D(block, set_is_unaligned))
+
+
+ .def("is_unaligned", &block::is_unaligned, D(block, is_unaligned))
+
+
+ .def("consume",
+ &block::consume,
+ py::arg("which_input"),
+ py::arg("how_many_items"),
+ D(block, consume))
+
+
+ .def("consume_each",
+ &block::consume_each,
+ py::arg("how_many_items"),
+ D(block, consume_each))
+
+
+ .def("produce",
+ &block::produce,
+ py::arg("which_output"),
+ py::arg("how_many_items"),
+ D(block, produce))
+
+
+ .def("set_relative_rate",
+ (void (block::*)(double)) & block::set_relative_rate,
+ py::arg("relative_rate"),
+ D(block, set_relative_rate, 0))
+
+
+ .def("set_inverse_relative_rate",
+ &block::set_inverse_relative_rate,
+ py::arg("inverse_relative_rate"),
+ D(block, set_inverse_relative_rate))
+
+
+ .def("set_relative_rate",
+ (void (block::*)(uint64_t, uint64_t)) & block::set_relative_rate,
+ py::arg("interpolation"),
+ py::arg("decimation"),
+ D(block, set_relative_rate, 1))
+
+
+ .def("relative_rate", &block::relative_rate, D(block, relative_rate))
+
+
+ .def("relative_rate_i", &block::relative_rate_i, D(block, relative_rate_i))
+
+
+ .def("relative_rate_d", &block::relative_rate_d, D(block, relative_rate_d))
+
+
+ .def("mp_relative_rate", &block::mp_relative_rate, D(block, mp_relative_rate))
+
+
+ .def("fixed_rate_ninput_to_noutput",
+ &block::fixed_rate_ninput_to_noutput,
+ py::arg("ninput"),
+ D(block, fixed_rate_ninput_to_noutput))
+
+
+ .def("fixed_rate_noutput_to_ninput",
+ &block::fixed_rate_noutput_to_ninput,
+ py::arg("noutput"),
+ D(block, fixed_rate_noutput_to_ninput))
+
+
+ .def("nitems_read",
+ &block::nitems_read,
+ py::arg("which_input"),
+ D(block, nitems_read))
+
+
+ .def("nitems_written",
+ &block::nitems_written,
+ py::arg("which_output"),
+ D(block, nitems_written))
+
+
+ .def("tag_propagation_policy",
+ &block::tag_propagation_policy,
+ D(block, tag_propagation_policy))
+
+
+ .def("set_tag_propagation_policy",
+ &block::set_tag_propagation_policy,
+ py::arg("p"),
+ D(block, set_tag_propagation_policy))
+
+
+ .def("min_noutput_items", &block::min_noutput_items, D(block, min_noutput_items))
+
+
+ .def("set_min_noutput_items",
+ &block::set_min_noutput_items,
+ py::arg("m"),
+ D(block, set_min_noutput_items))
+
+
+ .def("max_noutput_items", &block::max_noutput_items, D(block, max_noutput_items))
+
+
+ .def("set_max_noutput_items",
+ &block::set_max_noutput_items,
+ py::arg("m"),
+ D(block, set_max_noutput_items))
+
+
+ .def("unset_max_noutput_items",
+ &block::unset_max_noutput_items,
+ D(block, unset_max_noutput_items))
+
+
+ .def("is_set_max_noutput_items",
+ &block::is_set_max_noutput_items,
+ D(block, is_set_max_noutput_items))
+
+
+ .def("expand_minmax_buffer",
+ &block::expand_minmax_buffer,
+ py::arg("port"),
+ D(block, expand_minmax_buffer))
+
+
+ .def("max_output_buffer",
+ &block::max_output_buffer,
+ py::arg("i"),
+ D(block, max_output_buffer))
+
+
+ .def("set_max_output_buffer",
+ (void (block::*)(long int)) & block::set_max_output_buffer,
+ py::arg("max_output_buffer"),
+ D(block, set_max_output_buffer, 0))
+
+
+ .def("set_max_output_buffer",
+ (void (block::*)(int, long int)) & block::set_max_output_buffer,
+ py::arg("port"),
+ py::arg("max_output_buffer"),
+ D(block, set_max_output_buffer, 1))
+
+
+ .def("min_output_buffer",
+ &block::min_output_buffer,
+ py::arg("i"),
+ D(block, min_output_buffer))
+
+
+ .def("set_min_output_buffer",
+ (void (block::*)(long int)) & block::set_min_output_buffer,
+ py::arg("min_output_buffer"),
+ D(block, set_min_output_buffer, 0))
+
+
+ .def("set_min_output_buffer",
+ (void (block::*)(int, long int)) & block::set_min_output_buffer,
+ py::arg("port"),
+ py::arg("min_output_buffer"),
+ D(block, set_min_output_buffer, 1))
+
+
+ .def("pc_noutput_items", &block::pc_noutput_items, D(block, pc_noutput_items))
+
+
+ .def("pc_noutput_items_avg",
+ &block::pc_noutput_items_avg,
+ D(block, pc_noutput_items_avg))
+
+
+ .def("pc_noutput_items_var",
+ &block::pc_noutput_items_var,
+ D(block, pc_noutput_items_var))
+
+
+ .def("pc_nproduced", &block::pc_nproduced, D(block, pc_nproduced))
+
+
+ .def("pc_nproduced_avg", &block::pc_nproduced_avg, D(block, pc_nproduced_avg))
+
+
+ .def("pc_nproduced_var", &block::pc_nproduced_var, D(block, pc_nproduced_var))
+
+
+ .def("pc_input_buffers_full",
+ (float (block::*)(int)) & block::pc_input_buffers_full,
+ py::arg("which"),
+ D(block, pc_input_buffers_full, 0))
+
+
+ .def("pc_input_buffers_full_avg",
+ (float (block::*)(int)) & block::pc_input_buffers_full_avg,
+ py::arg("which"),
+ D(block, pc_input_buffers_full_avg, 0))
+
+
+ .def("pc_input_buffers_full_var",
+ (float (block::*)(int)) & block::pc_input_buffers_full_var,
+ py::arg("which"),
+ D(block, pc_input_buffers_full_var, 0))
+
+
+ .def("pc_input_buffers_full",
+ (std::vector<float, std::allocator<float>>(block::*)()) &
+ block::pc_input_buffers_full,
+ D(block, pc_input_buffers_full, 1))
+
+
+ .def("pc_input_buffers_full_avg",
+ (std::vector<float, std::allocator<float>>(block::*)()) &
+ block::pc_input_buffers_full_avg,
+ D(block, pc_input_buffers_full_avg, 1))
+
+
+ .def("pc_input_buffers_full_var",
+ (std::vector<float, std::allocator<float>>(block::*)()) &
+ block::pc_input_buffers_full_var,
+ D(block, pc_input_buffers_full_var, 1))
+
+
+ .def("pc_output_buffers_full",
+ (float (block::*)(int)) & block::pc_output_buffers_full,
+ py::arg("which"),
+ D(block, pc_output_buffers_full, 0))
+
+
+ .def("pc_output_buffers_full_avg",
+ (float (block::*)(int)) & block::pc_output_buffers_full_avg,
+ py::arg("which"),
+ D(block, pc_output_buffers_full_avg, 0))
+
+
+ .def("pc_output_buffers_full_var",
+ (float (block::*)(int)) & block::pc_output_buffers_full_var,
+ py::arg("which"),
+ D(block, pc_output_buffers_full_var, 0))
+
+
+ .def("pc_output_buffers_full",
+ (std::vector<float, std::allocator<float>>(block::*)()) &
+ block::pc_output_buffers_full,
+ D(block, pc_output_buffers_full, 1))
+
+
+ .def("pc_output_buffers_full_avg",
+ (std::vector<float, std::allocator<float>>(block::*)()) &
+ block::pc_output_buffers_full_avg,
+ D(block, pc_output_buffers_full_avg, 1))
+
+
+ .def("pc_output_buffers_full_var",
+ (std::vector<float, std::allocator<float>>(block::*)()) &
+ block::pc_output_buffers_full_var,
+ D(block, pc_output_buffers_full_var, 1))
+
+
+ .def("pc_work_time", &block::pc_work_time, D(block, pc_work_time))
+
+
+ .def("pc_work_time_avg", &block::pc_work_time_avg, D(block, pc_work_time_avg))
+
+
+ .def("pc_work_time_var", &block::pc_work_time_var, D(block, pc_work_time_var))
+
+
+ .def("pc_work_time_total",
+ &block::pc_work_time_total,
+ D(block, pc_work_time_total))
+
+
+ .def("pc_throughput_avg", &block::pc_throughput_avg, D(block, pc_throughput_avg))
+
+
+ .def("reset_perf_counters",
+ &block::reset_perf_counters,
+ D(block, reset_perf_counters))
+
+
+ .def("setup_pc_rpc", &block::setup_pc_rpc, D(block, setup_pc_rpc))
+
+
+ .def("is_pc_rpc_set", &block::is_pc_rpc_set, D(block, is_pc_rpc_set))
+
+
+ .def("no_pc_rpc", &block::no_pc_rpc, D(block, no_pc_rpc))
+
+
+ .def("set_processor_affinity",
+ &block::set_processor_affinity,
+ py::arg("mask"),
+ D(block, set_processor_affinity))
+
+
+ .def("unset_processor_affinity",
+ &block::unset_processor_affinity,
+ D(block, unset_processor_affinity))
+
+
+ .def("processor_affinity",
+ &block::processor_affinity,
+ D(block, processor_affinity))
+
+
+ .def("active_thread_priority",
+ &block::active_thread_priority,
+ D(block, active_thread_priority))
+
+
+ .def("thread_priority", &block::thread_priority, D(block, thread_priority))
+
+
+ .def("set_thread_priority",
+ &block::set_thread_priority,
+ py::arg("priority"),
+ D(block, set_thread_priority))
+
+
+ .def("update_rate", &block::update_rate, D(block, update_rate))
+
+
+ .def("system_handler",
+ &block::system_handler,
+ py::arg("msg"),
+ D(block, system_handler))
+
+
+ .def("set_log_level",
+ &block::set_log_level,
+ py::arg("level"),
+ D(block, set_log_level))
+
+
+ .def("log_level", &block::log_level, D(block, log_level))
+
+
+ .def("finished", &block::finished, D(block, finished))
+
+
+ .def("detail", &block::detail, D(block, detail))
+
+
+ .def("set_detail", &block::set_detail, py::arg("detail"), D(block, set_detail))
+
+
+ .def("notify_msg_neighbors",
+ &block::notify_msg_neighbors,
+ D(block, notify_msg_neighbors))
+
+
+ .def("clear_finished", &block::clear_finished, D(block, clear_finished))
+
+
+ .def("identifier", &block::identifier, D(block, identifier))
+
+ ;
+
+
+ m.def("cast_to_block_sptr",
+ &::gr::cast_to_block_sptr,
+ py::arg("p"),
+ D(cast_to_block_sptr));
+
+
+ py::enum_<gr::block::work_return_t>(m, "work_return_t")
+ .value("WORK_CALLED_PRODUCE", gr::block::WORK_CALLED_PRODUCE) // -2
+ .value("WORK_DONE", gr::block::WORK_DONE) // -1
+ .export_values();
+ py::enum_<gr::block::tag_propagation_policy_t>(m, "tag_propagation_policy_t")
+ .value("TPP_DONT", gr::block::TPP_DONT) // 0
+ .value("TPP_ALL_TO_ALL", gr::block::TPP_ALL_TO_ALL) // 1
+ .value("TPP_ONE_TO_ONE", gr::block::TPP_ONE_TO_ONE) // 2
+ .value("TPP_CUSTOM", gr::block::TPP_CUSTOM) // 3
+ .export_values();
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/buffer_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/buffer_python.cc
new file mode 100644
index 0000000000..ef51929d6c
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/buffer_python.cc
@@ -0,0 +1,234 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(buffer.h) */
+/* BINDTOOL_HEADER_FILE_HASH(825bd18ddcab10552de6f9162a6aae3e) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/block.h>
+#include <gnuradio/buffer.h>
+// pydoc.h is automatically generated in the build directory
+#include <buffer_pydoc.h>
+
+void bind_buffer(py::module& m)
+{
+
+ using buffer = ::gr::buffer;
+ using buffer_reader = ::gr::buffer_reader;
+
+
+ py::class_<buffer, std::shared_ptr<buffer>>(m, "buffer", D(buffer))
+
+
+ .def("space_available", &buffer::space_available, D(buffer, space_available))
+
+
+ .def("bufsize", &buffer::bufsize, D(buffer, bufsize))
+
+
+ .def("base", &buffer::base, D(buffer, base))
+
+
+ .def("write_pointer", &buffer::write_pointer, D(buffer, write_pointer))
+
+
+ .def("update_write_pointer",
+ &buffer::update_write_pointer,
+ py::arg("nitems"),
+ D(buffer, update_write_pointer))
+
+
+ .def("set_done", &buffer::set_done, py::arg("done"), D(buffer, set_done))
+
+
+ .def("done", &buffer::done, D(buffer, done))
+
+
+ .def("link", &buffer::link, D(buffer, link))
+
+
+ .def("nreaders", &buffer::nreaders, D(buffer, nreaders))
+
+
+ .def("reader", &buffer::reader, py::arg("index"), D(buffer, reader))
+
+
+ .def("mutex", &buffer::mutex, D(buffer, mutex))
+
+
+ .def("nitems_written", &buffer::nitems_written, D(buffer, nitems_written))
+
+
+ .def("reset_nitem_counter",
+ &buffer::reset_nitem_counter,
+ D(buffer, reset_nitem_counter))
+
+
+ .def("get_sizeof_item", &buffer::get_sizeof_item, D(buffer, get_sizeof_item))
+
+
+ .def("add_item_tag",
+ &buffer::add_item_tag,
+ py::arg("tag"),
+ D(buffer, add_item_tag))
+
+
+ .def("remove_item_tag",
+ &buffer::remove_item_tag,
+ py::arg("tag"),
+ py::arg("id"),
+ D(buffer, remove_item_tag))
+
+
+ .def(
+ "prune_tags", &buffer::prune_tags, py::arg("max_time"), D(buffer, prune_tags))
+
+
+ .def("get_tags_begin", &buffer::get_tags_begin, D(buffer, get_tags_begin))
+
+
+ .def("get_tags_end", &buffer::get_tags_end, D(buffer, get_tags_end))
+
+
+ .def("get_tags_lower_bound",
+ &buffer::get_tags_lower_bound,
+ py::arg("x"),
+ D(buffer, get_tags_lower_bound))
+
+
+ .def("get_tags_upper_bound",
+ &buffer::get_tags_upper_bound,
+ py::arg("x"),
+ D(buffer, get_tags_upper_bound))
+
+ ;
+
+
+ py::class_<buffer_reader, std::shared_ptr<buffer_reader>>(
+ m, "buffer_reader", D(buffer_reader))
+
+ .def(py::init<gr::buffer_reader const&>(),
+ py::arg("arg0"),
+ D(buffer_reader, buffer_reader))
+
+
+ .def("declare_sample_delay",
+ &buffer_reader::declare_sample_delay,
+ py::arg("delay"),
+ D(buffer_reader, declare_sample_delay))
+
+
+ .def("sample_delay", &buffer_reader::sample_delay, D(buffer_reader, sample_delay))
+
+
+ .def("items_available",
+ &buffer_reader::items_available,
+ D(buffer_reader, items_available))
+
+
+ .def("buffer", &buffer_reader::buffer, D(buffer_reader, buffer))
+
+
+ .def("max_possible_items_available",
+ &buffer_reader::max_possible_items_available,
+ D(buffer_reader, max_possible_items_available))
+
+
+ .def("read_pointer", &buffer_reader::read_pointer, D(buffer_reader, read_pointer))
+
+
+ .def("update_read_pointer",
+ &buffer_reader::update_read_pointer,
+ py::arg("nitems"),
+ D(buffer_reader, update_read_pointer))
+
+
+ .def("set_done",
+ &buffer_reader::set_done,
+ py::arg("done"),
+ D(buffer_reader, set_done))
+
+
+ .def("done", &buffer_reader::done, D(buffer_reader, done))
+
+
+ .def("mutex", &buffer_reader::mutex, D(buffer_reader, mutex))
+
+
+ .def("nitems_read", &buffer_reader::nitems_read, D(buffer_reader, nitems_read))
+
+
+ .def("reset_nitem_counter",
+ &buffer_reader::reset_nitem_counter,
+ D(buffer_reader, reset_nitem_counter))
+
+
+ .def("get_sizeof_item",
+ &buffer_reader::get_sizeof_item,
+ D(buffer_reader, get_sizeof_item))
+
+
+ .def("link", &buffer_reader::link, D(buffer_reader, link))
+
+
+ .def("get_tags_in_range",
+ &buffer_reader::get_tags_in_range,
+ py::arg("v"),
+ py::arg("abs_start"),
+ py::arg("abs_end"),
+ py::arg("id"),
+ D(buffer_reader, get_tags_in_range))
+
+ ;
+
+
+ m.def("make_buffer",
+ &::gr::make_buffer,
+ py::arg("nitems"),
+ py::arg("sizeof_item"),
+ py::arg("link") = gr::block_sptr(),
+ D(make_buffer));
+
+
+ m.def("buffer_add_reader",
+ &::gr::buffer_add_reader,
+ py::arg("buf"),
+ py::arg("nzero_preload"),
+ py::arg("link") = gr::block_sptr(),
+ py::arg("delay") = 0,
+ D(buffer_add_reader));
+
+
+ m.def("buffer_ncurrently_allocated",
+ &::gr::buffer_ncurrently_allocated,
+ D(buffer_ncurrently_allocated));
+
+
+ m.def("buffer_reader_ncurrently_allocated",
+ &::gr::buffer_reader_ncurrently_allocated,
+ D(buffer_reader_ncurrently_allocated));
+
+
+ py::module m_thread = m.def_submodule("thread");
+
+
+ py::module m_messages = m.def_submodule("messages");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc
new file mode 100644
index 0000000000..e2624e808d
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/constants_python.cc
@@ -0,0 +1,70 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(constants.h) */
+/* BINDTOOL_HEADER_FILE_HASH(d98c7e72cb74921e5e07f332dbf5475a) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/constants.h>
+// pydoc.h is automatically generated in the build directory
+#include <constants_pydoc.h>
+
+void bind_constants(py::module& m)
+{
+
+
+ m.def("prefix", &::gr::prefix, D(prefix));
+
+
+ m.def("sysconfdir", &::gr::sysconfdir, D(sysconfdir));
+
+
+ m.def("prefsdir", &::gr::prefsdir, D(prefsdir));
+
+
+ m.def("build_date", &::gr::build_date, D(build_date));
+
+
+ m.def("version", &::gr::version, D(version));
+
+
+ m.def("major_version", &::gr::major_version, D(major_version));
+
+
+ m.def("api_version", &::gr::api_version, D(api_version));
+
+
+ m.def("minor_version", &::gr::minor_version, D(minor_version));
+
+
+ m.def("c_compiler", &::gr::c_compiler, D(c_compiler));
+
+
+ m.def("cxx_compiler", &::gr::cxx_compiler, D(cxx_compiler));
+
+
+ m.def("compiler_flags", &::gr::compiler_flags, D(compiler_flags));
+
+
+ m.def("build_time_enabled_components",
+ &::gr::build_time_enabled_components,
+ D(build_time_enabled_components));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/basic_block_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/basic_block_pydoc_template.h
new file mode 100644
index 0000000000..f51175f1b6
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/basic_block_pydoc_template.h
@@ -0,0 +1,156 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_basic_block = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_subscribers = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_unique_id = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_symbolic_id = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_name = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_symbol_name = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_identifier = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_input_signature = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_output_signature = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_to_basic_block = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_alias_set = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_alias = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_alias_pmt = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_set_block_alias = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_register_in = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_register_out = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_pub = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_sub = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_unsub = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_is_hier = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_is_hier_in = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_port_is_hier_out = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_ports_in = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_message_ports_out = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block__post = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_empty_p_0 = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_empty_p_1 = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_empty_handled_p_0 = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_empty_handled_p_1 = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_nmsgs = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_insert_tail = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_delete_head_nowait = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_get_iterator = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_erase_msg = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_has_msg_port = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_get_msg_map = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_add_rpc_variable = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_setup_rpc = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_is_rpc_set = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_rpc_set = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_check_topology = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_set_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_unset_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_set_log_level = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_log_level = R"doc()doc";
+
+
+static const char* __doc_gr_basic_block_ncurrently_allocated = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_detail_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_detail_pydoc_template.h
new file mode 100644
index 0000000000..eb010d04a4
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_detail_pydoc_template.h
@@ -0,0 +1,183 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_block_detail = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_ninputs = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_noutputs = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_sink_p = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_source_p = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_set_done = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_done = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_set_input = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_input = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_set_output = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_output = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_consume = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_consume_each = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_produce = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_produce_each = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_nitems_read = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_nitems_written = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_reset_nitem_counters = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_clear_tags = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_add_item_tag = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_remove_item_tag = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_get_tags_in_range_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_get_tags_in_range_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_set_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_unset_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_thread_priority = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_set_thread_priority = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_start_perf_counters = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_stop_perf_counters = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_reset_perf_counters = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_nproduced = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_input_buffers_full_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_input_buffers_full_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_output_buffers_full_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_output_buffers_full_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_work_time = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_noutput_items_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_nproduced_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_input_buffers_full_avg_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_input_buffers_full_avg_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_output_buffers_full_avg_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_output_buffers_full_avg_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_work_time_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_throughput_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_noutput_items_var = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_nproduced_var = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_input_buffers_full_var_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_input_buffers_full_var_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_output_buffers_full_var_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_output_buffers_full_var_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_work_time_var = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_pc_work_time_total = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_consumed = R"doc()doc";
+
+
+static const char* __doc_gr_make_block_detail = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail_ncurrently_allocated = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_pydoc_template.h
new file mode 100644
index 0000000000..d60a699fec
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/block_pydoc_template.h
@@ -0,0 +1,294 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_block = R"doc()doc";
+
+
+static const char* __doc_gr_block_history = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_history = R"doc()doc";
+
+
+static const char* __doc_gr_block_declare_sample_delay_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_declare_sample_delay_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_sample_delay = R"doc()doc";
+
+
+static const char* __doc_gr_block_fixed_rate = R"doc()doc";
+
+
+static const char* __doc_gr_block_forecast = R"doc()doc";
+
+
+static const char* __doc_gr_block_general_work = R"doc()doc";
+
+
+static const char* __doc_gr_block_start = R"doc()doc";
+
+
+static const char* __doc_gr_block_stop = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_output_multiple = R"doc()doc";
+
+
+static const char* __doc_gr_block_output_multiple = R"doc()doc";
+
+
+static const char* __doc_gr_block_output_multiple_set = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_alignment = R"doc()doc";
+
+
+static const char* __doc_gr_block_alignment = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_unaligned = R"doc()doc";
+
+
+static const char* __doc_gr_block_unaligned = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_is_unaligned = R"doc()doc";
+
+
+static const char* __doc_gr_block_is_unaligned = R"doc()doc";
+
+
+static const char* __doc_gr_block_consume = R"doc()doc";
+
+
+static const char* __doc_gr_block_consume_each = R"doc()doc";
+
+
+static const char* __doc_gr_block_produce = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_relative_rate_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_inverse_relative_rate = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_relative_rate_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_relative_rate = R"doc()doc";
+
+
+static const char* __doc_gr_block_relative_rate_i = R"doc()doc";
+
+
+static const char* __doc_gr_block_relative_rate_d = R"doc()doc";
+
+
+static const char* __doc_gr_block_mp_relative_rate = R"doc()doc";
+
+
+static const char* __doc_gr_block_fixed_rate_ninput_to_noutput = R"doc()doc";
+
+
+static const char* __doc_gr_block_fixed_rate_noutput_to_ninput = R"doc()doc";
+
+
+static const char* __doc_gr_block_nitems_read = R"doc()doc";
+
+
+static const char* __doc_gr_block_nitems_written = R"doc()doc";
+
+
+static const char* __doc_gr_block_tag_propagation_policy = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_tag_propagation_policy = R"doc()doc";
+
+
+static const char* __doc_gr_block_min_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_min_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_max_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_max_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_unset_max_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_is_set_max_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_expand_minmax_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_block_max_output_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_max_output_buffer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_max_output_buffer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_min_output_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_min_output_buffer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_min_output_buffer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_noutput_items_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_noutput_items_var = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_nproduced = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_nproduced_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_nproduced_var = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_input_buffers_full_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_input_buffers_full_avg_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_input_buffers_full_var_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_input_buffers_full_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_input_buffers_full_avg_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_input_buffers_full_var_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_output_buffers_full_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_output_buffers_full_avg_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_output_buffers_full_var_0 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_output_buffers_full_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_output_buffers_full_avg_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_output_buffers_full_var_1 = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_work_time = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_work_time_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_work_time_var = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_work_time_total = R"doc()doc";
+
+
+static const char* __doc_gr_block_pc_throughput_avg = R"doc()doc";
+
+
+static const char* __doc_gr_block_reset_perf_counters = R"doc()doc";
+
+
+static const char* __doc_gr_block_setup_pc_rpc = R"doc()doc";
+
+
+static const char* __doc_gr_block_is_pc_rpc_set = R"doc()doc";
+
+
+static const char* __doc_gr_block_no_pc_rpc = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_block_unset_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_block_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_block_active_thread_priority = R"doc()doc";
+
+
+static const char* __doc_gr_block_thread_priority = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_thread_priority = R"doc()doc";
+
+
+static const char* __doc_gr_block_update_rate = R"doc()doc";
+
+
+static const char* __doc_gr_block_system_handler = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_log_level = R"doc()doc";
+
+
+static const char* __doc_gr_block_log_level = R"doc()doc";
+
+
+static const char* __doc_gr_block_finished = R"doc()doc";
+
+
+static const char* __doc_gr_block_detail = R"doc()doc";
+
+
+static const char* __doc_gr_block_set_detail = R"doc()doc";
+
+
+static const char* __doc_gr_block_notify_msg_neighbors = R"doc()doc";
+
+
+static const char* __doc_gr_block_clear_finished = R"doc()doc";
+
+
+static const char* __doc_gr_block_identifier = R"doc()doc";
+
+
+static const char* __doc_gr_cast_to_block_sptr = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/buffer_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/buffer_pydoc_template.h
new file mode 100644
index 0000000000..72aec93fa9
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/buffer_pydoc_template.h
@@ -0,0 +1,144 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_space_available = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_bufsize = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_base = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_write_pointer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_update_write_pointer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_set_done = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_done = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_link = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_nreaders = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_mutex = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_nitems_written = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reset_nitem_counter = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_get_sizeof_item = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_add_item_tag = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_remove_item_tag = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_prune_tags = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_get_tags_begin = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_get_tags_end = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_get_tags_lower_bound = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_get_tags_upper_bound = R"doc()doc";
+
+
+// static const char *__doc_gr_buffer_reader = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_buffer_reader = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_declare_sample_delay = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_sample_delay = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_items_available = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_max_possible_items_available = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_read_pointer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_update_read_pointer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_set_done = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_done = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_mutex = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_nitems_read = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_reset_nitem_counter = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_get_sizeof_item = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_link = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_get_tags_in_range = R"doc()doc";
+
+
+static const char* __doc_gr_make_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_add_reader = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_ncurrently_allocated = R"doc()doc";
+
+
+static const char* __doc_gr_buffer_reader_ncurrently_allocated = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/constants_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/constants_pydoc_template.h
new file mode 100644
index 0000000000..4ac45ae049
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/constants_pydoc_template.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_prefix = R"doc()doc";
+
+
+static const char* __doc_gr_sysconfdir = R"doc()doc";
+
+
+static const char* __doc_gr_prefsdir = R"doc()doc";
+
+
+static const char* __doc_gr_build_date = R"doc()doc";
+
+
+static const char* __doc_gr_version = R"doc()doc";
+
+
+static const char* __doc_gr_major_version = R"doc()doc";
+
+
+static const char* __doc_gr_api_version = R"doc()doc";
+
+
+static const char* __doc_gr_minor_version = R"doc()doc";
+
+
+static const char* __doc_gr_c_compiler = R"doc()doc";
+
+
+static const char* __doc_gr_cxx_compiler = R"doc()doc";
+
+
+static const char* __doc_gr_compiler_flags = R"doc()doc";
+
+
+static const char* __doc_gr_build_time_enabled_components = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/endianness_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/endianness_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/endianness_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/expj_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/expj_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/expj_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/flowgraph_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/flowgraph_pydoc_template.h
new file mode 100644
index 0000000000..ff54686a4a
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/flowgraph_pydoc_template.h
@@ -0,0 +1,156 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_flowgraph = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_flowgraph = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_connect_0 = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_disconnect_0 = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_connect_1 = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_disconnect_1 = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_connect_2 = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_disconnect_2 = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_validate = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_clear = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_edges = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_msg_edges = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_calc_used_blocks = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_topological_sort = R"doc()doc";
+
+
+static const char* __doc_gr_flowgraph_partition = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint_endpoint_0 = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint_endpoint_1 = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint_endpoint_2 = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint_block = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint_port = R"doc()doc";
+
+
+static const char* __doc_gr_endpoint_identifier = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_msg_endpoint_0 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_msg_endpoint_1 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_msg_endpoint_2 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_block = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_port = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_is_hier = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_set_hier = R"doc()doc";
+
+
+static const char* __doc_gr_msg_endpoint_identifier = R"doc()doc";
+
+
+static const char* __doc_gr_edge = R"doc()doc";
+
+
+static const char* __doc_gr_edge_edge_0 = R"doc()doc";
+
+
+static const char* __doc_gr_edge_edge_1 = R"doc()doc";
+
+
+static const char* __doc_gr_edge_edge_2 = R"doc()doc";
+
+
+static const char* __doc_gr_edge_src = R"doc()doc";
+
+
+static const char* __doc_gr_edge_dst = R"doc()doc";
+
+
+static const char* __doc_gr_edge_identifier = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge_msg_edge_0 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge_msg_edge_1 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge_msg_edge_2 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge_src = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge_dst = R"doc()doc";
+
+
+static const char* __doc_gr_msg_edge_identifier = R"doc()doc";
+
+
+static const char* __doc_gr_make_flowgraph = R"doc()doc";
+
+
+static const char* __doc_gr_dot_graph_fg = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_nco_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_nco_pydoc_template.h
new file mode 100644
index 0000000000..a3724fc645
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_nco_pydoc_template.h
@@ -0,0 +1,84 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_fxpt_nco = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_fxpt_nco_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_fxpt_nco_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_set_phase = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_adjust_phase = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_set_freq = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_adjust_freq = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_step_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_step_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_get_phase = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_get_freq = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sincos_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sincos_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sin_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_cos_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sin_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_cos_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sin_2 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_cos_2 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sin_3 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_cos_3 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_cos_4 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_nco_sin_4 = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_pydoc_template.h
new file mode 100644
index 0000000000..1631008d09
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_pydoc_template.h
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_fxpt = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_fxpt_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_fxpt_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_float_to_fixed = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_fixed_to_float = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_sin = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_cos = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_sincos = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_vco_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_vco_pydoc_template.h
new file mode 100644
index 0000000000..1d8b91e973
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/fxpt_vco_pydoc_template.h
@@ -0,0 +1,48 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_fxpt_vco = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_fxpt_vco_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_fxpt_vco_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_set_phase = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_adjust_phase = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_get_phase = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_sincos_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_sincos_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_cos_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_cos_1 = R"doc()doc";
+
+
+static const char* __doc_gr_fxpt_vco_sin = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/hier_block2_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/hier_block2_pydoc_template.h
new file mode 100644
index 0000000000..6c51aba45d
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/hier_block2_pydoc_template.h
@@ -0,0 +1,126 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_hier_block2 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_self = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_connect_0 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_connect_1 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_msg_connect_0 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_msg_connect_1 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_msg_disconnect_0 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_msg_disconnect_1 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_disconnect_0 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_disconnect_1 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_disconnect_all = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_lock = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_unlock = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_max_output_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_set_max_output_buffer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_set_max_output_buffer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_min_output_buffer = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_set_min_output_buffer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_set_min_output_buffer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_flatten = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_to_hier_block2 = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_has_msg_port = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_message_port_is_hier = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_message_port_is_hier_in = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_message_port_is_hier_out = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_message_port_register_hier_in = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_message_port_register_hier_out = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_set_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_unset_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_processor_affinity = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_set_log_level = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_log_level = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_all_min_output_buffer_p = R"doc()doc";
+
+
+static const char* __doc_gr_hier_block2_all_max_output_buffer_p = R"doc()doc";
+
+
+static const char* __doc_gr_make_hier_block2 = R"doc()doc";
+
+
+static const char* __doc_gr_dot_graph = R"doc()doc";
+
+
+static const char* __doc_gr_cast_to_hier_block2_sptr = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/high_res_timer_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/high_res_timer_pydoc_template.h
new file mode 100644
index 0000000000..55409413f7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/high_res_timer_pydoc_template.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_high_res_timer_now = R"doc()doc";
+
+
+static const char* __doc_gr_high_res_timer_now_perfmon = R"doc()doc";
+
+
+static const char* __doc_gr_high_res_timer_tps = R"doc()doc";
+
+
+static const char* __doc_gr_high_res_timer_epoch = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/io_signature_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/io_signature_pydoc_template.h
new file mode 100644
index 0000000000..643f6a3653
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/io_signature_pydoc_template.h
@@ -0,0 +1,45 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_io_signature = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_io_signature = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_make = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_make2 = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_make3 = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_makev = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_min_streams = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_max_streams = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_sizeof_stream_item = R"doc()doc";
+
+
+static const char* __doc_gr_io_signature_sizeof_stream_items = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/logger_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/logger_pydoc_template.h
new file mode 100644
index 0000000000..84d2e5e9cf
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/logger_pydoc_template.h
@@ -0,0 +1,147 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_logger = R"doc()doc";
+
+
+static const char* __doc_gr_logger_logger_0 = R"doc()doc";
+
+
+static const char* __doc_gr_logger_logger_1 = R"doc()doc";
+
+
+static const char* __doc_gr_logger_set_level = R"doc()doc";
+
+
+static const char* __doc_gr_logger_get_level = R"doc()doc";
+
+
+static const char* __doc_gr_logger_debug = R"doc()doc";
+
+
+static const char* __doc_gr_logger_info = R"doc()doc";
+
+
+static const char* __doc_gr_logger_notice = R"doc()doc";
+
+
+static const char* __doc_gr_logger_warn = R"doc()doc";
+
+
+static const char* __doc_gr_logger_error = R"doc()doc";
+
+
+static const char* __doc_gr_logger_crit = R"doc()doc";
+
+
+static const char* __doc_gr_logger_alert = R"doc()doc";
+
+
+static const char* __doc_gr_logger_fatal = R"doc()doc";
+
+
+static const char* __doc_gr_logger_emerg = R"doc()doc";
+
+
+static const char* __doc_gr_logger_errorIF = R"doc()doc";
+
+
+static const char* __doc_gr_logger_log_assert = R"doc()doc";
+
+
+static const char* __doc_gr_logger_add_console_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_set_console_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_add_file_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_set_file_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_add_rollingfile_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_config = R"doc()doc";
+
+
+static const char* __doc_gr_logger_config_get_filename = R"doc()doc";
+
+
+static const char* __doc_gr_logger_config_get_watch_period = R"doc()doc";
+
+
+static const char* __doc_gr_logger_config_load_config = R"doc()doc";
+
+
+static const char* __doc_gr_logger_config_stop_watch = R"doc()doc";
+
+
+static const char* __doc_gr_logger_config_reset_config = R"doc()doc";
+
+
+static const char* __doc_gr_configure_default_loggers = R"doc()doc";
+
+
+static const char* __doc_gr_update_logger_alias = R"doc()doc";
+
+
+static const char* __doc_gr_logger_get_logger = R"doc()doc";
+
+
+static const char* __doc_gr_logger_load_config = R"doc()doc";
+
+
+static const char* __doc_gr_logger_reset_config = R"doc()doc";
+
+
+static const char* __doc_gr_logger_set_level_0 = R"doc()doc";
+
+
+static const char* __doc_gr_logger_set_level_1 = R"doc()doc";
+
+
+static const char* __doc_gr_logger_get_level_0 = R"doc()doc";
+
+
+static const char* __doc_gr_logger_get_level_1 = R"doc()doc";
+
+
+static const char* __doc_gr_logger_add_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_set_appender = R"doc()doc";
+
+
+// static const char *__doc_gr_logger_add_console_appender = R"doc()doc";
+
+
+// static const char *__doc_gr_logger_set_console_appender = R"doc()doc";
+
+
+// static const char *__doc_gr_logger_add_file_appender = R"doc()doc";
+
+
+// static const char *__doc_gr_logger_set_file_appender = R"doc()doc";
+
+
+// static const char *__doc_gr_logger_add_rollingfile_appender = R"doc()doc";
+
+
+static const char* __doc_gr_logger_get_logger_names = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/math_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/math_pydoc_template.h
new file mode 100644
index 0000000000..af352fe0b8
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/math_pydoc_template.h
@@ -0,0 +1,75 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_fast_cc_multiply = R"doc()doc";
+
+
+static const char* __doc_gr_is_power_of_2 = R"doc()doc";
+
+
+static const char* __doc_gr_fast_atan2f_0 = R"doc()doc";
+
+
+static const char* __doc_gr_fast_atan2f_1 = R"doc()doc";
+
+
+static const char* __doc_gr_branchless_clip = R"doc()doc";
+
+
+static const char* __doc_gr_clip = R"doc()doc";
+
+
+static const char* __doc_gr_binary_slicer = R"doc()doc";
+
+
+static const char* __doc_gr_quad_45deg_slicer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_quad_0deg_slicer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_quad_45deg_slicer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_quad_0deg_slicer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_branchless_binary_slicer = R"doc()doc";
+
+
+static const char* __doc_gr_branchless_quad_0deg_slicer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_branchless_quad_0deg_slicer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_branchless_quad_45deg_slicer_0 = R"doc()doc";
+
+
+static const char* __doc_gr_branchless_quad_45deg_slicer_1 = R"doc()doc";
+
+
+static const char* __doc_gr_p2_round_down = R"doc()doc";
+
+
+static const char* __doc_gr_p2_round_up = R"doc()doc";
+
+
+static const char* __doc_gr_p2_modulo = R"doc()doc";
+
+
+static const char* __doc_gr_p2_modulo_neg = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/message_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/message_pydoc_template.h
new file mode 100644
index 0000000000..5c9a174a90
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/message_pydoc_template.h
@@ -0,0 +1,54 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_message = R"doc()doc";
+
+
+static const char* __doc_gr_message_message = R"doc()doc";
+
+
+static const char* __doc_gr_message_make = R"doc()doc";
+
+
+static const char* __doc_gr_message_make_from_string = R"doc()doc";
+
+
+static const char* __doc_gr_message_type = R"doc()doc";
+
+
+static const char* __doc_gr_message_arg1 = R"doc()doc";
+
+
+static const char* __doc_gr_message_arg2 = R"doc()doc";
+
+
+static const char* __doc_gr_message_set_type = R"doc()doc";
+
+
+static const char* __doc_gr_message_set_arg1 = R"doc()doc";
+
+
+static const char* __doc_gr_message_set_arg2 = R"doc()doc";
+
+
+static const char* __doc_gr_message_msg = R"doc()doc";
+
+
+static const char* __doc_gr_message_to_string = R"doc()doc";
+
+
+static const char* __doc_gr_message_ncurrently_allocated = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_accepter_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_accepter_pydoc_template.h
new file mode 100644
index 0000000000..fee326c6a3
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_accepter_pydoc_template.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_msg_accepter = R"doc()doc";
+
+
+static const char* __doc_gr_msg_accepter_msg_accepter_0 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_accepter_msg_accepter_1 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_accepter_post = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_handler_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_handler_pydoc_template.h
new file mode 100644
index 0000000000..b68f16ec3b
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_handler_pydoc_template.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_msg_handler = R"doc()doc";
+
+
+static const char* __doc_gr_msg_handler_msg_handler_0 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_handler_msg_handler_1 = R"doc()doc";
+
+
+static const char* __doc_gr_msg_handler_handle = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_queue_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_queue_pydoc_template.h
new file mode 100644
index 0000000000..6626bef81e
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/msg_queue_pydoc_template.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_msg_queue = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_msg_queue = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_make = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_handle = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_insert_tail = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_delete_head = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_delete_head_nowait = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_flush = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_empty_p = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_full_p = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_count = R"doc()doc";
+
+
+static const char* __doc_gr_msg_queue_limit = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/nco_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/nco_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/nco_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/prefs_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/prefs_pydoc_template.h
new file mode 100644
index 0000000000..61b0e0f8fb
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/prefs_pydoc_template.h
@@ -0,0 +1,63 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_prefs = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_prefs = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_singleton = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_add_config_file = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_to_string = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_save = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_has_section = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_has_option = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_get_string = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_set_string = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_get_bool = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_set_bool = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_get_long = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_set_long = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_get_double = R"doc()doc";
+
+
+static const char* __doc_gr_prefs_set_double = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/random_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/random_pydoc_template.h
new file mode 100644
index 0000000000..71fdb84d39
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/random_pydoc_template.h
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_random = R"doc()doc";
+
+
+static const char* __doc_gr_random_random_0 = R"doc()doc";
+
+
+static const char* __doc_gr_random_random_1 = R"doc()doc";
+
+
+static const char* __doc_gr_random_reseed = R"doc()doc";
+
+
+static const char* __doc_gr_random_set_integer_limits = R"doc()doc";
+
+
+static const char* __doc_gr_random_ran_int = R"doc()doc";
+
+
+static const char* __doc_gr_random_ran1 = R"doc()doc";
+
+
+static const char* __doc_gr_random_gasdev = R"doc()doc";
+
+
+static const char* __doc_gr_random_laplacian = R"doc()doc";
+
+
+static const char* __doc_gr_random_rayleigh = R"doc()doc";
+
+
+static const char* __doc_gr_random_impulse = R"doc()doc";
+
+
+static const char* __doc_gr_random_rayleigh_complex = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_impl_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_impl_pydoc_template.h
new file mode 100644
index 0000000000..88724212e3
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_impl_pydoc_template.h
@@ -0,0 +1,39 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_impl_rt_sched_param = R"doc()doc";
+
+
+static const char* __doc_gr_impl_rt_sched_param_rt_sched_param_0 = R"doc()doc";
+
+
+static const char* __doc_gr_impl_rt_sched_param_rt_sched_param_1 = R"doc()doc";
+
+
+static const char* __doc_gr_impl_rt_sched_param_rt_sched_param_2 = R"doc()doc";
+
+
+static const char* __doc_gr_impl_rt_priority_min = R"doc()doc";
+
+
+static const char* __doc_gr_impl_rt_priority_max = R"doc()doc";
+
+
+static const char* __doc_gr_impl_rt_priority_default = R"doc()doc";
+
+
+static const char* __doc_gr_impl_enable_realtime_scheduling = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_pydoc_template.h
new file mode 100644
index 0000000000..91a9607ae2
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/realtime_pydoc_template.h
@@ -0,0 +1,18 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_enable_realtime_scheduling = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpccallbackregister_base_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpccallbackregister_base_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpccallbackregister_base_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcmanager_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcmanager_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcmanager_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcregisterhelpers_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcregisterhelpers_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcregisterhelpers_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_aggregator_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_aggregator_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_aggregator_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_base_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_base_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_base_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_booter_aggregator_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_booter_aggregator_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/rpcserver_booter_aggregator_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/runtime_types_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/runtime_types_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/runtime_types_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sincos_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sincos_pydoc_template.h
new file mode 100644
index 0000000000..6d430b5983
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sincos_pydoc_template.h
@@ -0,0 +1,21 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_sincos = R"doc()doc";
+
+
+static const char* __doc_gr_sincosf = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sptr_magic_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sptr_magic_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sptr_magic_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_block_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_block_pydoc_template.h
new file mode 100644
index 0000000000..6034878624
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_block_pydoc_template.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_sync_block = R"doc()doc";
+
+
+static const char* __doc_gr_sync_block_work = R"doc()doc";
+
+
+static const char* __doc_gr_sync_block_forecast = R"doc()doc";
+
+
+static const char* __doc_gr_sync_block_general_work = R"doc()doc";
+
+
+static const char* __doc_gr_sync_block_fixed_rate_ninput_to_noutput = R"doc()doc";
+
+
+static const char* __doc_gr_sync_block_fixed_rate_noutput_to_ninput = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_decimator_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_decimator_pydoc_template.h
new file mode 100644
index 0000000000..f327d9f66e
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_decimator_pydoc_template.h
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_sync_decimator = R"doc()doc";
+
+
+static const char* __doc_gr_sync_decimator_decimation = R"doc()doc";
+
+
+static const char* __doc_gr_sync_decimator_set_decimation = R"doc()doc";
+
+
+static const char* __doc_gr_sync_decimator_forecast = R"doc()doc";
+
+
+static const char* __doc_gr_sync_decimator_general_work = R"doc()doc";
+
+
+static const char* __doc_gr_sync_decimator_fixed_rate_ninput_to_noutput = R"doc()doc";
+
+
+static const char* __doc_gr_sync_decimator_fixed_rate_noutput_to_ninput = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_interpolator_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_interpolator_pydoc_template.h
new file mode 100644
index 0000000000..3876790dbd
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sync_interpolator_pydoc_template.h
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_sync_interpolator = R"doc()doc";
+
+
+static const char* __doc_gr_sync_interpolator_interpolation = R"doc()doc";
+
+
+static const char* __doc_gr_sync_interpolator_set_interpolation = R"doc()doc";
+
+
+static const char* __doc_gr_sync_interpolator_forecast = R"doc()doc";
+
+
+static const char* __doc_gr_sync_interpolator_general_work = R"doc()doc";
+
+
+static const char* __doc_gr_sync_interpolator_fixed_rate_ninput_to_noutput = R"doc()doc";
+
+
+static const char* __doc_gr_sync_interpolator_fixed_rate_noutput_to_ninput = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sys_paths_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sys_paths_pydoc_template.h
new file mode 100644
index 0000000000..28a857d4cd
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/sys_paths_pydoc_template.h
@@ -0,0 +1,24 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_tmp_path = R"doc()doc";
+
+
+static const char* __doc_gr_appdata_path = R"doc()doc";
+
+
+static const char* __doc_gr_userconf_path = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tag_checker_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tag_checker_pydoc_template.h
new file mode 100644
index 0000000000..29d19d8e0f
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tag_checker_pydoc_template.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_tag_checker = R"doc()doc";
+
+
+static const char* __doc_gr_tag_checker_tag_checker_0 = R"doc()doc";
+
+
+static const char* __doc_gr_tag_checker_tag_checker_1 = R"doc()doc";
+
+
+static const char* __doc_gr_tag_checker_get_tags = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tagged_stream_block_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tagged_stream_block_pydoc_template.h
new file mode 100644
index 0000000000..efbd93e749
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tagged_stream_block_pydoc_template.h
@@ -0,0 +1,30 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_tagged_stream_block = R"doc()doc";
+
+
+static const char* __doc_gr_tagged_stream_block_forecast = R"doc()doc";
+
+
+static const char* __doc_gr_tagged_stream_block_check_topology = R"doc()doc";
+
+
+static const char* __doc_gr_tagged_stream_block_general_work = R"doc()doc";
+
+
+static const char* __doc_gr_tagged_stream_block_work = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tags_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tags_pydoc_template.h
new file mode 100644
index 0000000000..43981ff697
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tags_pydoc_template.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_tag_t = R"doc()doc";
+
+
+static const char* __doc_gr_tag_t_tag_t_0 = R"doc()doc";
+
+
+static const char* __doc_gr_tag_t_tag_t_1 = R"doc()doc";
+
+
+static const char* __doc_gr_tag_t_offset_compare = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/thrift_application_base_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/thrift_application_base_pydoc_template.h
new file mode 100644
index 0000000000..a17028c0e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/thrift_application_base_pydoc_template.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/top_block_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/top_block_pydoc_template.h
new file mode 100644
index 0000000000..e93ed7c3ee
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/top_block_pydoc_template.h
@@ -0,0 +1,63 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_top_block = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_run = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_start = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_stop = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_wait = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_lock = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_unlock = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_edge_list = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_msg_edge_list = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_dump = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_max_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_set_max_noutput_items = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_to_top_block = R"doc()doc";
+
+
+static const char* __doc_gr_top_block_setup_rpc = R"doc()doc";
+
+
+static const char* __doc_gr_make_top_block = R"doc()doc";
+
+
+static const char* __doc_gr_cast_to_top_block_sptr = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tpb_detail_pydoc_template.h b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tpb_detail_pydoc_template.h
new file mode 100644
index 0000000000..2d7b4fa793
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/docstrings/tpb_detail_pydoc_template.h
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(gr, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_gr_tpb_detail = R"doc()doc";
+
+
+static const char* __doc_gr_tpb_detail_tpb_detail = R"doc()doc";
+
+
+static const char* __doc_gr_tpb_detail_notify_upstream = R"doc()doc";
+
+
+static const char* __doc_gr_tpb_detail_notify_downstream = R"doc()doc";
+
+
+static const char* __doc_gr_tpb_detail_notify_neighbors = R"doc()doc";
+
+
+static const char* __doc_gr_tpb_detail_notify_msg = R"doc()doc";
+
+
+static const char* __doc_gr_tpb_detail_clear_changed = R"doc()doc";
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/endianness_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/endianness_python.cc
new file mode 100644
index 0000000000..95d44214c6
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/endianness_python.cc
@@ -0,0 +1,35 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(endianness.h) */
+/* BINDTOOL_HEADER_FILE_HASH(1738ddb9b6c9db43eafe4b41583afec0) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/endianness.h>
+
+void bind_endianness(py::module& m)
+{
+
+ py::enum_<gr::endianness_t>(m, "endianness_t")
+ .value("GR_MSB_FIRST", gr::GR_MSB_FIRST) // 0
+ .value("GR_LSB_FIRST", gr::GR_LSB_FIRST) // 1
+ .export_values();
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/expj_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/expj_python.cc
new file mode 100644
index 0000000000..b474a65651
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/expj_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(expj.h) */
+/* BINDTOOL_HEADER_FILE_HASH(484853753d87c0ea234a87fec495c36e) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/expj.h>
+
+void bind_expj(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/flowgraph_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/flowgraph_python.cc
new file mode 100644
index 0000000000..6f1f6694ef
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/flowgraph_python.cc
@@ -0,0 +1,226 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(flowgraph.h) */
+/* BINDTOOL_HEADER_FILE_HASH(a019dfc2f7380e37ef8eaa0ee96c39c0) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/flowgraph.h>
+// pydoc.h is automatically generated in the build directory
+#include <flowgraph_pydoc.h>
+
+void bind_flowgraph(py::module& m)
+{
+
+ using flowgraph = ::gr::flowgraph;
+ using endpoint = ::gr::endpoint;
+ using msg_endpoint = ::gr::msg_endpoint;
+ using edge = ::gr::edge;
+ using msg_edge = ::gr::msg_edge;
+
+
+ py::class_<flowgraph, std::shared_ptr<flowgraph>>(m, "flowgraph", D(flowgraph))
+
+ .def(py::init<gr::flowgraph const&>(), py::arg("arg0"), D(flowgraph, flowgraph))
+
+
+ .def("connect",
+ (void (flowgraph::*)(gr::endpoint const&, gr::endpoint const&)) &
+ flowgraph::connect,
+ py::arg("src"),
+ py::arg("dst"),
+ D(flowgraph, connect, 0))
+
+
+ .def("disconnect",
+ (void (flowgraph::*)(gr::endpoint const&, gr::endpoint const&)) &
+ flowgraph::disconnect,
+ py::arg("src"),
+ py::arg("dst"),
+ D(flowgraph, disconnect, 0))
+
+
+ .def("connect",
+ (void (flowgraph::*)(gr::basic_block_sptr, int, gr::basic_block_sptr, int)) &
+ flowgraph::connect,
+ py::arg("src_block"),
+ py::arg("src_port"),
+ py::arg("dst_block"),
+ py::arg("dst_port"),
+ D(flowgraph, connect, 1))
+
+
+ .def("disconnect",
+ (void (flowgraph::*)(gr::basic_block_sptr, int, gr::basic_block_sptr, int)) &
+ flowgraph::disconnect,
+ py::arg("src_block"),
+ py::arg("src_port"),
+ py::arg("dst_block"),
+ py::arg("dst_port"),
+ D(flowgraph, disconnect, 1))
+
+
+ .def("connect",
+ (void (flowgraph::*)(gr::msg_endpoint const&, gr::msg_endpoint const&)) &
+ flowgraph::connect,
+ py::arg("src"),
+ py::arg("dst"),
+ D(flowgraph, connect, 2))
+
+
+ .def("disconnect",
+ (void (flowgraph::*)(gr::msg_endpoint const&, gr::msg_endpoint const&)) &
+ flowgraph::disconnect,
+ py::arg("src"),
+ py::arg("dst"),
+ D(flowgraph, disconnect, 2))
+
+
+ .def("validate", &flowgraph::validate, D(flowgraph, validate))
+
+
+ .def("clear", &flowgraph::clear, D(flowgraph, clear))
+
+
+ .def("edges", &flowgraph::edges, D(flowgraph, edges))
+
+
+ .def("msg_edges", &flowgraph::msg_edges, D(flowgraph, msg_edges))
+
+
+ .def("calc_used_blocks",
+ &flowgraph::calc_used_blocks,
+ D(flowgraph, calc_used_blocks))
+
+
+ .def("topological_sort",
+ &flowgraph::topological_sort,
+ py::arg("blocks"),
+ D(flowgraph, topological_sort))
+
+
+ .def("partition", &flowgraph::partition, D(flowgraph, partition))
+
+ ;
+
+
+ py::class_<endpoint, std::shared_ptr<endpoint>>(m, "endpoint", D(endpoint))
+
+ .def(py::init<>(), D(endpoint, endpoint, 0))
+ .def(py::init<gr::basic_block_sptr, int>(),
+ py::arg("block"),
+ py::arg("port"),
+ D(endpoint, endpoint, 1))
+ .def(py::init<gr::endpoint const&>(), py::arg("arg0"), D(endpoint, endpoint, 2))
+
+
+ .def("block", &endpoint::block, D(endpoint, block))
+
+
+ .def("port", &endpoint::port, D(endpoint, port))
+
+
+ .def("identifier", &endpoint::identifier, D(endpoint, identifier))
+
+ ;
+
+
+ py::class_<msg_endpoint, std::shared_ptr<msg_endpoint>>(
+ m, "msg_endpoint", D(msg_endpoint))
+
+ .def(py::init<>(), D(msg_endpoint, msg_endpoint, 0))
+ .def(py::init<gr::basic_block_sptr, pmt::pmt_t, bool>(),
+ py::arg("block"),
+ py::arg("port"),
+ py::arg("is_hier") = false,
+ D(msg_endpoint, msg_endpoint, 1))
+ .def(py::init<gr::msg_endpoint const&>(),
+ py::arg("arg0"),
+ D(msg_endpoint, msg_endpoint, 2))
+
+
+ .def("block", &msg_endpoint::block, D(msg_endpoint, block))
+
+
+ .def("port", &msg_endpoint::port, D(msg_endpoint, port))
+
+
+ .def("is_hier", &msg_endpoint::is_hier, D(msg_endpoint, is_hier))
+
+
+ .def("set_hier", &msg_endpoint::set_hier, py::arg("h"), D(msg_endpoint, set_hier))
+
+
+ .def("identifier", &msg_endpoint::identifier, D(msg_endpoint, identifier))
+
+ ;
+
+
+ py::class_<edge, std::shared_ptr<edge>>(m, "edge", D(edge))
+
+ .def(py::init<>(), D(edge, edge, 0))
+ .def(py::init<gr::endpoint const&, gr::endpoint const&>(),
+ py::arg("src"),
+ py::arg("dst"),
+ D(edge, edge, 1))
+ .def(py::init<gr::edge const&>(), py::arg("arg0"), D(edge, edge, 2))
+
+
+ .def("src", &edge::src, D(edge, src))
+
+
+ .def("dst", &edge::dst, D(edge, dst))
+
+
+ .def("identifier", &edge::identifier, D(edge, identifier))
+
+ ;
+
+
+ py::class_<msg_edge, std::shared_ptr<msg_edge>>(m, "msg_edge", D(msg_edge))
+
+ .def(py::init<>(), D(msg_edge, msg_edge, 0))
+ .def(py::init<gr::msg_endpoint const&, gr::msg_endpoint const&>(),
+ py::arg("src"),
+ py::arg("dst"),
+ D(msg_edge, msg_edge, 1))
+ .def(py::init<gr::msg_edge const&>(), py::arg("arg0"), D(msg_edge, msg_edge, 2))
+
+
+ .def("src", &msg_edge::src, D(msg_edge, src))
+
+
+ .def("dst", &msg_edge::dst, D(msg_edge, dst))
+
+
+ .def("identifier", &msg_edge::identifier, D(msg_edge, identifier))
+
+ ;
+
+
+ m.def("make_flowgraph", &::gr::make_flowgraph, D(make_flowgraph));
+
+
+ // m.def("dot_graph_fg",&::gr::dot_graph_fg,
+ // py::arg("fg"),
+ // D(dot_graph_fg)
+ // );
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_nco_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_nco_python.cc
new file mode 100644
index 0000000000..40cf159870
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_nco_python.cc
@@ -0,0 +1,161 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(fxpt_nco.h) */
+/* BINDTOOL_HEADER_FILE_HASH(a464f7bdf49d3dfafc989a2b3f4d7b94) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/fxpt_nco.h>
+// pydoc.h is automatically generated in the build directory
+#include <fxpt_nco_pydoc.h>
+
+void bind_fxpt_nco(py::module& m)
+{
+
+ using fxpt_nco = ::gr::fxpt_nco;
+
+
+ py::class_<fxpt_nco, std::shared_ptr<fxpt_nco>>(m, "fxpt_nco", D(fxpt_nco))
+
+ .def(py::init<>(), D(fxpt_nco, fxpt_nco, 0))
+ .def(py::init<gr::fxpt_nco const&>(), py::arg("arg0"), D(fxpt_nco, fxpt_nco, 1))
+
+
+ .def("set_phase", &fxpt_nco::set_phase, py::arg("angle"), D(fxpt_nco, set_phase))
+
+
+ .def("adjust_phase",
+ &fxpt_nco::adjust_phase,
+ py::arg("delta_phase"),
+ D(fxpt_nco, adjust_phase))
+
+
+ .def(
+ "set_freq", &fxpt_nco::set_freq, py::arg("angle_rate"), D(fxpt_nco, set_freq))
+
+
+ .def("adjust_freq",
+ &fxpt_nco::adjust_freq,
+ py::arg("delta_angle_rate"),
+ D(fxpt_nco, adjust_freq))
+
+
+ .def("step", (void (fxpt_nco::*)()) & fxpt_nco::step, D(fxpt_nco, step, 0))
+
+
+ .def("step",
+ (void (fxpt_nco::*)(int)) & fxpt_nco::step,
+ py::arg("n"),
+ D(fxpt_nco, step, 1))
+
+
+ .def("get_phase", &fxpt_nco::get_phase, D(fxpt_nco, get_phase))
+
+
+ .def("get_freq", &fxpt_nco::get_freq, D(fxpt_nco, get_freq))
+
+
+ .def("sincos",
+ (void (fxpt_nco::*)(float*, float*) const) & fxpt_nco::sincos,
+ py::arg("sinx"),
+ py::arg("cosx"),
+ D(fxpt_nco, sincos, 0))
+
+
+ .def("sincos",
+ (void (fxpt_nco::*)(gr_complex*, int, double)) & fxpt_nco::sincos,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, sincos, 1))
+
+
+ .def("sin",
+ (void (fxpt_nco::*)(float*, int, double)) & fxpt_nco::sin,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, sin, 0))
+
+
+ .def("cos",
+ (void (fxpt_nco::*)(float*, int, double)) & fxpt_nco::cos,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, cos, 0))
+
+
+ .def("sin",
+ (void (fxpt_nco::*)(int8_t*, int, double)) & fxpt_nco::sin,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, sin, 1))
+
+
+ .def("cos",
+ (void (fxpt_nco::*)(int8_t*, int, double)) & fxpt_nco::cos,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, cos, 1))
+
+
+ .def("sin",
+ (void (fxpt_nco::*)(short int*, int, double)) & fxpt_nco::sin,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, sin, 2))
+
+
+ .def("cos",
+ (void (fxpt_nco::*)(short int*, int, double)) & fxpt_nco::cos,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, cos, 2))
+
+
+ .def("sin",
+ (void (fxpt_nco::*)(int*, int, double)) & fxpt_nco::sin,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, sin, 3))
+
+
+ .def("cos",
+ (void (fxpt_nco::*)(int*, int, double)) & fxpt_nco::cos,
+ py::arg("output"),
+ py::arg("noutput_items"),
+ py::arg("ampl") = 1.,
+ D(fxpt_nco, cos, 3))
+
+
+ .def("cos", (float (fxpt_nco::*)() const) & fxpt_nco::cos, D(fxpt_nco, cos, 4))
+
+
+ .def("sin", (float (fxpt_nco::*)() const) & fxpt_nco::sin, D(fxpt_nco, sin, 4))
+
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_python.cc
new file mode 100644
index 0000000000..52ef1f249c
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_python.cc
@@ -0,0 +1,68 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(fxpt.h) */
+/* BINDTOOL_HEADER_FILE_HASH(d8f127eabbf6b31d6fb100ad04eb21b2) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/fxpt.h>
+// pydoc.h is automatically generated in the build directory
+#include <fxpt_pydoc.h>
+
+void bind_fxpt(py::module& m)
+{
+
+ using fxpt = ::gr::fxpt;
+
+
+ py::class_<fxpt, std::shared_ptr<fxpt>>(m, "fxpt", D(fxpt))
+
+ .def(py::init<>(), D(fxpt, fxpt, 0))
+ .def(py::init<gr::fxpt const&>(), py::arg("arg0"), D(fxpt, fxpt, 1))
+
+
+ .def_static("float_to_fixed",
+ &fxpt::float_to_fixed,
+ py::arg("x"),
+ D(fxpt, float_to_fixed))
+
+
+ .def_static("fixed_to_float",
+ &fxpt::fixed_to_float,
+ py::arg("x"),
+ D(fxpt, fixed_to_float))
+
+
+ .def_static("sin", &fxpt::sin, py::arg("x"), D(fxpt, sin))
+
+
+ .def_static("cos", &fxpt::cos, py::arg("x"), D(fxpt, cos))
+
+
+ .def_static("sincos",
+ &fxpt::sincos,
+ py::arg("x"),
+ py::arg("s"),
+ py::arg("c"),
+ D(fxpt, sincos))
+
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_vco_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_vco_python.cc
new file mode 100644
index 0000000000..1e0fc38753
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/fxpt_vco_python.cc
@@ -0,0 +1,89 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(fxpt_vco.h) */
+/* BINDTOOL_HEADER_FILE_HASH(e43dce3c6a7df7cd2c1ff929cc6eabb1) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/fxpt_vco.h>
+// pydoc.h is automatically generated in the build directory
+#include <fxpt_vco_pydoc.h>
+
+void bind_fxpt_vco(py::module& m)
+{
+
+ using fxpt_vco = ::gr::fxpt_vco;
+
+
+ py::class_<fxpt_vco, std::shared_ptr<fxpt_vco>>(m, "fxpt_vco", D(fxpt_vco))
+
+ .def(py::init<>(), D(fxpt_vco, fxpt_vco, 0))
+ .def(py::init<gr::fxpt_vco const&>(), py::arg("arg0"), D(fxpt_vco, fxpt_vco, 1))
+
+
+ .def("set_phase", &fxpt_vco::set_phase, py::arg("angle"), D(fxpt_vco, set_phase))
+
+
+ .def("adjust_phase",
+ &fxpt_vco::adjust_phase,
+ py::arg("delta_phase"),
+ D(fxpt_vco, adjust_phase))
+
+
+ .def("get_phase", &fxpt_vco::get_phase, D(fxpt_vco, get_phase))
+
+
+ .def("sincos",
+ (void (fxpt_vco::*)(float*, float*) const) & fxpt_vco::sincos,
+ py::arg("sinx"),
+ py::arg("cosx"),
+ D(fxpt_vco, sincos, 0))
+
+
+ .def("sincos",
+ (void (fxpt_vco::*)(gr_complex*, float const*, int, float, float)) &
+ fxpt_vco::sincos,
+ py::arg("output"),
+ py::arg("input"),
+ py::arg("noutput_items"),
+ py::arg("k"),
+ py::arg("ampl") = 1.,
+ D(fxpt_vco, sincos, 1))
+
+
+ .def("cos",
+ (void (fxpt_vco::*)(float*, float const*, int, float, float)) &
+ fxpt_vco::cos,
+ py::arg("output"),
+ py::arg("input"),
+ py::arg("noutput_items"),
+ py::arg("k"),
+ py::arg("ampl") = 1.,
+ D(fxpt_vco, cos, 0))
+
+
+ .def("cos", (float (fxpt_vco::*)() const) & fxpt_vco::cos, D(fxpt_vco, cos, 1))
+
+
+ .def("sin", &fxpt_vco::sin, D(fxpt_vco, sin))
+
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/hier_block2_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/hier_block2_python.cc
new file mode 100644
index 0000000000..f2d439ad52
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/hier_block2_python.cc
@@ -0,0 +1,227 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(hier_block2.h) */
+/* BINDTOOL_HEADER_FILE_HASH(367d4df8d747ae4040c2e5b46cbe1b4f) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/hier_block2.h>
+// pydoc.h is automatically generated in the build directory
+#include <hier_block2_pydoc.h>
+
+void bind_hier_block2(py::module& m)
+{
+
+ using hier_block2 = ::gr::hier_block2;
+
+ py::class_<hier_block2,
+ gr::basic_block,
+ gr::msg_accepter,
+ std::shared_ptr<hier_block2>>(m, "hier_block2_pb", D(hier_block2))
+
+ .def(py::init(&gr::make_hier_block2),
+ py::arg("name"),
+ py::arg("input_signature"),
+ py::arg("output_signature"))
+
+ .def("self", &hier_block2::self)
+ .def("primitive_connect",
+ (void (hier_block2::*)(gr::basic_block_sptr)) & hier_block2::connect,
+ py::arg("block"))
+ .def("primitive_connect",
+ (void (hier_block2::*)(
+ gr::basic_block_sptr, int, gr::basic_block_sptr, int)) &
+ hier_block2::connect,
+ py::arg("src"),
+ py::arg("src_port"),
+ py::arg("dst"),
+ py::arg("dst_port"),
+ D(hier_block2, connect, 1))
+ .def("primitive_msg_connect",
+ (void (hier_block2::*)(
+ gr::basic_block_sptr, pmt::pmt_t, gr::basic_block_sptr, pmt::pmt_t)) &
+ hier_block2::msg_connect,
+ py::arg("src"),
+ py::arg("srcport"),
+ py::arg("dst"),
+ py::arg("dstport"),
+ D(hier_block2, msg_connect, 0))
+ .def("primitive_msg_connect",
+ (void (hier_block2::*)(
+ gr::basic_block_sptr, std::string, gr::basic_block_sptr, std::string)) &
+ hier_block2::msg_connect,
+ py::arg("src"),
+ py::arg("srcport"),
+ py::arg("dst"),
+ py::arg("dstport"),
+ D(hier_block2, msg_connect, 1))
+ .def("primitive_msg_disconnect",
+ (void (hier_block2::*)(
+ gr::basic_block_sptr, pmt::pmt_t, gr::basic_block_sptr, pmt::pmt_t)) &
+ hier_block2::msg_disconnect,
+ py::arg("src"),
+ py::arg("srcport"),
+ py::arg("dst"),
+ py::arg("dstport"),
+ D(hier_block2, msg_disconnect, 0))
+ .def("primitive_msg_disconnect",
+ (void (hier_block2::*)(
+ gr::basic_block_sptr, std::string, gr::basic_block_sptr, std::string)) &
+ hier_block2::msg_disconnect,
+ py::arg("src"),
+ py::arg("srcport"),
+ py::arg("dst"),
+ py::arg("dstport"),
+ D(hier_block2, msg_disconnect, 1))
+ .def("primitive_disconnect",
+ (void (hier_block2::*)(gr::basic_block_sptr)) & hier_block2::disconnect,
+ py::arg("block"),
+ D(hier_block2, disconnect, 0))
+ .def("primitive_disconnect",
+ (void (hier_block2::*)(
+ gr::basic_block_sptr, int, gr::basic_block_sptr, int)) &
+ hier_block2::disconnect,
+ py::arg("src"),
+ py::arg("src_port"),
+ py::arg("dst"),
+ py::arg("dst_port"),
+ D(hier_block2, disconnect, 1))
+
+
+ .def("disconnect_all",
+ &hier_block2::disconnect_all,
+ D(hier_block2, disconnect_all))
+
+
+ .def("lock", &hier_block2::lock, D(hier_block2, lock))
+
+
+ .def("unlock", &hier_block2::unlock, D(hier_block2, unlock))
+
+
+ .def("max_output_buffer",
+ &hier_block2::max_output_buffer,
+ py::arg("port") = 0,
+ D(hier_block2, max_output_buffer))
+ .def("set_max_output_buffer",
+ (void (hier_block2::*)(int)) & hier_block2::set_max_output_buffer,
+ py::arg("max_output_buffer"),
+ D(hier_block2, set_max_output_buffer, 0))
+ .def("set_max_output_buffer",
+ (void (hier_block2::*)(size_t, int)) & hier_block2::set_max_output_buffer,
+ py::arg("port"),
+ py::arg("max_output_buffer"),
+ D(hier_block2, set_max_output_buffer, 1))
+ .def("min_output_buffer",
+ &hier_block2::min_output_buffer,
+ py::arg("port") = 0,
+ D(hier_block2, min_output_buffer))
+ .def("set_min_output_buffer",
+ (void (hier_block2::*)(int)) & hier_block2::set_min_output_buffer,
+ py::arg("min_output_buffer"),
+ D(hier_block2, set_min_output_buffer, 0))
+ .def("set_min_output_buffer",
+ (void (hier_block2::*)(size_t, int)) & hier_block2::set_min_output_buffer,
+ py::arg("port"),
+ py::arg("min_output_buffer"),
+ D(hier_block2, set_min_output_buffer, 1))
+ // .def("flatten",&hier_block2::flatten)
+ .def("to_hier_block2",
+ &hier_block2::to_hier_block2,
+ D(hier_block2, to_hier_block2))
+
+ .def("has_msg_port",
+ &hier_block2::has_msg_port,
+ py::arg("which_port"),
+ D(hier_block2, has_msg_port))
+ .def("message_port_is_hier",
+ &hier_block2::message_port_is_hier,
+ py::arg("port_id"),
+ D(hier_block2, message_port_is_hier))
+ .def("message_port_is_hier_in",
+ &hier_block2::message_port_is_hier_in,
+ py::arg("port_id"),
+ D(hier_block2, message_port_is_hier_in))
+ .def("message_port_is_hier_out",
+ &hier_block2::message_port_is_hier_out,
+ py::arg("port_id"),
+ D(hier_block2, message_port_is_hier_out))
+
+
+ .def("primitive_message_port_register_hier_in",
+ &hier_block2::message_port_register_hier_in,
+ py::arg("port_id"),
+ D(hier_block2, message_port_register_hier_in))
+
+
+ .def("primitive_message_port_register_hier_out",
+ &hier_block2::message_port_register_hier_out,
+ py::arg("port_id"),
+ D(hier_block2, message_port_register_hier_out))
+ .def("set_processor_affinity",
+ &hier_block2::set_processor_affinity,
+ py::arg("mask"),
+ D(hier_block2, set_processor_affinity))
+
+
+ .def("unset_processor_affinity",
+ &hier_block2::unset_processor_affinity,
+ D(hier_block2, unset_processor_affinity))
+
+
+ .def("processor_affinity",
+ &hier_block2::processor_affinity,
+ D(hier_block2, processor_affinity))
+
+
+ .def("set_log_level",
+ &hier_block2::set_log_level,
+ py::arg("level"),
+ D(hier_block2, set_log_level))
+
+
+ .def("log_level", &hier_block2::log_level, D(hier_block2, log_level))
+
+
+ .def("all_min_output_buffer_p",
+ &hier_block2::all_min_output_buffer_p,
+ D(hier_block2, all_min_output_buffer_p))
+
+
+ .def("all_max_output_buffer_p",
+ &hier_block2::all_max_output_buffer_p,
+ D(hier_block2, all_max_output_buffer_p))
+
+ ;
+
+
+ // m.def("make_hier_block2",&gr::make_hier_block2,
+ // py::arg("name"),
+ // py::arg("input_signature"),
+ // py::arg("output_signature")
+ // );
+ // m.def("dot_graph",&gr::dot_graph,
+ // py::arg("hierblock2")
+ // );
+ // m.def("cast_to_hier_block2_sptr",&gr::cast_to_hier_block2_sptr,
+ // py::arg("block")
+ // );
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/high_res_timer_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/high_res_timer_python.cc
new file mode 100644
index 0000000000..4e581bfc98
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/high_res_timer_python.cc
@@ -0,0 +1,46 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(high_res_timer.h) */
+/* BINDTOOL_HEADER_FILE_HASH(07d128321042e69a0ce418de407ceaf4) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/high_res_timer.h>
+// pydoc.h is automatically generated in the build directory
+#include <high_res_timer_pydoc.h>
+
+void bind_high_res_timer(py::module& m)
+{
+
+
+ m.def("high_res_timer_now", &::gr::high_res_timer_now, D(high_res_timer_now));
+
+
+ m.def("high_res_timer_now_perfmon",
+ &::gr::high_res_timer_now_perfmon,
+ D(high_res_timer_now_perfmon));
+
+
+ m.def("high_res_timer_tps", &::gr::high_res_timer_tps, D(high_res_timer_tps));
+
+
+ m.def("high_res_timer_epoch", &::gr::high_res_timer_epoch, D(high_res_timer_epoch));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/io_signature_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/io_signature_python.cc
new file mode 100644
index 0000000000..56ed5c2fe5
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/io_signature_python.cc
@@ -0,0 +1,90 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(io_signature.h) */
+/* BINDTOOL_HEADER_FILE_HASH(aa246441b45c1a5b872509ed410615ae) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/io_signature.h>
+// pydoc.h is automatically generated in the build directory
+#include <io_signature_pydoc.h>
+
+void bind_io_signature(py::module& m)
+{
+
+ using io_signature = ::gr::io_signature;
+
+
+ py::class_<io_signature, std::shared_ptr<io_signature>>(
+ m, "io_signature", D(io_signature))
+
+ .def(py::init(&io_signature::make),
+ py::arg("min_streams"),
+ py::arg("max_streams"),
+ py::arg("sizeof_stream_item"),
+ D(io_signature, make))
+
+
+ .def_static("make2",
+ &io_signature::make2,
+ py::arg("min_streams"),
+ py::arg("max_streams"),
+ py::arg("sizeof_stream_item1"),
+ py::arg("sizeof_stream_item2"),
+ D(io_signature, make2))
+
+
+ .def_static("make3",
+ &io_signature::make3,
+ py::arg("min_streams"),
+ py::arg("max_streams"),
+ py::arg("sizeof_stream_item1"),
+ py::arg("sizeof_stream_item2"),
+ py::arg("sizeof_stream_item3"),
+ D(io_signature, make3))
+
+
+ .def_static("makev",
+ &io_signature::makev,
+ py::arg("min_streams"),
+ py::arg("max_streams"),
+ py::arg("sizeof_stream_items"),
+ D(io_signature, makev))
+
+
+ .def("min_streams", &io_signature::min_streams, D(io_signature, min_streams))
+
+
+ .def("max_streams", &io_signature::max_streams, D(io_signature, max_streams))
+
+
+ .def("sizeof_stream_item",
+ &io_signature::sizeof_stream_item,
+ py::arg("index"),
+ D(io_signature, sizeof_stream_item))
+
+
+ .def("sizeof_stream_items",
+ &io_signature::sizeof_stream_items,
+ D(io_signature, sizeof_stream_items))
+
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/logger_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/logger_python.cc
new file mode 100644
index 0000000000..e97c50bcf1
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/logger_python.cc
@@ -0,0 +1,162 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(logger.h) */
+/* BINDTOOL_HEADER_FILE_HASH(5e612fbda6f51ed261021bd090eb95c1) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/logger.h>
+
+void bind_logger(py::module& m)
+{
+ using logger = gr::logger;
+ using logger_config = gr::logger_config;
+
+
+ py::class_<logger, std::shared_ptr<logger>>(m, "logger")
+
+ .def(py::init<std::string>(), py::arg("logger_name"))
+ .def(py::init<gr::logger const&>(), py::arg("arg0"))
+
+ .def("set_level", &logger::set_level, py::arg("level"))
+ .def("get_level", &logger::get_level, py::arg("level"))
+ .def("debug", &logger::debug, py::arg("msg"))
+ .def("info", &logger::info, py::arg("msg"))
+ .def("notice", &logger::notice, py::arg("msg"))
+ .def("warn", &logger::warn, py::arg("msg"))
+ .def("error", &logger::error, py::arg("msg"))
+ .def("crit", &logger::crit, py::arg("msg"))
+ .def("alert", &logger::alert, py::arg("msg"))
+ .def("fatal", &logger::fatal, py::arg("msg"))
+ .def("emerg", &logger::emerg, py::arg("msg"))
+ .def("errorIF", &logger::errorIF, py::arg("cond"), py::arg("msg"))
+ .def("log_assert", &logger::log_assert, py::arg("cond"), py::arg("msg"))
+ .def("add_console_appender",
+ &logger::add_console_appender,
+ py::arg("target"),
+ py::arg("pattern"))
+ .def("set_console_appender",
+ &logger::set_console_appender,
+ py::arg("target"),
+ py::arg("pattern"))
+ .def("add_file_appender",
+ &logger::add_file_appender,
+ py::arg("filename"),
+ py::arg("append"),
+ py::arg("pattern"))
+ .def("set_file_appender",
+ &logger::set_file_appender,
+ py::arg("filename"),
+ py::arg("append"),
+ py::arg("pattern"))
+ .def("add_rollingfile_appender",
+ &logger::add_rollingfile_appender,
+ py::arg("filename"),
+ py::arg("filesize"),
+ py::arg("bkup_index"),
+ py::arg("append"),
+ py::arg("mode"),
+ py::arg("pattern"));
+
+
+ py::class_<logger_config, std::shared_ptr<logger_config>>(m, "logger_config")
+
+
+ .def_static("get_filename", &logger_config::get_filename)
+ .def_static("get_watch_period", &logger_config::get_watch_period)
+ .def_static("load_config",
+ &logger_config::load_config,
+ py::arg("filename"),
+ py::arg("watch_period") = 0)
+ .def_static("stop_watch", &logger_config::stop_watch)
+ .def_static("reset_config", &logger_config::reset_config);
+
+
+ // m.def("configure_default_loggers",&gr::configure_default_loggers,
+ // py::arg("l"),
+ // py::arg("d"),
+ // py::arg("name")
+ // );
+ m.def("update_logger_alias",
+ &gr::update_logger_alias,
+ py::arg("name"),
+ py::arg("alias"));
+ m.def("logger_get_logger", &gr::logger_get_logger, py::arg("name"));
+ m.def("logger_load_config", &gr::logger_load_config, py::arg("config_filename") = "");
+ m.def("gr_logger_reset_config", &gr_logger_reset_config);
+ m.def("logger_set_level",
+ (void (*)(gr::logger_ptr, std::string const&)) & gr::logger_set_level,
+ py::arg("logger"),
+ py::arg("level"));
+ m.def("logger_set_level",
+ (void (*)(gr::logger_ptr, log4cpp::Priority::Value)) & gr::logger_set_level,
+ py::arg("logger"),
+ py::arg("level"));
+ m.def("logger_get_level",
+ (void (*)(gr::logger_ptr, std::string&)) & gr::logger_get_level,
+ py::arg("logger"),
+ py::arg("level"));
+ // m.def("logger_get_level",(void (*)(gr::logger_ptr, log4cpp::Priority::Value
+ // &))&gr::logger_get_level,
+ // py::arg("logger"),
+ // py::arg("level")
+ // );
+ // m.def("logger_add_appender",&gr::logger_add_appender,
+ // py::arg("logger"),
+ // py::arg("appender")
+ // ); // Not Implemented
+ // m.def("logger_set_appender",&gr::logger_set_appender,
+ // py::arg("logger"),
+ // py::arg("appender")
+ // ); // Not Implemented
+ m.def("logger_add_console_appender",
+ &gr::logger_add_console_appender,
+ py::arg("logger"),
+ py::arg("target"),
+ py::arg("pattern"));
+ m.def("logger_set_console_appender",
+ &gr::logger_set_console_appender,
+ py::arg("logger"),
+ py::arg("target"),
+ py::arg("pattern"));
+ m.def("logger_add_file_appender",
+ &gr::logger_add_file_appender,
+ py::arg("logger"),
+ py::arg("filename"),
+ py::arg("append"),
+ py::arg("pattern"));
+ m.def("logger_set_file_appender",
+ &gr::logger_set_file_appender,
+ py::arg("logger"),
+ py::arg("filename"),
+ py::arg("append"),
+ py::arg("pattern"));
+ m.def("logger_add_rollingfile_appender",
+ &gr::logger_add_rollingfile_appender,
+ py::arg("logger"),
+ py::arg("filename"),
+ py::arg("filesize"),
+ py::arg("bkup_index"),
+ py::arg("append"),
+ py::arg("mode"),
+ py::arg("pattern"));
+ m.def("logger_get_logger_names", &gr::logger_get_logger_names);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/math_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/math_python.cc
new file mode 100644
index 0000000000..5ce47517a8
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/math_python.cc
@@ -0,0 +1,148 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(math.h) */
+/* BINDTOOL_HEADER_FILE_HASH(85ba2e8e7191733cc35f70005e2d99e9) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/math.h>
+// pydoc.h is automatically generated in the build directory
+#include <math_pydoc.h>
+
+void bind_math(py::module& m)
+{
+
+
+ m.def("fast_cc_multiply",
+ &::gr::fast_cc_multiply,
+ py::arg("out"),
+ py::arg("cc1"),
+ py::arg("cc2"),
+ D(fast_cc_multiply));
+
+
+ m.def("is_power_of_2", &::gr::is_power_of_2, py::arg("x"), D(is_power_of_2));
+
+
+ m.def("fast_atan2f",
+ (float (*)(float, float)) & ::gr::fast_atan2f,
+ py::arg("y"),
+ py::arg("x"),
+ D(fast_atan2f, 0));
+
+
+ m.def("fast_atan2f",
+ (float (*)(gr_complex)) & ::gr::fast_atan2f,
+ py::arg("z"),
+ D(fast_atan2f, 1));
+
+
+ m.def("branchless_clip",
+ &::gr::branchless_clip,
+ py::arg("x"),
+ py::arg("clip"),
+ D(branchless_clip));
+
+
+ m.def("clip", &::gr::clip, py::arg("x"), py::arg("clip"), D(clip));
+
+
+ m.def("binary_slicer", &::gr::binary_slicer, py::arg("x"), D(binary_slicer));
+
+
+ m.def("quad_45deg_slicer",
+ (unsigned int (*)(float, float)) & ::gr::quad_45deg_slicer,
+ py::arg("r"),
+ py::arg("i"),
+ D(quad_45deg_slicer, 0));
+
+
+ m.def("quad_0deg_slicer",
+ (unsigned int (*)(float, float)) & ::gr::quad_0deg_slicer,
+ py::arg("r"),
+ py::arg("i"),
+ D(quad_0deg_slicer, 0));
+
+
+ m.def("quad_45deg_slicer",
+ (unsigned int (*)(gr_complex)) & ::gr::quad_45deg_slicer,
+ py::arg("x"),
+ D(quad_45deg_slicer, 1));
+
+
+ m.def("quad_0deg_slicer",
+ (unsigned int (*)(gr_complex)) & ::gr::quad_0deg_slicer,
+ py::arg("x"),
+ D(quad_0deg_slicer, 1));
+
+
+ m.def("branchless_binary_slicer",
+ &::gr::branchless_binary_slicer,
+ py::arg("x"),
+ D(branchless_binary_slicer));
+
+
+ m.def("branchless_quad_0deg_slicer",
+ (unsigned int (*)(float, float)) & ::gr::branchless_quad_0deg_slicer,
+ py::arg("r"),
+ py::arg("i"),
+ D(branchless_quad_0deg_slicer, 0));
+
+
+ m.def("branchless_quad_0deg_slicer",
+ (unsigned int (*)(gr_complex)) & ::gr::branchless_quad_0deg_slicer,
+ py::arg("x"),
+ D(branchless_quad_0deg_slicer, 1));
+
+
+ m.def("branchless_quad_45deg_slicer",
+ (unsigned int (*)(float, float)) & ::gr::branchless_quad_45deg_slicer,
+ py::arg("r"),
+ py::arg("i"),
+ D(branchless_quad_45deg_slicer, 0));
+
+
+ m.def("branchless_quad_45deg_slicer",
+ (unsigned int (*)(gr_complex)) & ::gr::branchless_quad_45deg_slicer,
+ py::arg("x"),
+ D(branchless_quad_45deg_slicer, 1));
+
+
+ m.def("p2_round_down",
+ &::gr::p2_round_down,
+ py::arg("x"),
+ py::arg("pow2"),
+ D(p2_round_down));
+
+
+ m.def(
+ "p2_round_up", &::gr::p2_round_up, py::arg("x"), py::arg("pow2"), D(p2_round_up));
+
+
+ m.def("p2_modulo", &::gr::p2_modulo, py::arg("x"), py::arg("pow2"), D(p2_modulo));
+
+
+ m.def("p2_modulo_neg",
+ &::gr::p2_modulo_neg,
+ py::arg("x"),
+ py::arg("pow2"),
+ D(p2_modulo_neg));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/message_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/message_python.cc
new file mode 100644
index 0000000000..05d18d7234
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/message_python.cc
@@ -0,0 +1,91 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(message.h) */
+/* BINDTOOL_HEADER_FILE_HASH(1cbfd41a5d35bd455fea4eb0ec792379) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/message.h>
+// pydoc.h is automatically generated in the build directory
+#include <message_pydoc.h>
+
+void bind_message(py::module& m)
+{
+
+ using message = ::gr::message;
+
+
+ py::class_<message, std::shared_ptr<message>>(m, "message", D(message))
+
+ .def(py::init(&message::make),
+ py::arg("type") = 0,
+ py::arg("arg1") = 0,
+ py::arg("arg2") = 0,
+ py::arg("length") = 0,
+ D(message, make))
+
+
+ .def_static("make_from_string",
+ &message::make_from_string,
+ py::arg("s"),
+ py::arg("type") = 0,
+ py::arg("arg1") = 0,
+ py::arg("arg2") = 0,
+ D(message, make_from_string))
+
+
+ .def("type", &message::type, D(message, type))
+
+
+ .def("arg1", &message::arg1, D(message, arg1))
+
+
+ .def("arg2", &message::arg2, D(message, arg2))
+
+
+ .def("set_type", &message::set_type, py::arg("type"), D(message, set_type))
+ .def("set_arg1", &message::set_arg1, py::arg("arg1"), D(message, set_arg1))
+ .def("set_arg2", &message::set_arg2, py::arg("arg2"), D(message, set_arg2))
+ .def("msg", &message::msg, D(message, msg))
+
+ .def("length", &message::length)
+ // .def("to_string",&message::to_string)
+ // pybind11 needs explicit conversion to handle non-utf8 strings
+ .def("to_string",
+ [](std::shared_ptr<message> msg) {
+ std::string s = msg->to_string();
+ return py::bytes(s); // Return the data without transcoding
+ })
+
+
+ ;
+
+
+ m.def("message_ncurrently_allocated",
+ &::gr::message_ncurrently_allocated,
+ D(message_ncurrently_allocated));
+ m.def("message_from_string",
+ &message::make_from_string,
+ py::arg("s"),
+ py::arg("type") = 0,
+ py::arg("arg1") = 0,
+ py::arg("arg2") = 0);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_msgq_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_msgq_python.cc
new file mode 100644
index 0000000000..57069f3f64
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_msgq_python.cc
@@ -0,0 +1,33 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/messages/msg_accepter_msgq.h>
+
+void bind_messages_msg_accepter_msgq(py::module& m)
+{
+ using msg_accepter_msgq = gr::messages::msg_accepter_msgq;
+
+
+ py::class_<msg_accepter_msgq, std::shared_ptr<msg_accepter_msgq>>(
+ m, "messages_msg_accepter_msgq")
+
+ .def(py::init<gr::messages::msg_queue_sptr>(), py::arg("msgq"))
+ .def(py::init<gr::messages::msg_accepter_msgq const&>(), py::arg("arg0"))
+
+ .def("post", &msg_accepter_msgq::post, py::arg("msg"))
+ .def("msg_queue", &msg_accepter_msgq::msg_queue);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_python.cc
new file mode 100644
index 0000000000..fbad2e5eea
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_accepter_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/messages/msg_accepter.h>
+
+void bind_messages_msg_accepter(py::module& m)
+{
+ using msg_accepter = gr::messages::msg_accepter;
+
+
+ py::class_<msg_accepter, std::shared_ptr<msg_accepter>>(m, "messages_msg_accepter")
+
+ .def("post", &msg_accepter::post, py::arg("which_port"), py::arg("msg"));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_passing_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_passing_python.cc
new file mode 100644
index 0000000000..3564530a88
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_passing_python.cc
@@ -0,0 +1,51 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/messages/msg_passing.h>
+
+void bind_messages_msg_passing(py::module& m)
+{
+
+
+ m.def("send",
+ (pmt::pmt_t(*)(
+ gr::messages::msg_accepter_sptr, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ gr::messages::send,
+ py::arg("accepter"),
+ py::arg("which_port"),
+ py::arg("msg"));
+ m.def("send",
+ (pmt::pmt_t(*)(
+ gr::messages::msg_accepter*, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ gr::messages::send,
+ py::arg("accepter"),
+ py::arg("which_port"),
+ py::arg("msg"));
+ m.def("send",
+ (pmt::pmt_t(*)(
+ gr::messages::msg_accepter&, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ gr::messages::send,
+ py::arg("accepter"),
+ py::arg("which_port"),
+ py::arg("msg"));
+ m.def("send",
+ (pmt::pmt_t(*)(pmt::pmt_t, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ gr::messages::send,
+ py::arg("accepter"),
+ py::arg("which_port"),
+ py::arg("msg"));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_producer_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_producer_python.cc
new file mode 100644
index 0000000000..d519247ea3
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_producer_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/messages/msg_producer.h>
+
+void bind_messages_msg_producer(py::module& m)
+{
+ using msg_producer = gr::messages::msg_producer;
+
+
+ py::class_<msg_producer, std::shared_ptr<msg_producer>>(m, "messages_msg_producer")
+
+ .def("retrieve", &msg_producer::retrieve);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_queue_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_queue_python.cc
new file mode 100644
index 0000000000..c44a75b3c8
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/messages/msg_queue_python.cc
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/messages/msg_queue.h>
+
+void bind_messages_msg_queue(py::module& m)
+{
+ using msg_queue = gr::messages::msg_queue;
+
+
+ py::class_<msg_queue, std::shared_ptr<msg_queue>>(m, "messages_msg_queue")
+
+ .def(py::init<unsigned int>(), py::arg("limit"))
+
+ .def("insert_tail", &msg_queue::insert_tail, py::arg("msg"))
+ .def("delete_head", &msg_queue::delete_head)
+ .def("delete_head_nowait", &msg_queue::delete_head_nowait)
+ .def("flush", &msg_queue::flush)
+ .def("empty_p", &msg_queue::empty_p)
+ .def("full_p", &msg_queue::full_p)
+ .def("count", &msg_queue::count)
+ .def("limit", &msg_queue::limit);
+
+
+ // m.def("make_msg_queue",&gr::messages::make_msg_queue,
+ // py::arg("limit") = 0
+ // );
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/msg_accepter_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/msg_accepter_python.cc
new file mode 100644
index 0000000000..7b19d9d796
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/msg_accepter_python.cc
@@ -0,0 +1,55 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(msg_accepter.h) */
+/* BINDTOOL_HEADER_FILE_HASH(0816b1746a9c1a6dfa996b047917f9c1) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/msg_accepter.h>
+// pydoc.h is automatically generated in the build directory
+#include <msg_accepter_pydoc.h>
+
+void bind_msg_accepter(py::module& m)
+{
+
+ using msg_accepter = ::gr::msg_accepter;
+
+
+ py::class_<msg_accepter, gr::messages::msg_accepter, std::shared_ptr<msg_accepter>>(
+ m, "msg_accepter", D(msg_accepter))
+
+ .def(py::init<>(), D(msg_accepter, msg_accepter, 0))
+ .def(py::init<gr::msg_accepter const&>(),
+ py::arg("arg0"),
+ D(msg_accepter, msg_accepter, 1))
+
+
+ .def("post",
+ &msg_accepter::post,
+ py::arg("which_port"),
+ py::arg("msg"),
+ D(msg_accepter, post))
+
+ ;
+
+
+ py::module m_messages = m.def_submodule("messages");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/msg_handler_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/msg_handler_python.cc
new file mode 100644
index 0000000000..9aa4c9b57c
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/msg_handler_python.cc
@@ -0,0 +1,48 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(msg_handler.h) */
+/* BINDTOOL_HEADER_FILE_HASH(bd8c6ca9906efe1a5be8fb8e5965a7b2) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/msg_handler.h>
+// pydoc.h is automatically generated in the build directory
+#include <msg_handler_pydoc.h>
+
+void bind_msg_handler(py::module& m)
+{
+
+ using msg_handler = ::gr::msg_handler;
+
+
+ py::class_<msg_handler, std::shared_ptr<msg_handler>>(
+ m, "msg_handler", D(msg_handler))
+
+ // .def(py::init<>(),D(msg_handler,msg_handler,0))
+ // .def(py::init<gr::msg_handler const &>(), py::arg("arg0"),
+ // D(msg_handler,msg_handler,1)
+ // )
+
+
+ .def("handle", &msg_handler::handle, py::arg("msg"), D(msg_handler, handle))
+
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/msg_queue_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/msg_queue_python.cc
new file mode 100644
index 0000000000..1e58029429
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/msg_queue_python.cc
@@ -0,0 +1,77 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(msg_queue.h) */
+/* BINDTOOL_HEADER_FILE_HASH(0abeb5846ed511d2b4dd13479458f4be) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/msg_queue.h>
+// pydoc.h is automatically generated in the build directory
+#include <msg_queue_pydoc.h>
+
+void bind_msg_queue(py::module& m)
+{
+
+ using msg_queue = ::gr::msg_queue;
+
+
+ py::class_<msg_queue, gr::msg_handler, std::shared_ptr<msg_queue>>(
+ m, "msg_queue", D(msg_queue))
+
+ .def(py::init(&msg_queue::make), py::arg("limit") = 0, D(msg_queue, make))
+
+
+ .def("handle", &msg_queue::handle, py::arg("msg"), D(msg_queue, handle))
+
+
+ .def("insert_tail",
+ &msg_queue::insert_tail,
+ py::arg("msg"),
+ D(msg_queue, insert_tail))
+
+
+ .def("delete_head", &msg_queue::delete_head, D(msg_queue, delete_head))
+
+
+ .def("delete_head_nowait",
+ &msg_queue::delete_head_nowait,
+ D(msg_queue, delete_head_nowait))
+
+
+ .def("flush", &msg_queue::flush, D(msg_queue, flush))
+
+
+ .def("empty_p", &msg_queue::empty_p, D(msg_queue, empty_p))
+
+
+ .def("full_p", &msg_queue::full_p, D(msg_queue, full_p))
+
+
+ .def("count", &msg_queue::count, D(msg_queue, count))
+
+
+ .def("limit", &msg_queue::limit, D(msg_queue, limit))
+
+ ;
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/nco_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/nco_python.cc
new file mode 100644
index 0000000000..46736bd326
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/nco_python.cc
@@ -0,0 +1,30 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(nco.h) */
+/* BINDTOOL_HEADER_FILE_HASH(06b2a0c530b7660c0e6d19f503df55f9) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/nco.h>
+// pydoc.h is automatically generated in the build directory
+#include <nco_pydoc.h>
+
+void bind_nco(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/prefs_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/prefs_python.cc
new file mode 100644
index 0000000000..29a049618d
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/prefs_python.cc
@@ -0,0 +1,134 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(prefs.h) */
+/* BINDTOOL_HEADER_FILE_HASH(c461d885bc4fd82aa0301248e9f1e958) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/prefs.h>
+// pydoc.h is automatically generated in the build directory
+#include <prefs_pydoc.h>
+
+void bind_prefs(py::module& m)
+{
+
+ using prefs = ::gr::prefs;
+
+
+ py::class_<prefs, std::shared_ptr<prefs>>(m, "prefs", D(prefs))
+
+ .def(py::init<>(), D(prefs, prefs))
+
+
+ .def_static("singleton", &prefs::singleton, D(prefs, singleton))
+
+
+ .def("add_config_file",
+ &prefs::add_config_file,
+ py::arg("configfile"),
+ D(prefs, add_config_file))
+
+
+ .def("to_string", &prefs::to_string, D(prefs, to_string))
+
+
+ .def("save", &prefs::save, D(prefs, save))
+
+
+ .def(
+ "has_section", &prefs::has_section, py::arg("section"), D(prefs, has_section))
+
+
+ .def("has_option",
+ &prefs::has_option,
+ py::arg("section"),
+ py::arg("option"),
+ D(prefs, has_option))
+
+
+ .def("get_string",
+ &prefs::get_string,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("default_val"),
+ D(prefs, get_string))
+
+
+ .def("set_string",
+ &prefs::set_string,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("val"),
+ D(prefs, set_string))
+
+
+ .def("get_bool",
+ &prefs::get_bool,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("default_val"),
+ D(prefs, get_bool))
+
+
+ .def("set_bool",
+ &prefs::set_bool,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("val"),
+ D(prefs, set_bool))
+
+
+ .def("get_long",
+ &prefs::get_long,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("default_val"),
+ D(prefs, get_long))
+
+
+ .def("set_long",
+ &prefs::set_long,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("val"),
+ D(prefs, set_long))
+
+
+ .def("get_double",
+ &prefs::get_double,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("default_val"),
+ D(prefs, get_double))
+
+
+ .def("set_double",
+ &prefs::set_double,
+ py::arg("section"),
+ py::arg("option"),
+ py::arg("val"),
+ D(prefs, set_double))
+
+ ;
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/python_bindings.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/python_bindings.cc
new file mode 100644
index 0000000000..a178d2ac65
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/python_bindings.cc
@@ -0,0 +1,209 @@
+
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+#include <pybind11/pybind11.h>
+
+#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
+#include <gnuradio/gr_complex.h>
+#include <numpy/arrayobject.h>
+
+namespace py = pybind11;
+
+void bind_messages_msg_accepter_msgq(py::module&);
+void bind_messages_msg_accepter(py::module&);
+void bind_messages_msg_passing(py::module&);
+void bind_messages_msg_producer(py::module&);
+void bind_messages_msg_queue(py::module&);
+
+// void bind_attributes(py::module&);
+void bind_basic_block(py::module&);
+void bind_block(py::module&);
+void bind_block_detail(py::module&);
+void bind_block_gateway(py::module&);
+// void bind_block_registry(py::module&);
+void bind_buffer(py::module&);
+void bind_constants(py::module&);
+void bind_endianness(py::module&);
+void bind_expj(py::module&);
+void bind_flowgraph(py::module&);
+void bind_fxpt(py::module&);
+void bind_fxpt_nco(py::module&);
+void bind_fxpt_vco(py::module&);
+// void bind_gr_complex(py::module&);
+void bind_hier_block2(py::module&);
+void bind_high_res_timer(py::module&);
+void bind_io_signature(py::module&);
+void bind_logger(py::module&);
+void bind_math(py::module&);
+void bind_message(py::module&);
+void bind_msg_accepter(py::module&);
+// void bind_msg_accepter_msgq(py::module&);
+// void bind_msg_passing(py::module&);
+// void bind_msg_producer(py::module&);
+void bind_msg_queue(py::module&);
+// void bind_misc(py::module&);;
+void bind_msg_handler(py::module&);
+void bind_msg_queue(py::module&);
+void bind_nco(py::module&);
+void bind_prefs(py::module&);
+// void bind_pycallback_object(py::module&);
+void bind_random(py::module&);
+void bind_realtime(py::module&);
+// void bind_realtime_impl(py::module&);
+// void bind_rpcbufferedget(py::module&);
+// void bind_rpccallbackregister_base(py::module&);
+// void bind_rpcmanager(py::module&);
+// void bind_rpcmanager_base(py::module&);
+// void bind_rpcpmtconverters_thrift(py::module&);
+// void bind_rpcregisterhelpers(py::module&);
+// void bind_rpcserver_aggregator(py::module&);
+// void bind_rpcserver_base(py::module&);
+// void bind_rpcserver_booter_aggregator(py::module&);
+// void bind_rpcserver_booter_base(py::module&);
+// void bind_rpcserver_booter_thrift(py::module&);
+// void bind_rpcserver_selector(py::module&);
+// void bind_rpcserver_thrift(py::module&);
+void bind_runtime_types(py::module&);
+void bind_sincos(py::module&);
+void bind_sptr_magic(py::module&);
+void bind_sync_block(py::module&);
+void bind_sync_decimator(py::module&);
+void bind_sync_interpolator(py::module&);
+void bind_sys_paths(py::module&);
+void bind_tag_checker(py::module&);
+void bind_tagged_stream_block(py::module&);
+void bind_tags(py::module&);
+// void bind_thread(py::module&);
+// void bind_thread_body_wrapper(py::module&);
+// void bind_thread_group(py::module&);
+// void bind_thrift_application_base(py::module&);
+// void bind_thrift_server_template(py::module&);
+void bind_top_block(py::module&);
+void bind_tpb_detail(py::module&);
+// void bind_types(py::module&);
+// void bind_unittests(py::module&);
+// void bind_xoroshiro128p(py::module&);
+
+// We need this hack because import_array() returns NULL
+// for newer Python versions.
+// This function is also necessary because it ensures access to the C API
+// and removes a warning.
+void* init_numpy()
+{
+ import_array();
+ return NULL;
+}
+
+PYBIND11_MODULE(gr_python, m)
+{
+ // Initialize the numpy C API
+ // (otherwise we will see segmentation faults)
+ init_numpy();
+
+ // Allow access to base block methods
+ py::module::import("pmt");
+
+
+ bind_messages_msg_accepter(m);
+ bind_messages_msg_queue(m);
+ bind_messages_msg_accepter_msgq(m);
+ bind_messages_msg_passing(m);
+ bind_messages_msg_producer(m);
+
+
+ bind_msg_accepter(m);
+ bind_msg_handler(m);
+ bind_msg_queue(m);
+
+ bind_io_signature(m);
+ // // bind_attributes(m);
+ bind_basic_block(m);
+ bind_block(m);
+ bind_block_detail(m);
+ bind_block_gateway(m);
+ // // bind_block_registry(m);
+ bind_buffer(m);
+ bind_constants(m);
+ bind_endianness(m);
+ bind_expj(m);
+ bind_flowgraph(m);
+ bind_fxpt(m);
+ bind_fxpt_nco(m);
+ bind_fxpt_vco(m);
+ // // bind_gr_complex(m);
+ bind_hier_block2(m);
+ bind_high_res_timer(m);
+
+ bind_logger(m);
+ bind_math(m);
+ bind_message(m);
+
+ // // bind_msg_accepter_msgq(m);
+ // // bind_msg_passing(m);
+ // // bind_msg_producer(m);
+
+ // // bind_misc(m);
+
+
+ bind_nco(m);
+ bind_prefs(m);
+ // // bind_pycallback_object(m);
+ bind_random(m);
+ bind_realtime(m);
+ // // bind_realtime_impl(m);
+ // // bind_rpcbufferedget(m);
+ // // bind_rpccallbackregister_base(m);
+ // // bind_rpcmanager(m);
+ // // bind_rpcmanager_base(m);
+ // // bind_rpcpmtconverters_thrift(m);
+ // // bind_rpcregisterhelpers(m);
+ // // bind_rpcserver_aggregator(m);
+ // // bind_rpcserver_base(m);
+ // // bind_rpcserver_booter_aggregator(m);
+ // // bind_rpcserver_booter_base(m);
+ // // bind_rpcserver_booter_thrift(m);
+ // // bind_rpcserver_selector(m);
+ // // bind_rpcserver_thrift(m);
+ bind_runtime_types(m);
+ bind_sincos(m);
+ bind_sptr_magic(m);
+ bind_sync_block(m);
+ bind_sync_decimator(m);
+ bind_sync_interpolator(m);
+ bind_sys_paths(m);
+ bind_tag_checker(m);
+ bind_tagged_stream_block(m);
+ bind_tags(m);
+ // // bind_thread(m);
+ // // bind_thread_body_wrapper(m);
+ // // bind_thread_group(m);
+ // // bind_thrift_application_base(m);
+ // // bind_thrift_server_template(m);
+ bind_top_block(m);
+ bind_tpb_detail(m);
+ // // bind_types(m);
+ // // bind_unittests(m);
+ // // bind_xoroshiro128p(m);
+
+
+ // TODO: Move into gr_types.hpp
+ // %constant int sizeof_char = sizeof(char);
+ m.attr("sizeof_char") = sizeof(char);
+ // %constant int sizeof_short = sizeof(short);
+ m.attr("sizeof_short") = sizeof(short);
+ // %constant int sizeof_int = sizeof(int);
+ m.attr("sizeof_int") = sizeof(int);
+ // %constant int sizeof_float = sizeof(float);
+ m.attr("sizeof_float") = sizeof(float);
+ // %constant int sizeof_double = sizeof(double);
+ m.attr("sizeof_double") = sizeof(double);
+ // %constant int sizeof_gr_complex = sizeof(gr_complex);
+ m.attr("sizeof_gr_complex") = sizeof(gr_complex);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc
new file mode 100644
index 0000000000..cc6942bbc9
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/random_python.cc
@@ -0,0 +1,77 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(random.h) */
+/* BINDTOOL_HEADER_FILE_HASH(7f6d1465c630113ffe56d12f0e8b65a8) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/random.h>
+// pydoc.h is automatically generated in the build directory
+#include <random_pydoc.h>
+
+void bind_random(py::module& m)
+{
+
+ using random = ::gr::random;
+
+
+ py::class_<random, std::shared_ptr<random>>(m, "random", D(random))
+
+ .def(py::init<unsigned int, int, int>(),
+ py::arg("seed") = 0,
+ py::arg("min_integer") = 0,
+ py::arg("max_integer") = 2,
+ D(random, random, 0))
+ .def(py::init<gr::random const&>(), py::arg("arg0"), D(random, random, 1))
+
+
+ .def("reseed", &random::reseed, py::arg("seed"), D(random, reseed))
+
+
+ .def("set_integer_limits",
+ &random::set_integer_limits,
+ py::arg("minimum"),
+ py::arg("maximum"),
+ D(random, set_integer_limits))
+
+
+ .def("ran_int", &random::ran_int, D(random, ran_int))
+
+
+ .def("ran1", &random::ran1, D(random, ran1))
+
+
+ .def("gasdev", &random::gasdev, D(random, gasdev))
+
+
+ .def("laplacian", &random::laplacian, D(random, laplacian))
+
+
+ .def("rayleigh", &random::rayleigh, D(random, rayleigh))
+
+
+ .def("impulse", &random::impulse, py::arg("factor"), D(random, impulse))
+
+
+ .def("rayleigh_complex", &random::rayleigh_complex, D(random, rayleigh_complex))
+
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/realtime_impl_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/realtime_impl_python.cc
new file mode 100644
index 0000000000..792181483d
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/realtime_impl_python.cc
@@ -0,0 +1,81 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(realtime_impl.h) */
+/* BINDTOOL_HEADER_FILE_HASH(26d690b565b0b5c7489e5969d697ebf6) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/realtime_impl.h>
+// pydoc.h is automatically generated in the build directory
+#include <realtime_impl_pydoc.h>
+
+void bind_realtime_impl(py::module& m)
+{
+
+
+ py::enum_<::gr::rt_status_t>(m, "rt_status_t")
+ .value("RT_OK", ::gr::RT_OK) // 0
+ .value("RT_NOT_IMPLEMENTED", ::gr::RT_NOT_IMPLEMENTED) // 1
+ .value("RT_NO_PRIVS", ::gr::RT_NO_PRIVS) // 2
+ .value("RT_OTHER_ERROR", ::gr::RT_OTHER_ERROR) // 3
+ .export_values();
+ py::enum_<::gr::rt_sched_policy>(m, "rt_sched_policy")
+ .value("RT_SCHED_RR", ::gr::RT_SCHED_RR) // 0
+ .value("RT_SCHED_FIFO", ::gr::RT_SCHED_FIFO) // 1
+ .export_values();
+
+
+ py::module m_impl = m.def_submodule("impl");
+
+ using rt_sched_param = ::gr::impl::rt_sched_param;
+
+
+ py::class_<rt_sched_param, std::shared_ptr<rt_sched_param>>(
+ m_impl, "rt_sched_param", D(impl, rt_sched_param))
+
+ .def(py::init<>(), D(impl, rt_sched_param, rt_sched_param, 0))
+ .def(py::init<int, gr::rt_sched_policy>(),
+ py::arg("priority_"),
+ py::arg("policy_") = ::gr::rt_sched_policy::RT_SCHED_RR,
+ D(impl, rt_sched_param, rt_sched_param, 1))
+ .def(py::init<gr::impl::rt_sched_param const&>(),
+ py::arg("arg0"),
+ D(impl, rt_sched_param, rt_sched_param, 2))
+
+ ;
+
+
+ m_impl.def("rt_priority_min", &::gr::impl::rt_priority_min, D(impl, rt_priority_min));
+
+
+ m_impl.def("rt_priority_max", &::gr::impl::rt_priority_max, D(impl, rt_priority_max));
+
+
+ m_impl.def("rt_priority_default",
+ &::gr::impl::rt_priority_default,
+ D(impl, rt_priority_default));
+
+
+ m_impl.def("enable_realtime_scheduling",
+ &::gr::impl::enable_realtime_scheduling,
+ py::arg("arg0") = gr::impl::rt_sched_param(),
+ D(impl, enable_realtime_scheduling));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/realtime_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/realtime_python.cc
new file mode 100644
index 0000000000..5efd134281
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/realtime_python.cc
@@ -0,0 +1,40 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(realtime.h) */
+/* BINDTOOL_HEADER_FILE_HASH(3a8add4fc688853c32e8c4c8f8e51d0e) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/realtime.h>
+// pydoc.h is automatically generated in the build directory
+#include <realtime_pydoc.h>
+
+void bind_realtime(py::module& m)
+{
+
+
+ m.def("enable_realtime_scheduling",
+ &::gr::enable_realtime_scheduling,
+ D(enable_realtime_scheduling));
+
+
+ py::module m_impl = m.def_submodule("impl");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/rpccallbackregister_base_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/rpccallbackregister_base_python.cc
new file mode 100644
index 0000000000..dc20480934
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/rpccallbackregister_base_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(rpccallbackregister_base.h) */
+/* BINDTOOL_HEADER_FILE_HASH(59490b02954c38c1ac4959ee0cd05bd3) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/rpccallbackregister_base.h>
+
+void bind_rpccallbackregister_base(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/rpcmanager_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcmanager_python.cc
new file mode 100644
index 0000000000..c3ba494207
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcmanager_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(rpcmanager.h) */
+/* BINDTOOL_HEADER_FILE_HASH(0bf64e51db052f5a5322be2e472e3cca) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/rpcmanager.h>
+
+void bind_rpcmanager(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/rpcregisterhelpers_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcregisterhelpers_python.cc
new file mode 100644
index 0000000000..8043b048d3
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcregisterhelpers_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(rpcregisterhelpers.h) */
+/* BINDTOOL_HEADER_FILE_HASH(161051f19450588919336b43b4cabc4c) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/rpcregisterhelpers.h>
+
+void bind_rpcregisterhelpers(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_aggregator_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_aggregator_python.cc
new file mode 100644
index 0000000000..b8192873ea
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_aggregator_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(rpcserver_aggregator.h) */
+/* BINDTOOL_HEADER_FILE_HASH(2ffd2a6120b931d25fe874b3adede335) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/rpcserver_aggregator.h>
+
+void bind_rpcserver_aggregator(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_base_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_base_python.cc
new file mode 100644
index 0000000000..f02247e7b4
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_base_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(rpcserver_base.h) */
+/* BINDTOOL_HEADER_FILE_HASH(a90868b635febb56fec31daeffa36498) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/rpcserver_base.h>
+
+void bind_rpcserver_base(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_booter_aggregator_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_booter_aggregator_python.cc
new file mode 100644
index 0000000000..84daa5d8e7
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/rpcserver_booter_aggregator_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(rpcserver_booter_aggregator.h) */
+/* BINDTOOL_HEADER_FILE_HASH(f9a0f4f8fd77eb6045b728cd817aa0a4) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/rpcserver_booter_aggregator.h>
+
+void bind_rpcserver_booter_aggregator(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/runtime_types_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/runtime_types_python.cc
new file mode 100644
index 0000000000..60da3d239b
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/runtime_types_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(runtime_types.h) */
+/* BINDTOOL_HEADER_FILE_HASH(bdd73d157525d81f339b38343434eb8f) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/runtime_types.h>
+
+void bind_runtime_types(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/sincos_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/sincos_python.cc
new file mode 100644
index 0000000000..fb71a14543
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/sincos_python.cc
@@ -0,0 +1,48 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(sincos.h) */
+/* BINDTOOL_HEADER_FILE_HASH(799a972b9b6f7739795b7a0eda58e163) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/sincos.h>
+// pydoc.h is automatically generated in the build directory
+#include <sincos_pydoc.h>
+
+void bind_sincos(py::module& m)
+{
+
+
+ m.def("sincos",
+ &::gr::sincos,
+ py::arg("x"),
+ py::arg("sinx"),
+ py::arg("cosx"),
+ D(sincos));
+
+
+ m.def("sincosf",
+ &::gr::sincosf,
+ py::arg("x"),
+ py::arg("sinx"),
+ py::arg("cosx"),
+ D(sincosf));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/sptr_magic_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/sptr_magic_python.cc
new file mode 100644
index 0000000000..91706dd079
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/sptr_magic_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(sptr_magic.h) */
+/* BINDTOOL_HEADER_FILE_HASH(53ec33a057706160ccd13788ef91ab9b) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/sptr_magic.h>
+
+void bind_sptr_magic(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/sync_block_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/sync_block_python.cc
new file mode 100644
index 0000000000..884ea84f54
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/sync_block_python.cc
@@ -0,0 +1,82 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(sync_block.h) */
+/* BINDTOOL_HEADER_FILE_HASH(a4c0cf64175558267b81683da25f8caa) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/sync_block.h>
+// pydoc.h is automatically generated in the build directory
+#include <sync_block_pydoc.h>
+
+void bind_sync_block(py::module& m)
+{
+
+ using sync_block = ::gr::sync_block;
+
+
+ py::class_<sync_block, gr::block, gr::basic_block, std::shared_ptr<sync_block>>(
+ m, "sync_block", D(sync_block))
+
+
+ .def("work",
+ &sync_block::work,
+ py::arg("noutput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(sync_block, work))
+
+
+ .def("forecast",
+ &sync_block::forecast,
+ py::arg("noutput_items"),
+ py::arg("ninput_items_required"),
+ D(sync_block, forecast))
+
+
+ .def("general_work",
+ &sync_block::general_work,
+ py::arg("noutput_items"),
+ py::arg("ninput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(sync_block, general_work))
+
+
+ .def("fixed_rate_ninput_to_noutput",
+ &sync_block::fixed_rate_ninput_to_noutput,
+ py::arg("ninput"),
+ D(sync_block, fixed_rate_ninput_to_noutput))
+
+
+ .def("fixed_rate_noutput_to_ninput",
+ &sync_block::fixed_rate_noutput_to_ninput,
+ py::arg("noutput"),
+ D(sync_block, fixed_rate_noutput_to_ninput))
+
+ ;
+
+
+ py::module m_messages = m.def_submodule("messages");
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/sync_decimator_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/sync_decimator_python.cc
new file mode 100644
index 0000000000..48030fdf1a
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/sync_decimator_python.cc
@@ -0,0 +1,86 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(sync_decimator.h) */
+/* BINDTOOL_HEADER_FILE_HASH(b6dc9db79f929ad2a09fbd28c6ee3f9a) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/sync_decimator.h>
+// pydoc.h is automatically generated in the build directory
+#include <sync_decimator_pydoc.h>
+
+void bind_sync_decimator(py::module& m)
+{
+
+ using sync_decimator = ::gr::sync_decimator;
+
+
+ py::class_<sync_decimator,
+ gr::sync_block,
+ gr::block,
+ gr::basic_block,
+ std::shared_ptr<sync_decimator>>(m, "sync_decimator", D(sync_decimator))
+
+
+ .def("decimation", &sync_decimator::decimation, D(sync_decimator, decimation))
+
+
+ .def("set_decimation",
+ &sync_decimator::set_decimation,
+ py::arg("decimation"),
+ D(sync_decimator, set_decimation))
+
+
+ .def("forecast",
+ &sync_decimator::forecast,
+ py::arg("noutput_items"),
+ py::arg("ninput_items_required"),
+ D(sync_decimator, forecast))
+
+
+ .def("general_work",
+ &sync_decimator::general_work,
+ py::arg("noutput_items"),
+ py::arg("ninput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(sync_decimator, general_work))
+
+
+ .def("fixed_rate_ninput_to_noutput",
+ &sync_decimator::fixed_rate_ninput_to_noutput,
+ py::arg("ninput"),
+ D(sync_decimator, fixed_rate_ninput_to_noutput))
+
+
+ .def("fixed_rate_noutput_to_ninput",
+ &sync_decimator::fixed_rate_noutput_to_ninput,
+ py::arg("noutput"),
+ D(sync_decimator, fixed_rate_noutput_to_ninput))
+
+ ;
+
+
+ py::module m_messages = m.def_submodule("messages");
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/sync_interpolator_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/sync_interpolator_python.cc
new file mode 100644
index 0000000000..fd76c632e4
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/sync_interpolator_python.cc
@@ -0,0 +1,89 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(sync_interpolator.h) */
+/* BINDTOOL_HEADER_FILE_HASH(8a002a4a14c8cc88411bf3b4b0234e7a) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/sync_interpolator.h>
+// pydoc.h is automatically generated in the build directory
+#include <sync_interpolator_pydoc.h>
+
+void bind_sync_interpolator(py::module& m)
+{
+
+ using sync_interpolator = ::gr::sync_interpolator;
+
+
+ py::class_<sync_interpolator,
+ gr::sync_block,
+ gr::block,
+ gr::basic_block,
+ std::shared_ptr<sync_interpolator>>(
+ m, "sync_interpolator", D(sync_interpolator))
+
+
+ .def("interpolation",
+ &sync_interpolator::interpolation,
+ D(sync_interpolator, interpolation))
+
+
+ .def("set_interpolation",
+ &sync_interpolator::set_interpolation,
+ py::arg("interpolation"),
+ D(sync_interpolator, set_interpolation))
+
+
+ .def("forecast",
+ &sync_interpolator::forecast,
+ py::arg("noutput_items"),
+ py::arg("ninput_items_required"),
+ D(sync_interpolator, forecast))
+
+
+ .def("general_work",
+ &sync_interpolator::general_work,
+ py::arg("noutput_items"),
+ py::arg("ninput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(sync_interpolator, general_work))
+
+
+ .def("fixed_rate_ninput_to_noutput",
+ &sync_interpolator::fixed_rate_ninput_to_noutput,
+ py::arg("ninput"),
+ D(sync_interpolator, fixed_rate_ninput_to_noutput))
+
+
+ .def("fixed_rate_noutput_to_ninput",
+ &sync_interpolator::fixed_rate_noutput_to_ninput,
+ py::arg("noutput"),
+ D(sync_interpolator, fixed_rate_noutput_to_ninput))
+
+ ;
+
+
+ py::module m_messages = m.def_submodule("messages");
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/sys_paths_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/sys_paths_python.cc
new file mode 100644
index 0000000000..f7c410c3c1
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/sys_paths_python.cc
@@ -0,0 +1,41 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(sys_paths.h) */
+/* BINDTOOL_HEADER_FILE_HASH(d612f4abb40047c64395b4177ff3ae1f) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/sys_paths.h>
+// pydoc.h is automatically generated in the build directory
+#include <sys_paths_pydoc.h>
+
+void bind_sys_paths(py::module& m)
+{
+
+
+ m.def("tmp_path", &::gr::tmp_path, D(tmp_path));
+
+
+ m.def("appdata_path", &::gr::appdata_path, D(appdata_path));
+
+
+ m.def("userconf_path", &::gr::userconf_path, D(userconf_path));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/tag_checker_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/tag_checker_python.cc
new file mode 100644
index 0000000000..cfe40c6a1b
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/tag_checker_python.cc
@@ -0,0 +1,57 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(tag_checker.h) */
+/* BINDTOOL_HEADER_FILE_HASH(4f4bad08f4f039dbd5150a36e29d365c) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/tag_checker.h>
+// pydoc.h is automatically generated in the build directory
+#include <tag_checker_pydoc.h>
+
+void bind_tag_checker(py::module& m)
+{
+
+ using tag_checker = ::gr::tag_checker;
+
+
+ py::class_<tag_checker, std::shared_ptr<tag_checker>>(
+ m, "tag_checker", D(tag_checker))
+
+ .def(py::init<std::vector<gr::tag_t, std::allocator<gr::tag_t>>&>(),
+ py::arg("tags"),
+ D(tag_checker, tag_checker, 0))
+ .def(py::init<gr::tag_checker const&>(),
+ py::arg("arg0"),
+ D(tag_checker, tag_checker, 1))
+
+
+ .def("get_tags",
+ &tag_checker::get_tags,
+ py::arg("tag_list"),
+ py::arg("offset"),
+ D(tag_checker, get_tags))
+
+ ;
+
+
+ py::module m_messages = m.def_submodule("messages");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/tagged_stream_block_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/tagged_stream_block_python.cc
new file mode 100644
index 0000000000..369ac8ba32
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/tagged_stream_block_python.cc
@@ -0,0 +1,81 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(tagged_stream_block.h) */
+/* BINDTOOL_HEADER_FILE_HASH(03f4139c3fd58d7c80fde38da58ef670) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/tagged_stream_block.h>
+// pydoc.h is automatically generated in the build directory
+#include <tagged_stream_block_pydoc.h>
+
+void bind_tagged_stream_block(py::module& m)
+{
+
+ using tagged_stream_block = ::gr::tagged_stream_block;
+
+
+ py::class_<tagged_stream_block,
+ gr::block,
+ gr::basic_block,
+ std::shared_ptr<tagged_stream_block>>(
+ m, "tagged_stream_block", D(tagged_stream_block))
+
+
+ .def("forecast",
+ &tagged_stream_block::forecast,
+ py::arg("noutput_items"),
+ py::arg("ninput_items_required"),
+ D(tagged_stream_block, forecast))
+
+
+ .def("check_topology",
+ &tagged_stream_block::check_topology,
+ py::arg("ninputs"),
+ py::arg("arg1"),
+ D(tagged_stream_block, check_topology))
+
+
+ .def("general_work",
+ &tagged_stream_block::general_work,
+ py::arg("noutput_items"),
+ py::arg("ninput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(tagged_stream_block, general_work))
+
+
+ .def("work",
+ &tagged_stream_block::work,
+ py::arg("noutput_items"),
+ py::arg("ninput_items"),
+ py::arg("input_items"),
+ py::arg("output_items"),
+ D(tagged_stream_block, work))
+
+ ;
+
+
+ py::module m_messages = m.def_submodule("messages");
+
+
+ py::module m_thread = m.def_submodule("thread");
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/tags_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/tags_python.cc
new file mode 100644
index 0000000000..2487be0100
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/tags_python.cc
@@ -0,0 +1,55 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(tags.h) */
+/* BINDTOOL_HEADER_FILE_HASH(73eb73e445943e224cdbae24b0b0ab76) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/tags.h>
+// pydoc.h is automatically generated in the build directory
+#include <tags_pydoc.h>
+
+void bind_tags(py::module& m)
+{
+
+ using tag_t = ::gr::tag_t;
+
+
+ py::class_<tag_t, std::shared_ptr<tag_t>>(m, "tag_t", D(tag_t))
+
+ .def(py::init<>(), D(tag_t, tag_t, 0))
+ .def(py::init<gr::tag_t const&>(), py::arg("rhs"), D(tag_t, tag_t, 1))
+
+ .def_static("offset_compare",
+ &tag_t::offset_compare,
+ py::arg("x"),
+ py::arg("y"),
+ D(tag_t, offset_compare))
+
+ .def_readwrite("offset", &tag_t::offset)
+ .def_readwrite("key", &tag_t::key)
+ .def_readwrite("value", &tag_t::value)
+ .def_readwrite("srcid", &tag_t::srcid)
+ .def_readwrite("marked_deleted", &tag_t::marked_deleted)
+
+ // TODO - put in operators
+ ;
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_body_wrapper_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_body_wrapper_python.cc
new file mode 100644
index 0000000000..b062a0d303
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_body_wrapper_python.cc
@@ -0,0 +1,20 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/thread_body_wrapper.h>
+
+void bind_thread_body_wrapper(py::module& m) { m.def("mask_signals", &gr::mask_signals); }
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_group_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_group_python.cc
new file mode 100644
index 0000000000..66666898a3
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_group_python.cc
@@ -0,0 +1,37 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/thread_group.h>
+
+void bind_thread_group(py::module& m)
+{
+ using thread_group = gr::thread_group;
+
+
+ py::class_<thread_group,
+ boost::noncopyable_::noncopyable,
+ std::shared_ptr<thread_group>>(m, "thread_group")
+
+ .def(py::init<>())
+
+ .def("create_thread", &thread_group::create_thread, py::arg("threadfunc"))
+ .def("add_thread", &thread_group::add_thread, py::arg("thrd"))
+ .def("remove_thread", &thread_group::remove_thread, py::arg("thrd"))
+ .def("join_all", &thread_group::join_all)
+ .def("interrupt_all", &thread_group::interrupt_all)
+ .def("size", &thread_group::size);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_python.cc
new file mode 100644
index 0000000000..87e769ef88
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/thread/thread_python.cc
@@ -0,0 +1,53 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/thread.h>
+
+void bind_thread(py::module& m)
+{
+
+
+ m.def("get_current_thread_id", &gr::get_current_thread_id);
+ m.def("thread_bind_to_processor",
+ (void (*)(std::vector<int, std::allocator<int>> const&)) &
+ gr::thread_bind_to_processor,
+ py::arg("mask"));
+ m.def("thread_bind_to_processor",
+ (void (*)(int)) & gr::thread_bind_to_processor,
+ py::arg("n"));
+ m.def("thread_bind_to_processor",
+ (void (*)(gr::thread::gr_thread_t,
+ std::vector<int, std::allocator<int>> const&)) &
+ gr::thread_bind_to_processor,
+ py::arg("thread"),
+ py::arg("mask"));
+ m.def("thread_bind_to_processor",
+ (void (*)(gr::thread::gr_thread_t, unsigned int)) &
+ gr::thread_bind_to_processor,
+ py::arg("thread"),
+ py::arg("n"));
+ m.def("thread_unbind", (void (*)()) & gr::thread_unbind);
+ m.def("thread_unbind",
+ (void (*)(gr::thread::gr_thread_t)) & gr::thread_unbind,
+ py::arg("thread"));
+ m.def("thread_priority", &gr::thread_priority, py::arg("thread"));
+ m.def("set_thread_priority",
+ &gr::set_thread_priority,
+ py::arg("thread"),
+ py::arg("priority"));
+ m.def("set_thread_name", &gr::set_thread_name, py::arg("thread"), py::arg("name"));
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/thrift_application_base_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/thrift_application_base_python.cc
new file mode 100644
index 0000000000..b7e5fa0f23
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/thrift_application_base_python.cc
@@ -0,0 +1,28 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(thrift_application_base.h) */
+/* BINDTOOL_HEADER_FILE_HASH(6308813ad7a4fccf1d2baa9ab79a8634) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/thrift_application_base.h>
+
+void bind_thrift_application_base(py::module& m) {}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/top_block_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/top_block_python.cc
new file mode 100644
index 0000000000..16a9c817a8
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/top_block_python.cc
@@ -0,0 +1,154 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(top_block.h) */
+/* BINDTOOL_HEADER_FILE_HASH(c3f0d1bdb473739fbd3e929fc8338e94) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/runtime_types.h>
+#include <gnuradio/top_block.h>
+// pydoc.h is automatically generated in the build directory
+#include <top_block_pydoc.h>
+
+#define GR_PYTHON_BLOCKING_CODE(code) \
+ { \
+ PyThreadState* _save; \
+ _save = PyEval_SaveThread(); \
+ try { \
+ code \
+ } catch (...) { \
+ PyEval_RestoreThread(_save); \
+ throw; \
+ } \
+ PyEval_RestoreThread(_save); \
+ }
+
+
+void top_block_run_unlocked(gr::top_block_sptr r) noexcept(false)
+{
+ GR_PYTHON_BLOCKING_CODE(r->run();)
+}
+
+void top_block_start_unlocked(gr::top_block_sptr r, int max_noutput_items) noexcept(false)
+{
+ GR_PYTHON_BLOCKING_CODE(r->start(max_noutput_items);)
+}
+
+void top_block_wait_unlocked(gr::top_block_sptr r) noexcept(false)
+{
+ GR_PYTHON_BLOCKING_CODE(r->wait();)
+}
+
+void top_block_stop_unlocked(gr::top_block_sptr r) noexcept(false)
+{
+ GR_PYTHON_BLOCKING_CODE(r->stop();)
+}
+
+void top_block_unlock_unlocked(gr::top_block_sptr r) noexcept(false)
+{
+ GR_PYTHON_BLOCKING_CODE(r->unlock();)
+}
+
+
+void bind_top_block(py::module& m)
+{
+ using top_block = gr::top_block;
+
+
+ py::class_<top_block, gr::hier_block2, gr::basic_block, std::shared_ptr<top_block>>(
+ m, "top_block_pb", D(top_block))
+
+
+ .def(py::init(&gr::make_top_block),
+ py::arg("name"),
+ py::arg("catch_exceptions") = false)
+
+ .def("run",
+ &top_block::run,
+ py::arg("max_noutput_items") = 100000000,
+ D(top_block, run))
+
+
+ .def("start",
+ &top_block::start,
+ py::arg("max_noutput_items") = 100000000,
+ D(top_block, start))
+
+
+ .def("stop", &top_block::stop, D(top_block, stop))
+
+
+ .def("wait", &top_block::wait, D(top_block, wait))
+
+
+ .def("lock", &top_block::lock, D(top_block, lock))
+
+
+ .def("unlock", &top_block::unlock, D(top_block, unlock))
+
+
+ .def("edge_list", &top_block::edge_list, D(top_block, edge_list))
+
+
+ .def("msg_edge_list", &top_block::msg_edge_list, D(top_block, msg_edge_list))
+
+
+ .def("dump", &top_block::dump, D(top_block, dump))
+
+
+ .def("max_noutput_items",
+ &top_block::max_noutput_items,
+ D(top_block, max_noutput_items))
+
+
+ .def("set_max_noutput_items",
+ &top_block::set_max_noutput_items,
+ py::arg("nmax"),
+ D(top_block, set_max_noutput_items))
+
+
+ .def("to_top_block", &top_block::to_top_block, D(top_block, to_top_block))
+
+
+ .def("setup_rpc", &top_block::setup_rpc, D(top_block, setup_rpc))
+
+ ;
+
+
+ m.def("make_top_block",
+ &::gr::make_top_block,
+ py::arg("name"),
+ py::arg("catch_exceptions") = true,
+ D(make_top_block));
+
+
+ m.def("cast_to_top_block_sptr",
+ &::gr::cast_to_top_block_sptr,
+ py::arg("block"),
+ D(cast_to_top_block_sptr));
+
+
+ m.def("top_block_run_unlocked", &top_block_run_unlocked);
+ m.def("top_block_start_unlocked", &top_block_start_unlocked);
+ m.def("top_block_wait_unlocked", &top_block_wait_unlocked);
+ m.def("top_block_stop_unlocked", &top_block_stop_unlocked);
+ m.def("top_block_unlock_unlocked", &top_block_unlock_unlocked);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/bindings/tpb_detail_python.cc b/gnuradio-runtime/python/gnuradio/gr/bindings/tpb_detail_python.cc
new file mode 100644
index 0000000000..0e7a90aedd
--- /dev/null
+++ b/gnuradio-runtime/python/gnuradio/gr/bindings/tpb_detail_python.cc
@@ -0,0 +1,56 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/***********************************************************************************/
+/* This file is automatically generated using bindtool and can be manually edited */
+/* The following lines can be configured to regenerate this file during cmake */
+/* If manual edits are made, the following tags should be modified accordingly. */
+/* BINDTOOL_GEN_AUTOMATIC(0) */
+/* BINDTOOL_USE_PYGCCXML(0) */
+/* BINDTOOL_HEADER_FILE(tpb_detail.h) */
+/* BINDTOOL_HEADER_FILE_HASH(e08c6f246b04f1719d3377c5e3992f53) */
+/***********************************************************************************/
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <gnuradio/block_detail.h>
+#include <gnuradio/tpb_detail.h>
+// pydoc.h is automatically generated in the build directory
+#include <tpb_detail_pydoc.h>
+
+void bind_tpb_detail(py::module& m)
+{
+
+ using tpb_detail = ::gr::tpb_detail;
+
+
+ py::class_<tpb_detail, std::shared_ptr<tpb_detail>>(m, "tpb_detail", D(tpb_detail))
+
+ .def(py::init<>(), D(tpb_detail, tpb_detail))
+
+
+ .def("notify_upstream",
+ &tpb_detail::notify_upstream,
+ py::arg("d"),
+ D(tpb_detail, notify_upstream))
+ .def("notify_downstream",
+ &tpb_detail::notify_downstream,
+ py::arg("d"),
+ D(tpb_detail, notify_downstream))
+ .def("notify_neighbors",
+ &tpb_detail::notify_neighbors,
+ py::arg("d"),
+ D(tpb_detail, notify_neighbors))
+ .def("notify_msg", &tpb_detail::notify_msg)
+ .def("clear_changed", &tpb_detail::clear_changed);
+}
diff --git a/gnuradio-runtime/python/gnuradio/gr/gateway.py b/gnuradio-runtime/python/gnuradio/gr/gateway.py
index 71d15781d2..615027b833 100644
--- a/gnuradio-runtime/python/gnuradio/gr/gateway.py
+++ b/gnuradio-runtime/python/gnuradio/gr/gateway.py
@@ -1,5 +1,5 @@
#
-# Copyright 2011-2012, 2018 Free Software Foundation, Inc.
+# Copyright 2011-2012, 2018, 2020 Free Software Foundation, Inc.
#
# This file is part of GNU Radio
#
@@ -12,11 +12,12 @@ from __future__ import unicode_literals
import numpy
+import ctypes
+
+from . import gr_python as gr
+from .gr_python import io_signature # , io_signaturev
+from .gr_python import block_gateway
-from . import runtime_swig as gr
-from .runtime_swig import io_signature, io_signaturev
-from .runtime_swig import block_gw_message_type
-from .runtime_swig import block_gateway
########################################################################
# Magic to turn pointers into numpy arrays
@@ -25,54 +26,20 @@ from .runtime_swig import block_gateway
def pointer_to_ndarray(addr, dtype, nitems):
class array_like(object):
__array_interface__ = {
- 'data' : (int(addr), False),
- 'typestr' : dtype.base.str,
- 'descr' : dtype.base.descr,
- 'shape' : (nitems,) + dtype.shape,
- 'strides' : None,
- 'version' : 3
+ 'data': (int(addr), False),
+ 'typestr': dtype.base.str,
+ 'descr': dtype.base.descr,
+ 'shape': (nitems,) + dtype.shape,
+ 'strides': None,
+ 'version': 3
}
return numpy.asarray(array_like()).view(dtype.base)
########################################################################
-# Handler that does callbacks from C++
-########################################################################
-class gateway_handler(gr.feval_ll):
-
- #don't put a constructor, it won't work
-
- def init(self, callback):
- self._callback = callback
-
- def eval(self, arg):
- try: self._callback()
- except Exception as ex:
- print("handler caught exception: %s"%ex)
- import traceback; traceback.print_exc()
- raise ex
- return 0
-
-########################################################################
-# Handler that does callbacks from C++
+# io_signature for Python
########################################################################
-class msg_handler(gr.feval_p):
-
- #don't put a constructor, it won't work
-
- def init(self, callback):
- self._callback = callback
- def eval(self, arg):
- try: self._callback(arg)
- except Exception as ex:
- print("handler caught exception: %s"%ex)
- import traceback; traceback.print_exc()
- raise ex
- return 0
-########################################################################
-# io_signature for Python
-########################################################################
class py_io_signature(object):
"""
Describes the type/number of ports for block input or output.
@@ -94,15 +61,15 @@ class py_io_signature(object):
"""
self.__min_ports = min_ports
self.__max_ports = max_ports
- self.__types = tuple( numpy.dtype(t) for t in type_list )
+ self.__types = tuple(numpy.dtype(t) for t in type_list)
def gr_io_signature(self):
"""
Make/return a gr.io_signature. A non-empty list of sizes is
required, even if there are no ports.
"""
- return io_signaturev(self.__min_ports, self.__max_ports,
- [t.itemsize for t in self.__types] or [0])
+ return io_signature.makev(self.__min_ports, self.__max_ports,
+ [t.itemsize for t in self.__types] or [0])
def port_types(self, nports):
"""
@@ -129,14 +96,19 @@ class py_io_signature(object):
########################################################################
# The guts that make this into a gr block
########################################################################
+
+
class gateway_block(object):
- def __init__(self, name, in_sig, out_sig, work_type, factor):
+ def __init__(self, name, in_sig, out_sig, block_type):
+ self._decim = 1
+ self._interp = 1
+ self._block_type = block_type
# Normalize the many Python ways of saying 'nothing' to '()'
in_sig = in_sig or ()
out_sig = out_sig or ()
-
+
# Backward compatibility: array of type strings -> py_io_signature
if type(in_sig) is py_io_signature:
self.__in_sig = in_sig
@@ -145,98 +117,93 @@ class gateway_block(object):
if type(out_sig) is py_io_signature:
self.__out_sig = out_sig
else:
- self.__out_sig = py_io_signature(len(out_sig), len(out_sig), out_sig)
-
- #create internal gateway block
- self.__handler = gateway_handler()
- self.__handler.init(self.__gr_block_handle)
- self.__gateway = block_gateway(
- self.__handler, name,
- self.__in_sig.gr_io_signature(), self.__out_sig.gr_io_signature(),
- work_type, factor)
- self.__message = self.__gateway.block_message()
-
- #dict to keep references to all message handlers
- self.__msg_handlers = {}
-
- #register block functions
- prefix = 'block__'
- for attr in [x for x in dir(self.__gateway) if x.startswith(prefix)]:
- setattr(self, attr.replace(prefix, ''), getattr(self.__gateway, attr))
- self.pop_msg_queue = lambda: gr.block_gw_pop_msg_queue_safe(self.__gateway)
+ self.__out_sig = py_io_signature(
+ len(out_sig), len(out_sig), out_sig)
+
+ self.gateway = block_gateway(
+ self, name, self.__in_sig.gr_io_signature(), self.__out_sig.gr_io_signature())
+
+ self.msg_handlers = {}
+
+ def __getattr__(self, name):
+ """
+ Pass-through member requests to the C++ object.
+ """
+ if not hasattr(self, "gateway"):
+ raise RuntimeError(
+ "{0}: invalid state -- did you forget to call {0}.__init__ in "
+ "a derived class?".format(self.__class__.__name__))
+ return getattr(self.gateway, name)
def to_basic_block(self):
"""
Makes this block connectable by hier/top block python
"""
- return self.__gateway.to_basic_block()
+ return self.gateway.to_basic_block()
+
+ def fixed_rate_noutput_to_ninput(self, noutput_items):
+ return int((noutput_items * self._decim / self._interp) + self.gateway.history() - 1)
- def __gr_block_handle(self):
+ def handle_forecast(self, noutput_items, ninputs):
"""
- Dispatch tasks according to the action type specified in the message.
+ This is the handler function for forecast calls from
+ block_gateway in c++ across pybind11 wrappers
"""
+ return self.forecast(noutput_items, ninputs)
+
+ # return ninput_items_required
- if self.__message.action == gr.block_gw_message_type.ACTION_GENERAL_WORK:
- # Actual number of inputs/output from scheduler
- ninputs = len(self.__message.general_work_args_input_items)
- noutputs = len(self.__message.general_work_args_output_items)
- in_types = self.__in_sig.port_types(ninputs)
- out_types = self.__out_sig.port_types(noutputs)
- self.__message.general_work_args_return_value = self.general_work(
-
- input_items=[pointer_to_ndarray(
- self.__message.general_work_args_input_items[i],
- in_types[i],
- self.__message.general_work_args_ninput_items[i]
- ) for i in range(ninputs)],
-
- output_items=[pointer_to_ndarray(
- self.__message.general_work_args_output_items[i],
- out_types[i],
- self.__message.general_work_args_noutput_items
- ) for i in range(noutputs)],
- )
-
- elif self.__message.action == gr.block_gw_message_type.ACTION_WORK:
- # Actual number of inputs/output from scheduler
- ninputs = len(self.__message.work_args_input_items)
- noutputs = len(self.__message.work_args_output_items)
- in_types = self.__in_sig.port_types(ninputs)
- out_types = self.__out_sig.port_types(noutputs)
- self.__message.work_args_return_value = self.work(
-
- input_items=[pointer_to_ndarray(
- self.__message.work_args_input_items[i],
- in_types[i],
- self.__message.work_args_ninput_items
- ) for i in range(ninputs)],
-
- output_items=[pointer_to_ndarray(
- self.__message.work_args_output_items[i],
- out_types[i],
- self.__message.work_args_noutput_items
- ) for i in range(noutputs)],
- )
-
- elif self.__message.action == gr.block_gw_message_type.ACTION_FORECAST:
- self.forecast(
- noutput_items=self.__message.forecast_args_noutput_items,
- ninput_items_required=self.__message.forecast_args_ninput_items_required,
- )
-
- elif self.__message.action == gr.block_gw_message_type.ACTION_START:
- self.__message.start_args_return_value = self.start()
-
- elif self.__message.action == gr.block_gw_message_type.ACTION_STOP:
- self.__message.stop_args_return_value = self.stop()
-
- def forecast(self, noutput_items, ninput_items_required):
+ def forecast(self, noutput_items, ninputs):
"""
forecast is only called from a general block
this is the default implementation
"""
- for i in range(len(ninput_items_required)):
- ninput_items_required[i] = noutput_items + self.history() - 1
+ ninput_items_required = [0]*ninputs
+ for i in range(ninputs):
+ ninput_items_required[i] = noutput_items + self.gateway.history() - 1
+
+ return ninput_items_required
+
+ def handle_general_work(self, noutput_items,
+ ninput_items,
+ input_items,
+ output_items):
+
+ ninputs = len(input_items)
+ noutputs = len(output_items)
+ in_types = self.in_sig().port_types(ninputs)
+ out_types = self.out_sig().port_types(noutputs)
+
+
+ ctypes.pythonapi.PyCapsule_GetPointer.restype = ctypes.c_void_p
+ ctypes.pythonapi.PyCapsule_GetPointer.argtypes = [ctypes.py_object, ctypes.c_char_p]
+
+ if self._block_type != gr.GW_BLOCK_GENERAL:
+ ii=[pointer_to_ndarray(
+ ctypes.pythonapi.PyCapsule_GetPointer(input_items[i],None),
+ in_types[i],
+ self.fixed_rate_noutput_to_ninput(noutput_items)
+ ) for i in range(ninputs)]
+ else:
+ ii=[pointer_to_ndarray(
+ ctypes.pythonapi.PyCapsule_GetPointer(input_items[i],None),
+ in_types[i],
+ ninput_items[i]
+ ) for i in range(ninputs)]
+
+ oo=[pointer_to_ndarray(
+ ctypes.pythonapi.PyCapsule_GetPointer(output_items[i],None),
+ out_types[i],
+ noutput_items
+ ) for i in range(noutputs)]
+
+ if self._block_type != gr.GW_BLOCK_GENERAL:
+ r = self.work(ii,oo)
+ self.consume_items(r)
+ else:
+ r = self.general_work(ii,oo)
+
+ return r
def general_work(self, *args, **kwargs):
"""general work to be overloaded in a derived class"""
@@ -252,25 +219,43 @@ class gateway_block(object):
def stop(self):
return True
- def set_msg_handler(self, which_port, handler_func):
- handler = msg_handler()
- handler.init(handler_func)
- self.__gateway.set_msg_handler_feval(which_port, handler)
- # Save handler object in class so it's not garbage collected
- self.__msg_handlers[which_port] = handler
-
def in_sig(self):
return self.__in_sig
def out_sig(self):
return self.__out_sig
+ def set_msg_handler(self, which_port, handler_function):
+ self.gateway.set_msg_handler_pybind(which_port, handler_function.__name__)
+ # Save handler object in class so it's not garbage collected
+ self.msg_handlers[which_port] = handler_function
+
+ # TODO: Make gateway_block have an is-a instead of has-a relationship
+ # That way we don't have to wrap all these functions
+
+ # def message_port_register_in(self, port_id):
+ # return self.gateway.message_port_register_in(port_id)
+
+ # def message_port_register_out(self, port_id):
+ # return self.gateway.message_port_register_out(port_id)
+
+ # def consume_each(self, how_many_items):
+ # return self.gateway.consume_each( how_many_items)
+
+ # def consume(self, which_input, how_many_items):
+ # return self.gateway.consume(which_input, how_many_items)
+
+ # def produce(self, which_output, how_many_items):
+ # return self.gateway.produce(which_output, how_many_items)
+
+
########################################################################
# Wrappers for the user to inherit from
########################################################################
-class basic_block(gateway_block):
- """Args:
+class basic_block(gateway_block):
+ """
+ Args:
name (str): block name
in_sig (gr.py_io_signature): input port signature
@@ -279,18 +264,19 @@ class basic_block(gateway_block):
For backward compatibility, a sequence of numpy type names is also
accepted as an io signature.
-
"""
def __init__(self, name, in_sig, out_sig):
gateway_block.__init__(self,
- name=name,
- in_sig=in_sig,
- out_sig=out_sig,
- work_type=gr.GR_BLOCK_GW_WORK_GENERAL,
- factor=1, #not relevant factor
- )
-
-class sync_block(gateway_block):
+ name=name,
+ in_sig=in_sig,
+ out_sig=out_sig,
+ block_type=gr.GW_BLOCK_GENERAL
+ )
+
+ def consume_items(self, nitems ):
+ pass
+
+class sync_block(gateway_block):
"""
Args:
name (str): block name
@@ -304,12 +290,18 @@ class sync_block(gateway_block):
"""
def __init__(self, name, in_sig, out_sig):
gateway_block.__init__(self,
- name=name,
- in_sig=in_sig,
- out_sig=out_sig,
- work_type=gr.GR_BLOCK_GW_WORK_SYNC,
- factor=1,
- )
+ name=name,
+ in_sig=in_sig,
+ out_sig=out_sig,
+ block_type=gr.GW_BLOCK_SYNC
+ )
+ self._decim = 1
+ self._interp = 1
+
+ def consume_items(self, nitems ):
+ if (nitems > 0):
+ self.gateway.consume_each(nitems)
+
class decim_block(gateway_block):
"""
@@ -325,12 +317,24 @@ class decim_block(gateway_block):
"""
def __init__(self, name, in_sig, out_sig, decim):
gateway_block.__init__(self,
- name=name,
- in_sig=in_sig,
- out_sig=out_sig,
- work_type=gr.GR_BLOCK_GW_WORK_DECIM,
- factor=decim,
- )
+ name=name,
+ in_sig=in_sig,
+ out_sig=out_sig,
+ block_type=gr.GW_BLOCK_DECIM
+ )
+ self._decim = decim
+ self._interp = 1
+ self.gateway.set_relative_rate(self._interp, self._decim)
+ self.gateway.set_output_multiple(self._interp)
+
+ def consume_items(self, nitems ):
+ if (nitems > 0):
+ self.gateway.consume_each(int(nitems * self._decim))
+
+ def forecast(self, noutput_items, ninputs):
+ return [self.fixed_rate_noutput_to_ninput(noutput_items) for ii in range(ninputs)]
+
+
class interp_block(gateway_block):
"""
@@ -346,9 +350,22 @@ class interp_block(gateway_block):
"""
def __init__(self, name, in_sig, out_sig, interp):
gateway_block.__init__(self,
- name=name,
- in_sig=in_sig,
- out_sig=out_sig,
- work_type=gr.GR_BLOCK_GW_WORK_INTERP,
- factor=interp,
- )
+ name=name,
+ in_sig=in_sig,
+ out_sig=out_sig,
+ block_type=gr.GW_BLOCK_DECIM
+ )
+ self._decim = 1
+ self._interp = interp
+ self.gateway.set_relative_rate(self._interp, self._decim)
+ self.gateway.set_output_multiple(self._interp)
+
+
+ def consume_items(self, nitems ):
+ if (nitems > 0):
+ self.gateway.consume_each(int(nitems / self._interp))
+
+ def forecast(self, noutput_items, ninputs):
+ # print("{},{},{}".format(noutput_items, ninputs, [self.fixed_rate_noutput_to_ninput(noutput_items) for ii in range(ninputs)]))
+
+ return [self.fixed_rate_noutput_to_ninput(noutput_items) for ii in range(ninputs)]
diff --git a/gnuradio-runtime/python/gnuradio/gr/hier_block2.py b/gnuradio-runtime/python/gnuradio/gr/hier_block2.py
index 60b7fdb5ac..ead607ba8a 100644
--- a/gnuradio-runtime/python/gnuradio/gr/hier_block2.py
+++ b/gnuradio-runtime/python/gnuradio/gr/hier_block2.py
@@ -10,7 +10,9 @@ from __future__ import unicode_literals
import functools
-from .runtime_swig import hier_block2_swig, dot_graph
+# from .runtime_swig import hier_block2_swig, dot_graph
+from .gr_python import hier_block2_pb
+
import pmt
@@ -68,7 +70,7 @@ class hier_block2(object):
"""
Create a hierarchical block with a given name and I/O signatures.
"""
- self._impl = hier_block2_swig(name, input_signature, output_signature)
+ self._impl = hier_block2_pb(name, input_signature, output_signature)
def __getattr__(self, name):
"""
@@ -140,8 +142,8 @@ class hier_block2(object):
"""
self.primitive_message_port_register_hier_out(pmt.intern(portname))
- def dot_graph(self):
- """
- Return graph representation in dot language
- """
- return dot_graph(self._impl)
+ # def dot_graph(self):
+ # """
+ # Return graph representation in dot language
+ # """
+ # return dot_graph(self._impl)
diff --git a/gnuradio-runtime/python/gnuradio/gr/qa_feval.py b/gnuradio-runtime/python/gnuradio/gr/qa_feval.py
deleted file mode 100644
index 7018fd9f1a..0000000000
--- a/gnuradio-runtime/python/gnuradio/gr/qa_feval.py
+++ /dev/null
@@ -1,99 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright 2006,2007,2010 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# SPDX-License-Identifier: GPL-3.0-or-later
-#
-#
-
-
-from gnuradio import gr, gr_unittest
-
-class my_add2_dd(gr.feval_dd):
- def eval(self, x):
- return x + 2
-
-class my_add2_ll(gr.feval_ll):
- def eval(self, x):
- return x + 2
-
-class my_add2_cc(gr.feval_cc):
- def eval(self, x):
- return x + (2 - 2j)
-
-class my_feval(gr.feval):
- def __init__(self):
- gr.feval.__init__(self)
- self.fired = False
- def eval(self):
- self.fired = True
-
-class test_feval(gr_unittest.TestCase):
-
- def test_dd_1(self):
- f = my_add2_dd()
- src_data = (0.0, 1.0, 2.0, 3.0, 4.0)
- expected_result = (2.0, 3.0, 4.0, 5.0, 6.0)
- # this is all in python...
- actual_result = tuple([f.eval(x) for x in src_data])
- self.assertEqual(expected_result, actual_result)
-
- def test_dd_2(self):
- f = my_add2_dd()
- src_data = (0.0, 1.0, 2.0, 3.0, 4.0)
- expected_result = (2.0, 3.0, 4.0, 5.0, 6.0)
- # this is python -> C++ -> python and back again...
- actual_result = tuple([gr.feval_dd_example(f, x) for x in src_data])
- self.assertEqual(expected_result, actual_result)
-
-
- def test_ll_1(self):
- f = my_add2_ll()
- src_data = (0, 1, 2, 3, 4)
- expected_result = (2, 3, 4, 5, 6)
- # this is all in python...
- actual_result = tuple([f.eval(x) for x in src_data])
- self.assertEqual(expected_result, actual_result)
-
- def test_ll_2(self):
- f = my_add2_ll()
- src_data = (0, 1, 2, 3, 4)
- expected_result = (2, 3, 4, 5, 6)
- # this is python -> C++ -> python and back again...
- actual_result = tuple([gr.feval_ll_example(f, x) for x in src_data])
- self.assertEqual(expected_result, actual_result)
-
-
- def test_cc_1(self):
- f = my_add2_cc()
- src_data = (0+1j, 2+3j, 4+5j, 6+7j)
- expected_result = (2-1j, 4+1j, 6+3j, 8+5j)
- # this is all in python...
- actual_result = tuple([f.eval(x) for x in src_data])
- self.assertEqual(expected_result, actual_result)
-
- def test_cc_2(self):
- f = my_add2_cc()
- src_data = (0+1j, 2+3j, 4+5j, 6+7j)
- expected_result = (2-1j, 4+1j, 6+3j, 8+5j)
- # this is python -> C++ -> python and back again...
- actual_result = tuple([gr.feval_cc_example(f, x) for x in src_data])
- self.assertEqual(expected_result, actual_result)
-
- def test_void_1(self):
- # this is all in python
- f = my_feval()
- f.eval()
- self.assertEqual(True, f.fired)
-
- def test_void_2(self):
- # this is python -> C++ -> python and back again
- f = my_feval()
- gr.feval_example(f)
- self.assertEqual(True, f.fired)
-
-
-if __name__ == '__main__':
- gr_unittest.run(test_feval, "test_feval.xml")
diff --git a/gnuradio-runtime/python/gnuradio/gr/qa_flowgraph.py b/gnuradio-runtime/python/gnuradio/gr/qa_flowgraph.py
index e5767e05d8..c92bea241e 100644
--- a/gnuradio-runtime/python/gnuradio/gr/qa_flowgraph.py
+++ b/gnuradio-runtime/python/gnuradio/gr/qa_flowgraph.py
@@ -40,7 +40,7 @@ class test_flowgraph (gr_unittest.TestCase):
self.assertEqual(dbg.num_messages(), 1)
data = pmt.u8vector_elements(pmt.cdr(dbg.get_message(0)))
- self.assertEqual((1, 2, 3), data)
+ self.assertEqual([1, 2, 3], data)
if __name__ == '__main__':
gr_unittest.run(test_flowgraph, 'test_flowgraph.xml')
diff --git a/gnuradio-runtime/python/gnuradio/gr/tag_utils.py b/gnuradio-runtime/python/gnuradio/gr/tag_utils.py
index cdb3350ed0..26fd62b864 100644
--- a/gnuradio-runtime/python/gnuradio/gr/tag_utils.py
+++ b/gnuradio-runtime/python/gnuradio/gr/tag_utils.py
@@ -1,7 +1,7 @@
from __future__ import unicode_literals
import pmt
-from . import runtime_swig as gr
+from . import gr_python as gr
class PythonTag(object):
" Python container for tags "
@@ -58,17 +58,17 @@ def python_to_tag(tag_struct):
good = True
if('key' in tag_struct):
- if(isinstance(tag_struct['key'], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct['key'], pmt.pmt_base)):
tag.key = tag_struct['key']
good = True
if('value' in tag_struct):
- if(isinstance(tag_struct['value'], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct['value'], pmt.pmt_base)):
tag.value = tag_struct['value']
good = True
if('srcid' in tag_struct):
- if(isinstance(tag_struct['srcid'], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct['srcid'], pmt.pmt_base)):
tag.srcid = tag_struct['srcid']
good = True
@@ -78,15 +78,15 @@ def python_to_tag(tag_struct):
tag.offset = tag_struct[0]
good = True
- if(isinstance(tag_struct[1], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct[1], pmt.pmt_base)):
tag.key = tag_struct[1]
good = True
- if(isinstance(tag_struct[2], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct[2], pmt.pmt_base)):
tag.value = tag_struct[2]
good = True
- if(isinstance(tag_struct[3], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct[3], pmt.pmt_base)):
tag.srcid = tag_struct[3]
good = True
@@ -95,11 +95,11 @@ def python_to_tag(tag_struct):
tag.offset = tag_struct[0]
good = True
- if(isinstance(tag_struct[1], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct[1], pmt.pmt_base)):
tag.key = tag_struct[1]
good = True
- if(isinstance(tag_struct[2], pmt.swig_pmt_ptr)):
+ if(isinstance(tag_struct[2], pmt.pmt_base)):
tag.value = tag_struct[2]
good = True
@@ -112,33 +112,33 @@ def python_to_tag(tag_struct):
def tag_t_offset_compare_key():
"""
- Convert a tag_t_offset_compare function into a key=function
+ Convert a tag_t.offset_compare function into a key=function
This method is modeled after functools.cmp_to_key(_func_).
It can be used by functions that accept a key function, such as
sorted(), min(), max(), etc. to compare tags by their offsets,
- e.g., sorted(tag_list, key=gr.tag_t_offset_compare_key()).
+ e.g., sorted(tag_list, key=gr.tag_t.offset_compare_key()).
"""
class K(object):
def __init__(self, obj, *args):
self.obj = obj
def __lt__(self, other):
# x.offset < y.offset
- return gr.tag_t_offset_compare(self.obj, other.obj)
+ return gr.tag_t.offset_compare(self.obj, other.obj)
def __gt__(self, other):
# y.offset < x.offset
- return gr.tag_t_offset_compare(other.obj, self.obj)
+ return gr.tag_t.offset_compare(other.obj, self.obj)
def __eq__(self, other):
# not (x.offset < y.offset) and not (y.offset < x.offset)
- return not gr.tag_t_offset_compare(self.obj, other.obj) and \
- not gr.tag_t_offset_compare(other.obj, self.obj)
+ return not gr.tag_t.offset_compare(self.obj, other.obj) and \
+ not gr.tag_t.offset_compare(other.obj, self.obj)
def __le__(self, other):
# not (y.offset < x.offset)
- return not gr.tag_t_offset_compare(other.obj, self.obj)
+ return not gr.tag_t.offset_compare(other.obj, self.obj)
def __ge__(self, other):
# not (x.offset < y.offset)
- return not gr.tag_t_offset_compare(self.obj, other.obj)
+ return not gr.tag_t.offset_compare(self.obj, other.obj)
def __ne__(self, other):
# (x.offset < y.offset) or (y.offset < x.offset)
- return gr.tag_t_offset_compare(self.obj, other.obj) or \
- gr.tag_t_offset_compare(other.obj, self.obj)
+ return gr.tag_t.offset_compare(self.obj, other.obj) or \
+ gr.tag_t.offset_compare(other.obj, self.obj)
return K
diff --git a/gnuradio-runtime/python/gnuradio/gr/top_block.py b/gnuradio-runtime/python/gnuradio/gr/top_block.py
index e8a18b2d07..9523e4e91d 100644
--- a/gnuradio-runtime/python/gnuradio/gr/top_block.py
+++ b/gnuradio-runtime/python/gnuradio/gr/top_block.py
@@ -10,11 +10,12 @@
from __future__ import absolute_import
from __future__ import unicode_literals
-from .runtime_swig import (top_block_swig,
+from .gr_python import (top_block_pb,
top_block_wait_unlocked, top_block_run_unlocked,
top_block_start_unlocked, top_block_stop_unlocked,
- top_block_unlock_unlocked, dot_graph_tb)
+ top_block_unlock_unlocked) #, dot_graph_tb)
+from .hier_block2 import hier_block2
import threading
from .hier_block2 import hier_block2
@@ -89,7 +90,7 @@ class top_block(hier_block2):
Create a top block with a given name.
"""
# not calling hier_block2.__init__, we set our own _impl
- self._impl = top_block_swig(name, catch_exceptions)
+ self._impl = top_block_pb(name)
self.handle_sigint = True
def start(self, max_noutput_items=10000000):
@@ -123,8 +124,8 @@ class top_block(hier_block2):
"""
_top_block_waiter(self._impl).wait(self.handle_sigint)
- def dot_graph(self):
- """
- Return graph representation in dot language
- """
- return dot_graph_tb(self._impl)
+ # def dot_graph(self):
+ # """
+ # Return graph representation in dot language
+ # """
+ # return dot_graph_tb(self._impl)
diff --git a/gnuradio-runtime/python/pmt/CMakeLists.txt b/gnuradio-runtime/python/pmt/CMakeLists.txt
index cbbce43df0..3dcec8246b 100644
--- a/gnuradio-runtime/python/pmt/CMakeLists.txt
+++ b/gnuradio-runtime/python/pmt/CMakeLists.txt
@@ -26,10 +26,10 @@ foreach(py_qa_test_file ${py_qa_test_files})
get_filename_component(py_qa_test_name ${py_qa_test_file} NAME_WE)
set(GR_TEST_PYTHON_DIRS
${CMAKE_BINARY_DIR}/gnuradio-runtime/python
- ${CMAKE_BINARY_DIR}/gnuradio-runtime/swig
- ${CMAKE_BINARY_DIR}/gnuradio-blocks/swig
)
set(GR_TEST_TARGET_DEPS gnuradio-runtime)
GR_ADD_TEST(${py_qa_test_name} ${QA_PYTHON_EXECUTABLE} -B ${py_qa_test_file})
endforeach(py_qa_test_file)
endif(ENABLE_TESTING)
+
+add_subdirectory(bindings)
diff --git a/gnuradio-runtime/python/pmt/__init__.py b/gnuradio-runtime/python/pmt/__init__.py
index 05046f05d9..9b3b6f5410 100644
--- a/gnuradio-runtime/python/pmt/__init__.py
+++ b/gnuradio-runtime/python/pmt/__init__.py
@@ -33,11 +33,11 @@ from __future__ import unicode_literals
import os
try:
- from .pmt_swig import *
+ from .pmt_python import *
except ImportError:
dirname, filename = os.path.split(os.path.abspath(__file__))
- __path__.append(os.path.join(dirname, "..", "..", "swig"))
- from .pmt_swig import *
+ __path__.append(os.path.join(dirname, "bindings"))
+ from .pmt_python import *
# due to changes in the PMT_NIL singleton for static builds, we force
# this into Python here.
diff --git a/gnuradio-runtime/python/pmt/bindings/CMakeLists.txt b/gnuradio-runtime/python/pmt/bindings/CMakeLists.txt
new file mode 100644
index 0000000000..267d451d0b
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/CMakeLists.txt
@@ -0,0 +1,18 @@
+include(GrPybind)
+
+########################################################################
+# Python Bindings
+########################################################################
+list(APPEND pmt_python_files
+ pmt_python.cc
+ pmt_pool_python.cc
+ pmt_sugar_python.cc
+ python_bindings.cc
+)
+
+GR_PYBIND_MAKE(pmt
+ ../../..
+ pmt
+ "${pmt_python_files}")
+
+install(TARGETS pmt_python DESTINATION ${GR_PYTHON_DIR}/pmt COMPONENT pythonapi)
diff --git a/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pool_pydoc_template.h b/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pool_pydoc_template.h
new file mode 100644
index 0000000000..19c7fd4788
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pool_pydoc_template.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(pmt, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_pmt_pmt_pool = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_pool_pmt_pool = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_pool_malloc = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_pool_free = R"doc()doc";
diff --git a/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pydoc_template.h b/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pydoc_template.h
new file mode 100644
index 0000000000..6af2f9e0af
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_pydoc_template.h
@@ -0,0 +1,882 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(pmt, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_pmt_pmt_base = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_pmt_base = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_bool = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_symbol = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_number = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_integer = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_uint64 = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_real = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_complex = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_null = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_pair = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_tuple = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_dict = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_any = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_uniform_vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_u8vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_s8vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_u16vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_s16vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_u32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_s32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_u64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_s64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_f32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_f64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_c32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_base_is_c64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_exception = R"doc()doc";
+
+
+static const char* __doc_pmt_exception_exception_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_exception_exception_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_wrong_type = R"doc()doc";
+
+
+static const char* __doc_pmt_wrong_type_wrong_type_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_wrong_type_wrong_type_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_out_of_range = R"doc()doc";
+
+
+static const char* __doc_pmt_out_of_range_out_of_range_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_out_of_range_out_of_range_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_notimplemented = R"doc()doc";
+
+
+static const char* __doc_pmt_notimplemented_notimplemented_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_notimplemented_notimplemented_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_comparator = R"doc()doc";
+
+
+static const char* __doc_pmt_comparator_comparator_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_comparator_comparator_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_get_PMT_NIL = R"doc()doc";
+
+
+static const char* __doc_pmt_get_PMT_T = R"doc()doc";
+
+
+static const char* __doc_pmt_get_PMT_F = R"doc()doc";
+
+
+static const char* __doc_pmt_get_PMT_EOF = R"doc()doc";
+
+
+static const char* __doc_pmt_is_bool = R"doc()doc";
+
+
+static const char* __doc_pmt_is_true = R"doc()doc";
+
+
+static const char* __doc_pmt_is_false = R"doc()doc";
+
+
+static const char* __doc_pmt_from_bool = R"doc()doc";
+
+
+static const char* __doc_pmt_to_bool = R"doc()doc";
+
+
+static const char* __doc_pmt_is_symbol = R"doc()doc";
+
+
+static const char* __doc_pmt_string_to_symbol = R"doc()doc";
+
+
+static const char* __doc_pmt_intern = R"doc()doc";
+
+
+static const char* __doc_pmt_symbol_to_string = R"doc()doc";
+
+
+static const char* __doc_pmt_is_number = R"doc()doc";
+
+
+static const char* __doc_pmt_is_integer = R"doc()doc";
+
+
+static const char* __doc_pmt_from_long = R"doc()doc";
+
+
+static const char* __doc_pmt_to_long = R"doc()doc";
+
+
+static const char* __doc_pmt_is_uint64 = R"doc()doc";
+
+
+static const char* __doc_pmt_from_uint64 = R"doc()doc";
+
+
+static const char* __doc_pmt_to_uint64 = R"doc()doc";
+
+
+static const char* __doc_pmt_is_real = R"doc()doc";
+
+
+static const char* __doc_pmt_from_double = R"doc()doc";
+
+
+static const char* __doc_pmt_from_float = R"doc()doc";
+
+
+static const char* __doc_pmt_to_double = R"doc()doc";
+
+
+static const char* __doc_pmt_to_float = R"doc()doc";
+
+
+static const char* __doc_pmt_is_complex = R"doc()doc";
+
+
+static const char* __doc_pmt_make_rectangular = R"doc()doc";
+
+
+static const char* __doc_pmt_from_complex_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_from_complex_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_from_complex_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_from_complex_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_to_complex = R"doc()doc";
+
+
+static const char* __doc_pmt_is_null = R"doc()doc";
+
+
+static const char* __doc_pmt_is_pair = R"doc()doc";
+
+
+static const char* __doc_pmt_cons = R"doc()doc";
+
+
+static const char* __doc_pmt_dcons = R"doc()doc";
+
+
+static const char* __doc_pmt_car = R"doc()doc";
+
+
+static const char* __doc_pmt_cdr = R"doc()doc";
+
+
+static const char* __doc_pmt_set_car = R"doc()doc";
+
+
+static const char* __doc_pmt_set_cdr = R"doc()doc";
+
+
+static const char* __doc_pmt_caar = R"doc()doc";
+
+
+static const char* __doc_pmt_cadr = R"doc()doc";
+
+
+static const char* __doc_pmt_cdar = R"doc()doc";
+
+
+static const char* __doc_pmt_cddr = R"doc()doc";
+
+
+static const char* __doc_pmt_caddr = R"doc()doc";
+
+
+static const char* __doc_pmt_cadddr = R"doc()doc";
+
+
+static const char* __doc_pmt_is_tuple = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_2 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_3 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_4 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_5 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_6 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_7 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_8 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_9 = R"doc()doc";
+
+
+static const char* __doc_pmt_make_tuple_10 = R"doc()doc";
+
+
+static const char* __doc_pmt_to_tuple = R"doc()doc";
+
+
+static const char* __doc_pmt_tuple_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_is_vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_vector = R"doc()doc";
+
+
+static const char* __doc_pmt_vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_vector_fill = R"doc()doc";
+
+
+static const char* __doc_pmt_is_blob = R"doc()doc";
+
+
+static const char* __doc_pmt_make_blob = R"doc()doc";
+
+
+static const char* __doc_pmt_blob_data = R"doc()doc";
+
+
+static const char* __doc_pmt_blob_length = R"doc()doc";
+
+
+static const char* __doc_pmt_is_uniform_vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_u8vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_s8vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_u16vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_s16vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_u32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_s32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_u64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_s64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_f32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_f64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_c32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_is_c64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_uniform_vector_itemsize = R"doc()doc";
+
+
+static const char* __doc_pmt_make_u8vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_s8vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_u16vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_s16vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_u32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_s32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_u64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_s64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_f32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_f64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_c32vector = R"doc()doc";
+
+
+static const char* __doc_pmt_make_c64vector = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u8vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u8vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s8vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s8vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u16vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u16vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s16vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s16vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u32vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u32vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s32vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s32vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u64vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_u64vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s64vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_s64vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_f32vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_f32vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_f64vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_f64vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_c32vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_c32vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_c64vector_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_init_c64vector_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_u8vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_s8vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_u16vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_s16vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_u32vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_s32vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_u64vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_s64vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_f32vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_f64vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_c32vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_c64vector_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_u8vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_s8vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_u16vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_s16vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_u32vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_s32vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_u64vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_s64vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_f32vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_f64vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_c32vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_c64vector_set = R"doc()doc";
+
+
+static const char* __doc_pmt_uniform_vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_u8vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_s8vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_u16vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_s16vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_u32vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_s32vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_u64vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_s64vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_f32vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_f64vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_c32vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_c64vector_elements_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_u8vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_s8vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_u16vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_s16vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_u32vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_s32vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_u64vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_s64vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_f32vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_f64vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_c32vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_c64vector_elements_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_u8vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_s8vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_u16vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_s16vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_u32vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_s32vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_u64vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_s64vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_f32vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_f64vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_c32vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_pmt_c64vector_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_uniform_vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_u8vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_s8vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_u16vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_s16vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_u32vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_s32vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_u64vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_s64vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_f32vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_f64vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_c32vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_c64vector_writable_elements = R"doc()doc";
+
+
+static const char* __doc_pmt_is_dict = R"doc()doc";
+
+
+static const char* __doc_pmt_make_dict = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_add = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_delete = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_has_key = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_items = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_keys = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_update = R"doc()doc";
+
+
+static const char* __doc_pmt_dict_values = R"doc()doc";
+
+
+static const char* __doc_pmt_is_any = R"doc()doc";
+
+
+static const char* __doc_pmt_make_any = R"doc()doc";
+
+
+static const char* __doc_pmt_any_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_any_set = R"doc()doc";
+
+
+static const char* __doc_pmt_is_msg_accepter = R"doc()doc";
+
+
+static const char* __doc_pmt_make_msg_accepter = R"doc()doc";
+
+
+static const char* __doc_pmt_msg_accepter_ref = R"doc()doc";
+
+
+static const char* __doc_pmt_is_pdu = R"doc()doc";
+
+
+static const char* __doc_pmt_eq = R"doc()doc";
+
+
+static const char* __doc_pmt_eqv = R"doc()doc";
+
+
+static const char* __doc_pmt_equal = R"doc()doc";
+
+
+static const char* __doc_pmt_assq = R"doc()doc";
+
+
+static const char* __doc_pmt_assv = R"doc()doc";
+
+
+static const char* __doc_pmt_assoc = R"doc()doc";
+
+
+static const char* __doc_pmt_map = R"doc()doc";
+
+
+static const char* __doc_pmt_reverse = R"doc()doc";
+
+
+static const char* __doc_pmt_reverse_x = R"doc()doc";
+
+
+static const char* __doc_pmt_acons = R"doc()doc";
+
+
+static const char* __doc_pmt_nth = R"doc()doc";
+
+
+static const char* __doc_pmt_nthcdr = R"doc()doc";
+
+
+static const char* __doc_pmt_memq = R"doc()doc";
+
+
+static const char* __doc_pmt_memv = R"doc()doc";
+
+
+static const char* __doc_pmt_member = R"doc()doc";
+
+
+static const char* __doc_pmt_subsetp = R"doc()doc";
+
+
+static const char* __doc_pmt_list1 = R"doc()doc";
+
+
+static const char* __doc_pmt_list2 = R"doc()doc";
+
+
+static const char* __doc_pmt_list3 = R"doc()doc";
+
+
+static const char* __doc_pmt_list4 = R"doc()doc";
+
+
+static const char* __doc_pmt_list5 = R"doc()doc";
+
+
+static const char* __doc_pmt_list6 = R"doc()doc";
+
+
+static const char* __doc_pmt_list_add = R"doc()doc";
+
+
+static const char* __doc_pmt_list_rm = R"doc()doc";
+
+
+static const char* __doc_pmt_list_has = R"doc()doc";
+
+
+static const char* __doc_pmt_is_eof_object = R"doc()doc";
+
+
+static const char* __doc_pmt_read = R"doc()doc";
+
+
+static const char* __doc_pmt_write = R"doc()doc";
+
+
+static const char* __doc_pmt_write_string = R"doc()doc";
+
+
+static const char* __doc_pmt_print = R"doc()doc";
+
+
+static const char* __doc_pmt_serialize = R"doc()doc";
+
+
+static const char* __doc_pmt_deserialize = R"doc()doc";
+
+
+static const char* __doc_pmt_dump_sizeof = R"doc()doc";
+
+
+static const char* __doc_pmt_serialize_str = R"doc()doc";
+
+
+static const char* __doc_pmt_deserialize_str = R"doc()doc";
diff --git a/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_sugar_pydoc_template.h b/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_sugar_pydoc_template.h
new file mode 100644
index 0000000000..2134d6f3e1
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/docstrings/pmt_sugar_pydoc_template.h
@@ -0,0 +1,78 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+#include "pydoc_macros.h"
+#define D(...) DOC(pmt, __VA_ARGS__)
+/*
+ This file contains placeholders for docstrings for the Python bindings.
+ Do not edit! These were automatically extracted during the binding process
+ and will be overwritten during the build process
+ */
+
+
+static const char* __doc_pmt_mp_0 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_1 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_2 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_3 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_4 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_5 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_6 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_7 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_8 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_9 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_10 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_11 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_12 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_13 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_14 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_15 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_16 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_17 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_18 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_19 = R"doc()doc";
+
+
+static const char* __doc_pmt_mp_20 = R"doc()doc";
diff --git a/gnuradio-runtime/python/pmt/bindings/pmt_pool_python.cc b/gnuradio-runtime/python/pmt/bindings/pmt_pool_python.cc
new file mode 100644
index 0000000000..c6c8f71f5f
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/pmt_pool_python.cc
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <pmt/pmt_pool.h>
+// pydoc.h is automatically generated in the build directory
+#include <pmt_pool_pydoc.h>
+
+void bind_pmt_pool(py::module& m)
+{
+
+ using pmt_pool = ::pmt::pmt_pool;
+
+
+ py::class_<pmt_pool, std::shared_ptr<pmt_pool>>(m, "pmt_pool", D(pmt_pool))
+
+ .def(py::init<size_t, size_t, size_t, size_t>(),
+ py::arg("itemsize"),
+ py::arg("alignment") = 16,
+ py::arg("allocation_size") = 4096,
+ py::arg("max_items") = 0,
+ D(pmt_pool, pmt_pool))
+
+
+ .def("malloc", &pmt_pool::malloc, D(pmt_pool, malloc))
+
+
+ .def("free", &pmt_pool::free, py::arg("p"), D(pmt_pool, free));
+}
diff --git a/gnuradio-runtime/python/pmt/bindings/pmt_python.cc b/gnuradio-runtime/python/pmt/bindings/pmt_python.cc
new file mode 100644
index 0000000000..7cb1e530d3
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/pmt_python.cc
@@ -0,0 +1,1558 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <pmt/pmt.h>
+// pydoc.h is automatically generated in the build directory
+#include <pmt_pydoc.h>
+
+void bind_pmt(py::module& m)
+{
+ using pmt_base = pmt::pmt_base;
+ // using exception = pmt::exception;
+ // using wrong_type = pmt::wrong_type;
+ // using out_of_range = pmt::out_of_range;
+ // using notimplemented = pmt::notimplemented;
+ using comparator = pmt::comparator;
+
+ py::class_<pmt_base, std::shared_ptr<pmt_base>>(m, "pmt_base")
+
+ .def(py::init<>(), D(pmt_base, pmt_base))
+ .def("__str__", [](const pmt::pmt_t& p) { return pmt::write_string(p); })
+ .def("is_bool", &pmt_base::is_bool, D(pmt_base, is_bool))
+
+
+ .def("is_symbol", &pmt_base::is_symbol, D(pmt_base, is_symbol))
+
+
+ .def("is_number", &pmt_base::is_number, D(pmt_base, is_number))
+
+
+ .def("is_integer", &pmt_base::is_integer, D(pmt_base, is_integer))
+
+
+ .def("is_uint64", &pmt_base::is_uint64, D(pmt_base, is_uint64))
+
+
+ .def("is_real", &pmt_base::is_real, D(pmt_base, is_real))
+
+
+ .def("is_complex", &pmt_base::is_complex, D(pmt_base, is_complex))
+
+
+ .def("is_null", &pmt_base::is_null, D(pmt_base, is_null))
+
+
+ .def("is_pair", &pmt_base::is_pair, D(pmt_base, is_pair))
+
+
+ .def("is_tuple", &pmt_base::is_tuple, D(pmt_base, is_tuple))
+
+
+ .def("is_vector", &pmt_base::is_vector, D(pmt_base, is_vector))
+
+
+ .def("is_dict", &pmt_base::is_dict, D(pmt_base, is_dict))
+
+
+ .def("is_any", &pmt_base::is_any, D(pmt_base, is_any))
+
+
+ .def("is_uniform_vector",
+ &pmt_base::is_uniform_vector,
+ D(pmt_base, is_uniform_vector))
+
+
+ .def("is_u8vector", &pmt_base::is_u8vector, D(pmt_base, is_u8vector))
+
+
+ .def("is_s8vector", &pmt_base::is_s8vector, D(pmt_base, is_s8vector))
+
+
+ .def("is_u16vector", &pmt_base::is_u16vector, D(pmt_base, is_u16vector))
+
+
+ .def("is_s16vector", &pmt_base::is_s16vector, D(pmt_base, is_s16vector))
+
+
+ .def("is_u32vector", &pmt_base::is_u32vector, D(pmt_base, is_u32vector))
+
+
+ .def("is_s32vector", &pmt_base::is_s32vector, D(pmt_base, is_s32vector))
+
+
+ .def("is_u64vector", &pmt_base::is_u64vector, D(pmt_base, is_u64vector))
+
+
+ .def("is_s64vector", &pmt_base::is_s64vector, D(pmt_base, is_s64vector))
+
+
+ .def("is_f32vector", &pmt_base::is_f32vector, D(pmt_base, is_f32vector))
+
+
+ .def("is_f64vector", &pmt_base::is_f64vector, D(pmt_base, is_f64vector))
+
+
+ .def("is_c32vector", &pmt_base::is_c32vector, D(pmt_base, is_c32vector))
+
+
+ .def("is_c64vector", &pmt_base::is_c64vector, D(pmt_base, is_c64vector))
+
+ ;
+
+
+ // py::class_<exception,std::logic_error,
+ // std::shared_ptr<exception>>(m, "exception")
+
+ // .def(py::init<std::string const &,pmt::pmt_t>(), py::arg("msg"),
+ // py::arg("obj")
+ // )
+ // .def(py::init<pmt::exception const &>(), py::arg("arg0")
+ // )
+
+ // ;
+
+
+ // py::class_<wrong_type,pmt::exception,
+ // std::shared_ptr<wrong_type>>(m, "wrong_type")
+
+ // .def(py::init<std::string const &,pmt::pmt_t>(), py::arg("msg"),
+ // py::arg("obj")
+ // )
+ // .def(py::init<pmt::wrong_type const &>(), py::arg("arg0")
+ // )
+
+ // ;
+
+
+ // py::class_<out_of_range,pmt::exception,
+ // std::shared_ptr<out_of_range>>(m, "out_of_range")
+
+ // .def(py::init<std::string const &,pmt::pmt_t>(), py::arg("msg"),
+ // py::arg("obj")
+ // )
+ // .def(py::init<pmt::out_of_range const &>(), py::arg("arg0")
+ // )
+
+ // ;
+
+
+ // py::class_<notimplemented,pmt::exception,
+ // std::shared_ptr<notimplemented>>(m, "notimplemented")
+
+ // .def(py::init<std::string const &,pmt::pmt_t>(), py::arg("msg"),
+ // py::arg("obj")
+ // )
+ // .def(py::init<pmt::notimplemented const &>(), py::arg("arg0")
+ // )
+
+ // ;
+
+
+ py::class_<comparator, std::shared_ptr<comparator>>(m, "comparator")
+
+ .def(py::init<>())
+ .def(py::init<pmt::comparator const&>(), py::arg("arg0"))
+
+ ;
+
+
+ m.def("get_PMT_NIL", &::pmt::get_PMT_NIL, D(get_PMT_NIL));
+
+
+ m.def("get_PMT_T", &::pmt::get_PMT_T, D(get_PMT_T));
+
+
+ m.def("get_PMT_F", &::pmt::get_PMT_F, D(get_PMT_F));
+
+
+ m.def("get_PMT_EOF", &::pmt::get_PMT_EOF, D(get_PMT_EOF));
+
+
+ m.def("is_bool", &::pmt::is_bool, py::arg("obj"), D(is_bool));
+
+
+ m.def("is_true", &::pmt::is_true, py::arg("obj"), D(is_true));
+
+
+ m.def("is_false", &::pmt::is_false, py::arg("obj"), D(is_false));
+
+
+ m.def("from_bool", &::pmt::from_bool, py::arg("val"), D(from_bool));
+
+
+ m.def("to_bool", &::pmt::to_bool, py::arg("val"), D(to_bool));
+
+
+ m.def("is_symbol", &::pmt::is_symbol, py::arg("obj"), D(is_symbol));
+
+
+ m.def(
+ "string_to_symbol", &::pmt::string_to_symbol, py::arg("s"), D(string_to_symbol));
+
+
+ m.def("intern", &::pmt::intern, py::arg("s"), D(intern));
+
+
+ m.def("symbol_to_string",
+ &::pmt::symbol_to_string,
+ py::arg("sym"),
+ D(symbol_to_string));
+
+
+ m.def("is_number", &::pmt::is_number, py::arg("obj"), D(is_number));
+
+
+ m.def("is_integer", &::pmt::is_integer, py::arg("x"), D(is_integer));
+
+
+ m.def("from_long", &::pmt::from_long, py::arg("x"), D(from_long));
+
+
+ m.def("to_long", &::pmt::to_long, py::arg("x"), D(to_long));
+
+
+ m.def("is_uint64", &::pmt::is_uint64, py::arg("x"), D(is_uint64));
+
+
+ m.def("from_uint64", &::pmt::from_uint64, py::arg("x"), D(from_uint64));
+
+
+ m.def("to_uint64", &::pmt::to_uint64, py::arg("x"), D(to_uint64));
+
+
+ m.def("is_real", &::pmt::is_real, py::arg("obj"), D(is_real));
+
+
+ m.def("from_double", &::pmt::from_double, py::arg("x"), D(from_double));
+
+
+ m.def("from_float", &::pmt::from_float, py::arg("x"), D(from_float));
+
+
+ m.def("to_double", &::pmt::to_double, py::arg("x"), D(to_double));
+
+
+ m.def("to_float", &::pmt::to_float, py::arg("x"), D(to_float));
+
+
+ m.def("is_complex", &::pmt::is_complex, py::arg("obj"), D(is_complex));
+
+
+ m.def("make_rectangular",
+ &::pmt::make_rectangular,
+ py::arg("re"),
+ py::arg("im"),
+ D(make_rectangular));
+
+
+ m.def("from_complex",
+ (pmt::pmt_t(*)(double, double)) & ::pmt::from_complex,
+ py::arg("re"),
+ py::arg("im"),
+ D(from_complex, 0));
+
+
+ m.def("from_complex",
+ (pmt::pmt_t(*)(std::complex<double> const&)) & ::pmt::from_complex,
+ py::arg("z"),
+ D(from_complex, 1));
+
+
+ m.def("pmt_from_complex",
+ (pmt::pmt_t(*)(double, double)) & ::pmt::pmt_from_complex,
+ py::arg("re"),
+ py::arg("im"),
+ D(pmt_from_complex, 0));
+
+
+ m.def("pmt_from_complex",
+ (pmt::pmt_t(*)(std::complex<double> const&)) & ::pmt::pmt_from_complex,
+ py::arg("z"),
+ D(pmt_from_complex, 1));
+
+
+ m.def("to_complex", &::pmt::to_complex, py::arg("z"), D(to_complex));
+
+
+ m.def("is_null", &::pmt::is_null, py::arg("x"), D(is_null));
+
+
+ m.def("is_pair", &::pmt::is_pair, py::arg("obj"), D(is_pair));
+
+
+ m.def("cons", &::pmt::cons, py::arg("x"), py::arg("y"), D(cons));
+
+
+ m.def("dcons", &::pmt::dcons, py::arg("x"), py::arg("y"), D(dcons));
+
+
+ m.def("car", &::pmt::car, py::arg("pair"), D(car));
+
+
+ m.def("cdr", &::pmt::cdr, py::arg("pair"), D(cdr));
+
+
+ m.def("set_car", &::pmt::set_car, py::arg("pair"), py::arg("value"), D(set_car));
+
+
+ m.def("set_cdr", &::pmt::set_cdr, py::arg("pair"), py::arg("value"), D(set_cdr));
+
+
+ m.def("caar", &::pmt::caar, py::arg("pair"), D(caar));
+
+
+ m.def("cadr", &::pmt::cadr, py::arg("pair"), D(cadr));
+
+
+ m.def("cdar", &::pmt::cdar, py::arg("pair"), D(cdar));
+
+
+ m.def("cddr", &::pmt::cddr, py::arg("pair"), D(cddr));
+
+
+ m.def("caddr", &::pmt::caddr, py::arg("pair"), D(caddr));
+
+
+ m.def("cadddr", &::pmt::cadddr, py::arg("pair"), D(cadddr));
+
+
+ m.def("is_tuple", &::pmt::is_tuple, py::arg("x"), D(is_tuple));
+
+
+ m.def("make_tuple", (pmt::pmt_t(*)()) & ::pmt::make_tuple, D(make_tuple, 0));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&)) & ::pmt::make_tuple,
+ py::arg("e0"),
+ D(make_tuple, 1));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&, pmt::pmt_t const&)) & ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ D(make_tuple, 2));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ D(make_tuple, 3));
+
+
+ m.def(
+ "make_tuple",
+ (pmt::pmt_t(*)(
+ pmt::pmt_t const&, pmt::pmt_t const&, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ D(make_tuple, 4));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ D(make_tuple, 5));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ D(make_tuple, 6));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ D(make_tuple, 7));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ py::arg("e7"),
+ D(make_tuple, 8));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ py::arg("e7"),
+ py::arg("e8"),
+ D(make_tuple, 9));
+
+
+ m.def("make_tuple",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::make_tuple,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ py::arg("e7"),
+ py::arg("e8"),
+ py::arg("e9"),
+ D(make_tuple, 10));
+
+
+ m.def("to_tuple", &::pmt::to_tuple, py::arg("x"), D(to_tuple));
+
+
+ m.def("tuple_ref", &::pmt::tuple_ref, py::arg("tuple"), py::arg("k"), D(tuple_ref));
+
+
+ m.def("is_vector", &::pmt::is_vector, py::arg("x"), D(is_vector));
+
+
+ m.def("make_vector",
+ &::pmt::make_vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_vector));
+
+
+ m.def(
+ "vector_ref", &::pmt::vector_ref, py::arg("vector"), py::arg("k"), D(vector_ref));
+
+
+ m.def("vector_set",
+ &::pmt::vector_set,
+ py::arg("vector"),
+ py::arg("k"),
+ py::arg("obj"),
+ D(vector_set));
+
+
+ m.def("vector_fill",
+ &::pmt::vector_fill,
+ py::arg("vector"),
+ py::arg("fill"),
+ D(vector_fill));
+
+
+ m.def("is_blob", &::pmt::is_blob, py::arg("x"), D(is_blob));
+
+
+ m.def("make_blob", &::pmt::make_blob, py::arg("buf"), py::arg("len"), D(make_blob));
+
+
+ m.def("blob_data", &::pmt::blob_data, py::arg("blob"), D(blob_data));
+
+
+ m.def("blob_length", &::pmt::blob_length, py::arg("blob"), D(blob_length));
+
+
+ m.def("is_uniform_vector",
+ &::pmt::is_uniform_vector,
+ py::arg("x"),
+ D(is_uniform_vector));
+
+
+ m.def("is_u8vector", &::pmt::is_u8vector, py::arg("x"), D(is_u8vector));
+
+
+ m.def("is_s8vector", &::pmt::is_s8vector, py::arg("x"), D(is_s8vector));
+
+
+ m.def("is_u16vector", &::pmt::is_u16vector, py::arg("x"), D(is_u16vector));
+
+
+ m.def("is_s16vector", &::pmt::is_s16vector, py::arg("x"), D(is_s16vector));
+
+
+ m.def("is_u32vector", &::pmt::is_u32vector, py::arg("x"), D(is_u32vector));
+
+
+ m.def("is_s32vector", &::pmt::is_s32vector, py::arg("x"), D(is_s32vector));
+
+
+ m.def("is_u64vector", &::pmt::is_u64vector, py::arg("x"), D(is_u64vector));
+
+
+ m.def("is_s64vector", &::pmt::is_s64vector, py::arg("x"), D(is_s64vector));
+
+
+ m.def("is_f32vector", &::pmt::is_f32vector, py::arg("x"), D(is_f32vector));
+
+
+ m.def("is_f64vector", &::pmt::is_f64vector, py::arg("x"), D(is_f64vector));
+
+
+ m.def("is_c32vector", &::pmt::is_c32vector, py::arg("x"), D(is_c32vector));
+
+
+ m.def("is_c64vector", &::pmt::is_c64vector, py::arg("x"), D(is_c64vector));
+
+
+ m.def("uniform_vector_itemsize",
+ &::pmt::uniform_vector_itemsize,
+ py::arg("x"),
+ D(uniform_vector_itemsize));
+
+
+ m.def("make_u8vector",
+ &::pmt::make_u8vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_u8vector));
+
+
+ m.def("make_s8vector",
+ &::pmt::make_s8vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_s8vector));
+
+
+ m.def("make_u16vector",
+ &::pmt::make_u16vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_u16vector));
+
+
+ m.def("make_s16vector",
+ &::pmt::make_s16vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_s16vector));
+
+
+ m.def("make_u32vector",
+ &::pmt::make_u32vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_u32vector));
+
+
+ m.def("make_s32vector",
+ &::pmt::make_s32vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_s32vector));
+
+
+ m.def("make_u64vector",
+ &::pmt::make_u64vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_u64vector));
+
+
+ m.def("make_s64vector",
+ &::pmt::make_s64vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_s64vector));
+
+
+ m.def("make_f32vector",
+ &::pmt::make_f32vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_f32vector));
+
+
+ m.def("make_f64vector",
+ &::pmt::make_f64vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_f64vector));
+
+
+ m.def("make_c32vector",
+ &::pmt::make_c32vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_c32vector));
+
+
+ m.def("make_c64vector",
+ &::pmt::make_c64vector,
+ py::arg("k"),
+ py::arg("fill"),
+ D(make_c64vector));
+
+
+ m.def("init_u8vector",
+ (pmt::pmt_t(*)(size_t, uint8_t const*)) & ::pmt::init_u8vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u8vector, 0));
+
+
+ m.def("init_u8vector",
+ (pmt::pmt_t(*)(
+ size_t, std::vector<unsigned char, std::allocator<unsigned char>> const&)) &
+ ::pmt::init_u8vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u8vector, 1));
+
+
+ m.def("init_s8vector",
+ (pmt::pmt_t(*)(size_t, int8_t const*)) & ::pmt::init_s8vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s8vector, 0));
+
+
+ m.def("init_s8vector",
+ (pmt::pmt_t(*)(size_t,
+ std::vector<signed char, std::allocator<signed char>> const&)) &
+ ::pmt::init_s8vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s8vector, 1));
+
+
+ m.def("init_u16vector",
+ (pmt::pmt_t(*)(size_t, uint16_t const*)) & ::pmt::init_u16vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u16vector, 0));
+
+
+ m.def(
+ "init_u16vector",
+ (pmt::pmt_t(*)(
+ size_t, std::vector<unsigned short, std::allocator<unsigned short>> const&)) &
+ ::pmt::init_u16vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u16vector, 1));
+
+
+ m.def("init_s16vector",
+ (pmt::pmt_t(*)(size_t, int16_t const*)) & ::pmt::init_s16vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s16vector, 0));
+
+
+ m.def("init_s16vector",
+ (pmt::pmt_t(*)(size_t, std::vector<short, std::allocator<short>> const&)) &
+ ::pmt::init_s16vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s16vector, 1));
+
+
+ m.def("init_u32vector",
+ (pmt::pmt_t(*)(size_t, uint32_t const*)) & ::pmt::init_u32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u32vector, 0));
+
+
+ m.def("init_u32vector",
+ (pmt::pmt_t(*)(
+ size_t, std::vector<unsigned int, std::allocator<unsigned int>> const&)) &
+ ::pmt::init_u32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u32vector, 1));
+
+
+ m.def("init_s32vector",
+ (pmt::pmt_t(*)(size_t, int32_t const*)) & ::pmt::init_s32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s32vector, 0));
+
+
+ m.def("init_s32vector",
+ (pmt::pmt_t(*)(size_t, std::vector<int, std::allocator<int>> const&)) &
+ ::pmt::init_s32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s32vector, 1));
+
+
+ m.def("init_u64vector",
+ (pmt::pmt_t(*)(size_t, uint64_t const*)) & ::pmt::init_u64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u64vector, 0));
+
+
+ m.def(
+ "init_u64vector",
+ (pmt::pmt_t(*)(size_t, std::vector<uint64_t, std::allocator<uint64_t>> const&)) &
+ ::pmt::init_u64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_u64vector, 1));
+
+
+ m.def("init_s64vector",
+ (pmt::pmt_t(*)(size_t, int64_t const*)) & ::pmt::init_s64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s64vector, 0));
+
+
+ m.def("init_s64vector",
+ (pmt::pmt_t(*)(size_t, std::vector<int64_t, std::allocator<int64_t>> const&)) &
+ ::pmt::init_s64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_s64vector, 1));
+
+
+ m.def("init_f32vector",
+ (pmt::pmt_t(*)(size_t, float const*)) & ::pmt::init_f32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_f32vector, 0));
+
+
+ m.def("init_f32vector",
+ (pmt::pmt_t(*)(size_t, std::vector<float, std::allocator<float>> const&)) &
+ ::pmt::init_f32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_f32vector, 1));
+
+
+ m.def("init_f64vector",
+ (pmt::pmt_t(*)(size_t, double const*)) & ::pmt::init_f64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_f64vector, 0));
+
+
+ m.def("init_f64vector",
+ (pmt::pmt_t(*)(size_t, std::vector<double, std::allocator<double>> const&)) &
+ ::pmt::init_f64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_f64vector, 1));
+
+
+ m.def("init_c32vector",
+ (pmt::pmt_t(*)(size_t, std::complex<float> const*)) & ::pmt::init_c32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_c32vector, 0));
+
+
+ m.def("init_c32vector",
+ (pmt::pmt_t(*)(size_t,
+ std::vector<std::complex<float>,
+ std::allocator<std::complex<float>>> const&)) &
+ ::pmt::init_c32vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_c32vector, 1));
+
+
+ m.def("init_c64vector",
+ (pmt::pmt_t(*)(size_t, std::complex<double> const*)) & ::pmt::init_c64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_c64vector, 0));
+
+
+ m.def("init_c64vector",
+ (pmt::pmt_t(*)(size_t,
+ std::vector<std::complex<double>,
+ std::allocator<std::complex<double>>> const&)) &
+ ::pmt::init_c64vector,
+ py::arg("k"),
+ py::arg("data"),
+ D(init_c64vector, 1));
+
+
+ m.def("u8vector_ref",
+ &::pmt::u8vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(u8vector_ref));
+
+
+ m.def("s8vector_ref",
+ &::pmt::s8vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(s8vector_ref));
+
+
+ m.def("u16vector_ref",
+ &::pmt::u16vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(u16vector_ref));
+
+
+ m.def("s16vector_ref",
+ &::pmt::s16vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(s16vector_ref));
+
+
+ m.def("u32vector_ref",
+ &::pmt::u32vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(u32vector_ref));
+
+
+ m.def("s32vector_ref",
+ &::pmt::s32vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(s32vector_ref));
+
+
+ m.def("u64vector_ref",
+ &::pmt::u64vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(u64vector_ref));
+
+
+ m.def("s64vector_ref",
+ &::pmt::s64vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(s64vector_ref));
+
+
+ m.def("f32vector_ref",
+ &::pmt::f32vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(f32vector_ref));
+
+
+ m.def("f64vector_ref",
+ &::pmt::f64vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(f64vector_ref));
+
+
+ m.def("c32vector_ref",
+ &::pmt::c32vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(c32vector_ref));
+
+
+ m.def("c64vector_ref",
+ &::pmt::c64vector_ref,
+ py::arg("v"),
+ py::arg("k"),
+ D(c64vector_ref));
+
+
+ m.def("u8vector_set",
+ &::pmt::u8vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(u8vector_set));
+
+
+ m.def("s8vector_set",
+ &::pmt::s8vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(s8vector_set));
+
+
+ m.def("u16vector_set",
+ &::pmt::u16vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(u16vector_set));
+
+
+ m.def("s16vector_set",
+ &::pmt::s16vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(s16vector_set));
+
+
+ m.def("u32vector_set",
+ &::pmt::u32vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(u32vector_set));
+
+
+ m.def("s32vector_set",
+ &::pmt::s32vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(s32vector_set));
+
+
+ m.def("u64vector_set",
+ &::pmt::u64vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(u64vector_set));
+
+
+ m.def("s64vector_set",
+ &::pmt::s64vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(s64vector_set));
+
+
+ m.def("f32vector_set",
+ &::pmt::f32vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(f32vector_set));
+
+
+ m.def("f64vector_set",
+ &::pmt::f64vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(f64vector_set));
+
+
+ m.def("c32vector_set",
+ &::pmt::c32vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(c32vector_set));
+
+
+ m.def("c64vector_set",
+ &::pmt::c64vector_set,
+ py::arg("v"),
+ py::arg("k"),
+ py::arg("x"),
+ D(c64vector_set));
+
+
+ m.def("uniform_vector_elements",
+ &::pmt::uniform_vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(uniform_vector_elements));
+
+
+ m.def("u8vector_elements",
+ (uint8_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::u8vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u8vector_elements, 0));
+
+
+ m.def("s8vector_elements",
+ (int8_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::s8vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s8vector_elements, 0));
+
+
+ m.def("u16vector_elements",
+ (uint16_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::u16vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u16vector_elements, 0));
+
+
+ m.def("s16vector_elements",
+ (int16_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::s16vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s16vector_elements, 0));
+
+
+ m.def("u32vector_elements",
+ (uint32_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::u32vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u32vector_elements, 0));
+
+
+ m.def("s32vector_elements",
+ (int32_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::s32vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s32vector_elements, 0));
+
+
+ m.def("u64vector_elements",
+ (uint64_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::u64vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u64vector_elements, 0));
+
+
+ m.def("s64vector_elements",
+ (int64_t const* (*)(pmt::pmt_t, size_t&)) & ::pmt::s64vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s64vector_elements, 0));
+
+
+ m.def("f32vector_elements",
+ (float const* (*)(pmt::pmt_t, size_t&)) & ::pmt::f32vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(f32vector_elements, 0));
+
+
+ m.def("f64vector_elements",
+ (double const* (*)(pmt::pmt_t, size_t&)) & ::pmt::f64vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(f64vector_elements, 0));
+
+
+ m.def("c32vector_elements",
+ (std::complex<float> const* (*)(pmt::pmt_t, size_t&)) &
+ ::pmt::c32vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(c32vector_elements, 0));
+
+
+ m.def("c64vector_elements",
+ (std::complex<double> const* (*)(pmt::pmt_t, size_t&)) &
+ ::pmt::c64vector_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(c64vector_elements, 0));
+
+ m.def("u8vector_elements",
+ (std::vector<unsigned char, std::allocator<unsigned char>> const (*)(
+ pmt::pmt_t)) &
+ ::pmt::u8vector_elements,
+ py::arg("v"),
+ D(u8vector_elements, 1));
+
+
+ m.def("s8vector_elements",
+ (std::vector<signed char, std::allocator<signed char>> const (*)(pmt::pmt_t)) &
+ ::pmt::s8vector_elements,
+ py::arg("v"),
+ D(s8vector_elements, 1));
+
+
+ m.def("u16vector_elements",
+ (std::vector<unsigned short, std::allocator<unsigned short>> const (*)(
+ pmt::pmt_t)) &
+ ::pmt::u16vector_elements,
+ py::arg("v"),
+ D(u16vector_elements, 1));
+
+
+ m.def("s16vector_elements",
+ (std::vector<short, std::allocator<short>> const (*)(pmt::pmt_t)) &
+ ::pmt::s16vector_elements,
+ py::arg("v"),
+ D(s16vector_elements, 1));
+
+
+ m.def(
+ "u32vector_elements",
+ (std::vector<unsigned int, std::allocator<unsigned int>> const (*)(pmt::pmt_t)) &
+ ::pmt::u32vector_elements,
+ py::arg("v"),
+ D(u32vector_elements, 1));
+
+
+ m.def("s32vector_elements",
+ (std::vector<int, std::allocator<int>> const (*)(pmt::pmt_t)) &
+ ::pmt::s32vector_elements,
+ py::arg("v"),
+ D(s32vector_elements, 1));
+
+
+ m.def("u64vector_elements",
+ (std::vector<uint64_t, std::allocator<uint64_t>> const (*)(pmt::pmt_t)) &
+ ::pmt::u64vector_elements,
+ py::arg("v"),
+ D(u64vector_elements, 1));
+
+
+ m.def("s64vector_elements",
+ (std::vector<int64_t, std::allocator<int64_t>> const (*)(pmt::pmt_t)) &
+ ::pmt::s64vector_elements,
+ py::arg("v"),
+ D(s64vector_elements, 1));
+
+
+ m.def("f32vector_elements",
+ (std::vector<float, std::allocator<float>> const (*)(pmt::pmt_t)) &
+ ::pmt::f32vector_elements,
+ py::arg("v"),
+ D(f32vector_elements, 1));
+
+
+ m.def("f64vector_elements",
+ (std::vector<double, std::allocator<double>> const (*)(pmt::pmt_t)) &
+ ::pmt::f64vector_elements,
+ py::arg("v"),
+ D(f64vector_elements, 1));
+
+
+ m.def(
+ "c32vector_elements",
+ (std::vector<std::complex<float>, std::allocator<std::complex<float>>> const (*)(
+ pmt::pmt_t)) &
+ ::pmt::c32vector_elements,
+ py::arg("v"),
+ D(c32vector_elements, 1));
+
+
+ m.def("c64vector_elements",
+ (std::vector<std::complex<double>,
+ std::allocator<std::complex<double>>> const (*)(pmt::pmt_t)) &
+ ::pmt::c64vector_elements,
+ py::arg("v"),
+ D(c64vector_elements, 1));
+
+ // The following functions are not implemented in pmt.cc
+ // m.def("pmt_u8vector_elements",&pmt::pmt_u8vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_s8vector_elements",&pmt::pmt_s8vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_u16vector_elements",&pmt::pmt_u16vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_s16vector_elements",&pmt::pmt_s16vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_u32vector_elements",&pmt::pmt_u32vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_s32vector_elements",&pmt::pmt_s32vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_u64vector_elements",&pmt::pmt_u64vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_s64vector_elements",&pmt::pmt_s64vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_f32vector_elements",&pmt::pmt_f32vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_f64vector_elements",&pmt::pmt_f64vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_c32vector_elements",&pmt::pmt_c32vector_elements,
+ // py::arg("v")
+ // );
+ // m.def("pmt_c64vector_elements",&pmt::pmt_c64vector_elements,
+ // py::arg("v")
+ // );
+ m.def("uniform_vector_writable_elements",
+ &::pmt::uniform_vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(uniform_vector_writable_elements));
+
+
+ m.def("u8vector_writable_elements",
+ &::pmt::u8vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u8vector_writable_elements));
+
+
+ m.def("s8vector_writable_elements",
+ &::pmt::s8vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s8vector_writable_elements));
+
+
+ m.def("u16vector_writable_elements",
+ &::pmt::u16vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u16vector_writable_elements));
+
+
+ m.def("s16vector_writable_elements",
+ &::pmt::s16vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s16vector_writable_elements));
+
+
+ m.def("u32vector_writable_elements",
+ &::pmt::u32vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u32vector_writable_elements));
+
+
+ m.def("s32vector_writable_elements",
+ &::pmt::s32vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s32vector_writable_elements));
+
+
+ m.def("u64vector_writable_elements",
+ &::pmt::u64vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(u64vector_writable_elements));
+
+
+ m.def("s64vector_writable_elements",
+ &::pmt::s64vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(s64vector_writable_elements));
+
+
+ m.def("f32vector_writable_elements",
+ &::pmt::f32vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(f32vector_writable_elements));
+
+
+ m.def("f64vector_writable_elements",
+ &::pmt::f64vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(f64vector_writable_elements));
+
+
+ m.def("c32vector_writable_elements",
+ &::pmt::c32vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(c32vector_writable_elements));
+
+
+ m.def("c64vector_writable_elements",
+ &::pmt::c64vector_writable_elements,
+ py::arg("v"),
+ py::arg("len"),
+ D(c64vector_writable_elements));
+
+
+ m.def("is_dict", &::pmt::is_dict, py::arg("obj"), D(is_dict));
+
+
+ m.def("make_dict", &::pmt::make_dict, D(make_dict));
+
+
+ m.def("dict_add",
+ &::pmt::dict_add,
+ py::arg("dict"),
+ py::arg("key"),
+ py::arg("value"),
+ D(dict_add));
+
+
+ m.def("dict_delete",
+ &::pmt::dict_delete,
+ py::arg("dict"),
+ py::arg("key"),
+ D(dict_delete));
+
+
+ m.def("dict_has_key",
+ &::pmt::dict_has_key,
+ py::arg("dict"),
+ py::arg("key"),
+ D(dict_has_key));
+
+
+ m.def("dict_ref",
+ &::pmt::dict_ref,
+ py::arg("dict"),
+ py::arg("key"),
+ py::arg("not_found"),
+ D(dict_ref));
+
+
+ m.def("dict_items", &::pmt::dict_items, py::arg("dict"), D(dict_items));
+
+
+ m.def("dict_keys", &::pmt::dict_keys, py::arg("dict"), D(dict_keys));
+
+
+ m.def("dict_update",
+ &::pmt::dict_update,
+ py::arg("dict1"),
+ py::arg("dict2"),
+ D(dict_update));
+
+
+ m.def("dict_values", &::pmt::dict_values, py::arg("dict"), D(dict_values));
+
+
+ m.def("is_any", &::pmt::is_any, py::arg("obj"), D(is_any));
+
+
+ m.def("make_any", &::pmt::make_any, py::arg("any"), D(make_any));
+
+
+ m.def("any_ref", &::pmt::any_ref, py::arg("obj"), D(any_ref));
+
+
+ m.def("any_set", &::pmt::any_set, py::arg("obj"), py::arg("any"), D(any_set));
+
+ // m.def("is_msg_accepter",&pmt::is_msg_accepter,
+ // py::arg("obj")
+ // );
+ // m.def("make_msg_accepter",&pmt::make_msg_accepter,
+ // py::arg("ma")
+ // );
+ // m.def("msg_accepter_ref",&pmt::msg_accepter_ref,
+ // py::arg("obj")
+ // );
+ m.def("is_pdu", &::pmt::is_pdu, py::arg("obj"), D(is_pdu));
+
+
+ m.def("eq", &::pmt::eq, py::arg("x"), py::arg("y"), D(eq));
+
+
+ m.def("eqv", &::pmt::eqv, py::arg("x"), py::arg("y"), D(eqv));
+
+
+ m.def("equal", &::pmt::equal, py::arg("x"), py::arg("y"), D(equal));
+
+
+ m.def("assq", &::pmt::assq, py::arg("obj"), py::arg("alist"), D(assq));
+
+
+ m.def("assv", &::pmt::assv, py::arg("obj"), py::arg("alist"), D(assv));
+
+
+ m.def("assoc", &::pmt::assoc, py::arg("obj"), py::arg("alist"), D(assoc));
+
+
+ m.def("map", &::pmt::map, py::arg("proc"), py::arg("list"), D(map));
+
+
+ m.def("reverse", &::pmt::reverse, py::arg("list"), D(reverse));
+
+
+ m.def("reverse_x", &::pmt::reverse_x, py::arg("list"), D(reverse_x));
+
+
+ m.def("acons", &::pmt::acons, py::arg("x"), py::arg("y"), py::arg("a"), D(acons));
+
+
+ m.def("nth", &::pmt::nth, py::arg("n"), py::arg("list"), D(nth));
+
+
+ m.def("nthcdr", &::pmt::nthcdr, py::arg("n"), py::arg("list"), D(nthcdr));
+
+
+ m.def("memq", &::pmt::memq, py::arg("obj"), py::arg("list"), D(memq));
+
+
+ m.def("memv", &::pmt::memv, py::arg("obj"), py::arg("list"), D(memv));
+
+
+ m.def("member", &::pmt::member, py::arg("obj"), py::arg("list"), D(member));
+
+
+ m.def("subsetp", &::pmt::subsetp, py::arg("list1"), py::arg("list2"), D(subsetp));
+
+
+ m.def("list1", &::pmt::list1, py::arg("x1"), D(list1));
+
+
+ m.def("list2", &::pmt::list2, py::arg("x1"), py::arg("x2"), D(list2));
+
+
+ m.def("list3", &::pmt::list3, py::arg("x1"), py::arg("x2"), py::arg("x3"), D(list3));
+
+
+ m.def("list4",
+ &::pmt::list4,
+ py::arg("x1"),
+ py::arg("x2"),
+ py::arg("x3"),
+ py::arg("x4"),
+ D(list4));
+
+
+ m.def("list5",
+ &::pmt::list5,
+ py::arg("x1"),
+ py::arg("x2"),
+ py::arg("x3"),
+ py::arg("x4"),
+ py::arg("x5"),
+ D(list5));
+
+
+ m.def("list6",
+ &::pmt::list6,
+ py::arg("x1"),
+ py::arg("x2"),
+ py::arg("x3"),
+ py::arg("x4"),
+ py::arg("x5"),
+ py::arg("x6"),
+ D(list6));
+
+
+ m.def("list_add", &::pmt::list_add, py::arg("list"), py::arg("item"), D(list_add));
+
+
+ m.def("list_rm", &::pmt::list_rm, py::arg("list"), py::arg("item"), D(list_rm));
+
+
+ m.def("list_has", &::pmt::list_has, py::arg("list"), py::arg("item"), D(list_has));
+
+
+ m.def("is_eof_object", &::pmt::is_eof_object, py::arg("obj"), D(is_eof_object));
+
+
+ m.def("read", &::pmt::read, py::arg("port"), D(read));
+
+
+ m.def("write", &::pmt::write, py::arg("obj"), py::arg("port"), D(write));
+
+
+ m.def("write_string", &::pmt::write_string, py::arg("obj"), D(write_string));
+
+
+ m.def("print", &::pmt::print, py::arg("v"), D(print));
+
+
+ m.def("serialize", &::pmt::serialize, py::arg("obj"), py::arg("sink"), D(serialize));
+
+
+ m.def("deserialize", &::pmt::deserialize, py::arg("source"), D(deserialize));
+
+
+ m.def("dump_sizeof", &::pmt::dump_sizeof, D(dump_sizeof));
+
+ m.def("length", &pmt::length, py::arg("v"));
+
+ // pybind11 needs explicit conversion to handle non-utf8 strings
+ m.def(
+ "serialize_str",
+ [](pmt::pmt_t obj) {
+ std::string s = serialize_str(obj);
+ return py::bytes(s); // Return the data without transcoding
+ },
+ py::arg("obj"),
+ D(serialize_str));
+
+ m.def("deserialize_str", &pmt::deserialize_str, py::arg("str"), D(deserialize_str));
+}
diff --git a/gnuradio-runtime/python/pmt/bindings/pmt_sugar_python.cc b/gnuradio-runtime/python/pmt/bindings/pmt_sugar_python.cc
new file mode 100644
index 0000000000..442d00369f
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/pmt_sugar_python.cc
@@ -0,0 +1,217 @@
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+/* This file is automatically generated using bindtool */
+
+#include <pybind11/complex.h>
+#include <pybind11/pybind11.h>
+#include <pybind11/stl.h>
+
+namespace py = pybind11;
+
+#include <pmt/pmt_sugar.h>
+// pydoc.h is automatically generated in the build directory
+#include <pmt_sugar_pydoc.h>
+
+void bind_pmt_sugar(py::module& m)
+{
+ m.def("mp", (pmt::pmt_t(*)(std::string const&)) & ::pmt::mp, py::arg("s"), D(mp, 0));
+
+
+ m.def("mp", (pmt::pmt_t(*)(char const*)) & ::pmt::mp, py::arg("s"), D(mp, 1));
+
+
+ m.def("mp", (pmt::pmt_t(*)(long int)) & ::pmt::mp, py::arg("x"), D(mp, 2));
+
+
+ m.def("mp", (pmt::pmt_t(*)(long unsigned int)) & ::pmt::mp, py::arg("x"), D(mp, 3));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(long long unsigned int)) & ::pmt::mp,
+ py::arg("x"),
+ D(mp, 4));
+
+
+ m.def("mp", (pmt::pmt_t(*)(int)) & ::pmt::mp, py::arg("x"), D(mp, 5));
+
+
+ m.def("mp", (pmt::pmt_t(*)(double)) & ::pmt::mp, py::arg("x"), D(mp, 6));
+
+
+ m.def(
+ "mp", (pmt::pmt_t(*)(std::complex<double>)) & ::pmt::mp, py::arg("z"), D(mp, 7));
+
+
+ m.def("mp", (pmt::pmt_t(*)(std::complex<float>)) & ::pmt::mp, py::arg("z"), D(mp, 8));
+
+
+ // m.def("mp",
+ // (pmt::pmt_t(*)(std::shared_ptr<gr::messages::msg_accepter>)) & ::pmt::mp,
+ // py::arg("ma"),
+ // D(mp, 9));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(void const*, size_t)) & ::pmt::mp,
+ py::arg("data"),
+ py::arg("len_in_bytes"),
+ D(mp, 10));
+
+
+ m.def("mp", (pmt::pmt_t(*)(pmt::pmt_t const&)) & ::pmt::mp, py::arg("e0"), D(mp, 11));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&, pmt::pmt_t const&)) & ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ D(mp, 12));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ D(mp, 13));
+
+
+ m.def(
+ "mp",
+ (pmt::pmt_t(*)(
+ pmt::pmt_t const&, pmt::pmt_t const&, pmt::pmt_t const&, pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ D(mp, 14));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ D(mp, 15));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ D(mp, 16));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ D(mp, 17));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ py::arg("e7"),
+ D(mp, 18));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ py::arg("e7"),
+ py::arg("e8"),
+ D(mp, 19));
+
+
+ m.def("mp",
+ (pmt::pmt_t(*)(pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&,
+ pmt::pmt_t const&)) &
+ ::pmt::mp,
+ py::arg("e0"),
+ py::arg("e1"),
+ py::arg("e2"),
+ py::arg("e3"),
+ py::arg("e4"),
+ py::arg("e5"),
+ py::arg("e6"),
+ py::arg("e7"),
+ py::arg("e8"),
+ py::arg("e9"),
+ D(mp, 20));
+}
diff --git a/gnuradio-runtime/python/pmt/bindings/python_bindings.cc b/gnuradio-runtime/python/pmt/bindings/python_bindings.cc
new file mode 100644
index 0000000000..af312f5802
--- /dev/null
+++ b/gnuradio-runtime/python/pmt/bindings/python_bindings.cc
@@ -0,0 +1,46 @@
+
+/*
+ * Copyright 2020 Free Software Foundation, Inc.
+ *
+ * This file is part of GNU Radio
+ *
+ * SPDX-License-Identifier: GPL-3.0-or-later
+ *
+ */
+
+#include <pybind11/pybind11.h>
+
+#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
+#include <numpy/arrayobject.h>
+
+namespace py = pybind11;
+
+void bind_pmt(py::module&);
+void bind_pmt_pool(py::module&);
+// void bind_pmt_serial_tags(py::module&);
+void bind_pmt_sugar(py::module&);
+
+// We need this hack because import_array() returns NULL
+// for newer Python versions.
+// This function is also necessary because it ensures access to the C API
+// and removes a warning.
+void* init_numpy()
+{
+ import_array();
+ return NULL;
+}
+
+PYBIND11_MODULE(pmt_python, m)
+{
+ // Initialize the numpy C API
+ // (otherwise we will see segmentation faults)
+ init_numpy();
+
+ // Allow access to base block methods
+ // py::module::import("gnuradio.gr");
+
+ bind_pmt(m);
+ bind_pmt_pool(m);
+ // bind_pmt_serial_tags(m);
+ bind_pmt_sugar(m);
+}
diff --git a/gnuradio-runtime/python/pmt/pmt_to_python.py b/gnuradio-runtime/python/pmt/pmt_to_python.py
index 1c547ba521..425d68b6d1 100644
--- a/gnuradio-runtime/python/pmt/pmt_to_python.py
+++ b/gnuradio-runtime/python/pmt/pmt_to_python.py
@@ -7,7 +7,7 @@
from __future__ import unicode_literals
-from . import pmt_swig as pmt
+from . import pmt_python as pmt
import numpy
# SWIG isn't taking in the #define PMT_NIL;
@@ -112,7 +112,7 @@ def pmt_to_python(p):
if pmt_check(p):
try:
return to_python(p)
- except (TypeError, ValueError):
+ except (RuntimeError, TypeError, ValueError): # TODO: make pybind11 handle wrong_type, convert to type error
# This exception will be handled by the general failure case
pass
raise ValueError("can't convert %s type to pmt (%s)"%(type(p),p))
diff --git a/gnuradio-runtime/swig/CMakeLists.txt b/gnuradio-runtime/swig/CMakeLists.txt
deleted file mode 100644
index a2a685e19e..0000000000
--- a/gnuradio-runtime/swig/CMakeLists.txt
+++ /dev/null
@@ -1,102 +0,0 @@
-# Copyright 2013,2019 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# SPDX-License-Identifier: GPL-3.0-or-later
-#
-
-########################################################################
-# Setup swig generation
-########################################################################
-include(GrPython)
-include(GrSwig)
-
-set(GR_SWIG_INCLUDE_DIRS
- $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
- $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>
- $<INSTALL_INTERFACE:include/gnuradio/swig>
- )
-
-set(GR_SWIG_LIBRARIES
- gnuradio-runtime)
-
-###############################################################
-# Build pmt swig
-###############################################################
-
-set(GR_SWIG_DOC_FILE ${CMAKE_CURRENT_BINARY_DIR}/pmt_swig_doc.i)
-set(GR_SWIG_DOC_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../include/pmt
- ${CMAKE_CURRENT_BINARY_DIR}/../include/pmt)
-GR_SWIG_MAKE(pmt_swig pmt_swig.i)
-
-GR_SWIG_INSTALL(
- TARGETS pmt_swig
- DESTINATION ${GR_PYTHON_DIR}/pmt
-)
-
-###############################################################
-# Build gnuradio-runtime swig
-###############################################################
-set(GR_SWIG_DOC_FILE ${CMAKE_CURRENT_BINARY_DIR}/runtime_swig_doc.i)
-set(GR_SWIG_DOC_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../include)
-set(GR_RUNTIME_SWIG_DOC_FILE ${GR_SWIG_DOC_FILE})
-if(ENABLE_GR_CTRLPORT)
- set(GR_SWIG_FLAGS "-DGR_CTRLPORT")
-endif()
-list(APPEND GR_SWIG_TARGET_DEPS pmt_swig)
-
-GR_SWIG_MAKE(runtime_swig runtime_swig.i)
-
-install(
- TARGETS runtime_swig
- EXPORT runtime_swig-export
- DESTINATION ${GR_PYTHON_DIR}/gnuradio/gr
- )
-
-include(GrPython)
-GR_PYTHON_INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/runtime_swig.py
- DESTINATION ${GR_PYTHON_DIR}/gnuradio/gr
- DEPENDS runtime_swig
-)
-
-install(EXPORT runtime_swig-export
- FILE runtime_swigTargets.cmake
- NAMESPACE gnuradio::
- DESTINATION ${GR_CMAKE_DIR}
-)
-
-install(
- FILES
- runtime_swig.i
- gnuradio.i
- basic_block.i
- block.i
- block_detail.i
- block_gateway.i
- buffer.i
- constants.i
- feval.i
- gr_ctrlport.i
- gr_extras.i
- gr_logger.i
- gr_shared_ptr.i
- gr_swig_block_magic.i
- gr_types.i
- hier_block2.i
- io_signature.i
- message.i
- msg_handler.i
- msg_queue.i
- pmt_swig.i
- prefs.i
- realtime.i
- sync_block.i
- sync_decimator.i
- sync_interpolator.i
- tagged_stream_block.i
- tags.i
- top_block.i
- ${CMAKE_CURRENT_BINARY_DIR}/runtime_swig_doc.i
- ${CMAKE_CURRENT_BINARY_DIR}/pmt_swig_doc.i
- DESTINATION ${GR_INCLUDE_DIR}/gnuradio/swig
-)
diff --git a/gnuradio-runtime/swig/basic_block.i b/gnuradio-runtime/swig/basic_block.i
deleted file mode 100644
index 3ded09031a..0000000000
--- a/gnuradio-runtime/swig/basic_block.i
+++ /dev/null
@@ -1,54 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2006,2010,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::basic_block;
-typedef std::shared_ptr<gr::basic_block> gr::basic_block_sptr;
-%template(basic_block_sptr) std::shared_ptr<gr::basic_block>;
-
-%import "pmt_swig.i"
-
-// support vectors of these...
-namespace std {
- %template(x_vector_basic_block_sptr) vector<gr::basic_block_sptr>;
-};
-
-namespace gr {
-
- class gr::basic_block
- {
- protected:
- basic_block();
-
- public:
- virtual ~basic_block();
- std::string name() const;
- std::string symbol_name() const;
- gr::io_signature::sptr input_signature() const;
- gr::io_signature::sptr output_signature() const;
- long unique_id() const;
- gr::basic_block_sptr to_basic_block();
- bool check_topology(int ninputs, int noutputs);
- std::string alias();
- void set_block_alias(std::string name);
- void _post(pmt::pmt_t which_port, pmt::pmt_t msg);
- pmt::pmt_t message_ports_in();
- pmt::pmt_t message_ports_out();
- pmt::pmt_t message_subscribers(pmt::pmt_t which_port);
- };
-
- %rename(block_ncurrently_allocated) basic_block_ncurrently_allocated;
- long basic_block_ncurrently_allocated();
-}
-
-#ifdef SWIGPYTHON
-%pythoncode %{
-basic_block_sptr.__repr__ = lambda self: "<basic_block %s (%d)>" % (self.name(), self.unique_id ())
-%}
-#endif
diff --git a/gnuradio-runtime/swig/block.i b/gnuradio-runtime/swig/block.i
deleted file mode 100644
index fb21dd1447..0000000000
--- a/gnuradio-runtime/swig/block.i
+++ /dev/null
@@ -1,108 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2010,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-%include <basic_block.i>
-
-class gr::block;
-typedef std::shared_ptr<gr::block> gr::block_sptr;
-%template(block_sptr) std::shared_ptr<gr::block>;
-
-// support vectors of these...
-namespace std {
- %template(x_vector_block_sptr) vector<gr::block_sptr>;
-};
-
-class gr::block : public gr::basic_block
-{
- protected:
- block (const std::string &name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature);
-
- public:
-
- virtual ~block ();
-
- unsigned history () const;
-
- void declare_sample_delay(int which, int delay);
- void declare_sample_delay(unsigned int delay);
- unsigned sample_delay(int which) const;
-
- void set_output_multiple(int multiple);
- int output_multiple () const;
- double relative_rate () const;
- uint64_t relative_rate_i () const;
- uint64_t relative_rate_d () const;
-
- bool start();
- bool stop();
-
- uint64_t nitems_read(unsigned int which_input);
- uint64_t nitems_written(unsigned int which_output);
-
- void set_log_level(std::string level);
- std::string log_level();
-
- // Methods to manage the block's max_noutput_items size.
- int max_noutput_items();
- void set_max_noutput_items(int m);
- void unset_max_noutput_items();
- bool is_set_max_noutput_items();
- void set_min_noutput_items(int m);
- int min_noutput_items() const;
-
- // Methods to manage block's min/max buffer sizes.
- long max_output_buffer(int i);
- void set_max_output_buffer(long max_output_buffer);
- void set_max_output_buffer(int port, long max_output_buffer);
- long min_output_buffer(int i);
- void set_min_output_buffer(long min_output_buffer);
- void set_min_output_buffer(int port, long min_output_buffer);
-
- // Methods to access performance counters
- float pc_noutput_items();
- float pc_noutput_items_avg();
- float pc_noutput_items_var();
- float pc_nproduced();
- float pc_nproduced_avg();
- float pc_nproduced_var();
- float pc_input_buffers_full(int which);
- float pc_input_buffers_full_avg(int which);
- float pc_input_buffers_full_var(int which);
- std::vector<float> pc_input_buffers_full();
- std::vector<float> pc_input_buffers_full_avg();
- std::vector<float> pc_input_buffers_full_var();
- float pc_output_buffers_full(int which);
- float pc_output_buffers_full_avg(int which);
- float pc_output_buffers_full_var(int which);
- std::vector<float> pc_output_buffers_full();
- std::vector<float> pc_output_buffers_full_avg();
- std::vector<float> pc_output_buffers_full_var();
- float pc_work_time();
- float pc_work_time_avg();
- float pc_work_time_var();
- float pc_work_time_total();
- float pc_throughput_avg();
-
- // Methods to manage processor affinity.
- void set_processor_affinity(const std::vector<int> &mask);
- void unset_processor_affinity();
- std::vector<int> processor_affinity();
-
- // Methods to manage thread priority
- int active_thread_priority();
- int thread_priority();
- int set_thread_priority(int priority);
-
- // internal use
- //block_detail_sptr detail () const { return d_detail; }
- //void set_detail (block_detail_sptr detail) { d_detail = detail; }
-};
diff --git a/gnuradio-runtime/swig/block_detail.i b/gnuradio-runtime/swig/block_detail.i
deleted file mode 100644
index 6e335aaf36..0000000000
--- a/gnuradio-runtime/swig/block_detail.i
+++ /dev/null
@@ -1,44 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::block_detail;
-typedef std::shared_ptr<gr::block_detail> gr::block_detail_sptr;
-%template(block_detail_sptr) std::shared_ptr<gr::block_detail>;
-%rename(block_detail) gr::make_block_detail;
-%ignore gr::block_detail;
-
-gr::block_detail_sptr gr::
-gr::make_block_detail(unsigned int ninputs, unsigned int noutputs);
-
-namespace gr {
-
- class gr::block_detail {
- public:
-
- ~block_detail ();
-
- int ninputs() const;
- int noutputs() const;
- bool sink_p() const;
- bool source_p() const;
-
- void set_input(unsigned int which, gr::buffer_reader_sptr reader);
- gr::buffer_reader_sptr input(unsigned int which);
-
- void set_output(unsigned int which, gr::buffer_sptr buffer);
- gr::buffer_sptr output(unsigned int which);
-
- private:
- block_detail(unsigned int ninputs, unsigned int noutputs);
- };
-
- %rename(block_detail_ncurrently_allocated) block_detail_ncurrently_allocated;
- long block_detail_ncurrently_allocated();
-}
diff --git a/gnuradio-runtime/swig/block_gateway.i b/gnuradio-runtime/swig/block_gateway.i
deleted file mode 100644
index b95b045b72..0000000000
--- a/gnuradio-runtime/swig/block_gateway.i
+++ /dev/null
@@ -1,37 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2011-2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-////////////////////////////////////////////////////////////////////////
-// standard includes
-////////////////////////////////////////////////////////////////////////
-%include <gnuradio.i>
-%include <tags.i>
-%import <feval.i>
-
-%template(void_start_vector_t) std::vector<void *>;
-
-////////////////////////////////////////////////////////////////////////
-// block headers
-////////////////////////////////////////////////////////////////////////
-%{
-#include <gnuradio/block_gateway.h>
-%}
-
-////////////////////////////////////////////////////////////////////////
-// block magic
-////////////////////////////////////////////////////////////////////////
-%include <gnuradio/block_gateway.h>
-
-%template(block_gateway_sptr) std::shared_ptr<gr::block_gateway>;
-%pythoncode %{
-block_gateway_sptr.__repr__ = lambda self: "<block_gateway>"
-block_gateway = block_gateway.make;
-%}
-
diff --git a/gnuradio-runtime/swig/buffer.i b/gnuradio-runtime/swig/buffer.i
deleted file mode 100644
index a95c7996a0..0000000000
--- a/gnuradio-runtime/swig/buffer.i
+++ /dev/null
@@ -1,55 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::buffer;
-typedef std::shared_ptr<gr::buffer> gr::buffer_sptr;
-%template(buffer_sptr) std::shared_ptr<gr::buffer>;
-%rename(buffer) gr::make_buffer;
-%ignore gr::buffer;
-
-gr::buffer_sptr
-gr::make_buffer (int nitems, size_t sizeof_item, gr::block_sptr link);
-
-class gr::buffer_reader;
-typedef std::shared_ptr<gr::buffer_reader> gr::buffer_reader_sptr;
-%template(buffer_reader_sptr) std::shared_ptr<gr::buffer_reader>;
-%ignore gr::buffer_reader;
-
-%rename(buffer_add_reader) gr::buffer_add_reader;
-gr::buffer_reader_sptr
-gr::buffer_add_reader (gr::buffer_sptr buf, int nzero_preload, gr::block_sptr link);
-
-namespace gr {
-
- class gr::buffer
- {
- public:
- ~buffer();
-
- private:
- buffer(int nitems, size_t sizeof_item, gr::block_sptr link);
- };
-
- class gr::buffer_reader
- {
- public:
- ~buffer_reader();
-
- private:
- friend class buffer;
- buffer_reader(gr::buffer_sptr buffer, unsigned int read_index, gr::block_sptr link);
- };
-
- %rename(buffer_ncurrently_allocated) buffer_ncurrently_allocated;
- long buffer_ncurrently_allocated();
-
- %rename(buffer_reader_ncurrently_allocated) buffer_reader_ncurrently_allocated;
- long buffer_reader_ncurrently_allocated();
-}
diff --git a/gnuradio-runtime/swig/constants.i b/gnuradio-runtime/swig/constants.i
deleted file mode 100644
index 9b7b9610c7..0000000000
--- a/gnuradio-runtime/swig/constants.i
+++ /dev/null
@@ -1,20 +0,0 @@
-/* -*- c++ -*- */
-
-namespace gr {
- %rename(prefix) prefix;
- %rename(sysconfdir) sysconfdir;
- %rename(prefsdir) prefsdir;
- %rename(build_date) build_date;
- %rename(version) version;
- %rename(version_info) version_info;
-
- const std::string prefix();
- const std::string sysconfdir();
- const std::string prefsdir();
- const std::string build_date();
- const std::string version();
- const std::string major_version();
- const std::string api_version();
- const std::string minor_version();
-
-}
diff --git a/gnuradio-runtime/swig/feval.i b/gnuradio-runtime/swig/feval.i
deleted file mode 100644
index 697417d322..0000000000
--- a/gnuradio-runtime/swig/feval.i
+++ /dev/null
@@ -1,86 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2006,2010,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-
-/*
- * N.B., this is a _very_ non-standard SWIG .i file
- *
- * It contains a bunch of magic that is required to ensure that when
- * these classes are used as base classes for python code,
- * everything works when calling back from C++ into Python.
- *
- * The gist of the problem is that our C++ code is usually not holding
- * the Python Global Interpreter Lock (GIL). Thus if we invoke a
- * "director" method from C++, we'll end up in Python not holding the
- * GIL. Disaster (SIGSEGV) will result. To avoid this we insert a
- * "shim" that grabs and releases the GIL.
- *
- * If you don't understand SWIG "directors" or the Python GIL,
- * don't bother trying to understand what's going on in here.
- *
- * [We could eliminate a bunch of this hair by requiring SWIG 1.3.29
- * or later and some additional magic declarations, but many systems
- * aren't shipping that version yet. Thus we kludge...]
- */
-
-// Directors are only supported in Python, Java and C#
-#ifdef SWIGPYTHON
-
-%import "pmt_swig.i"
-
- // Enable SWIG directors for these classes
-%feature("director") gr::py_feval_dd;
-%feature("director") gr::py_feval_cc;
-%feature("director") gr::py_feval_ll;
-%feature("director") gr::py_feval;
-%feature("director") gr::py_feval_p;
-
-%feature("nodirector") gr::py_feval_dd::calleval;
-%feature("nodirector") gr::py_feval_cc::calleval;
-%feature("nodirector") gr::py_feval_ll::calleval;
-%feature("nodirector") gr::py_feval::calleval;
-%feature("nodirector") gr::py_feval_p::calleval;
-
-//%exception {
-// try { $action }
-// catch (Swig::DirectorException &e) { std::cerr << e.getMessage(); SWIG_fail; }
-//}
-
-%ignore gr::feval_dd;
-%ignore gr::feval_cc;
-%ignore gr::feval_ll;
-%ignore gr::feval;
-%ignore gr::feval_p;
-
-%include <gnuradio/feval.h>
-
-/*
- * These are the ones to derive from in Python. They have the magic shim
- * that ensures that we're holding the Python GIL when we enter Python land...
- */
-namespace gr {
- %rename(feval_dd) py_feval_dd;
- %rename(feval_cc) py_feval_cc;
- %rename(feval_ll) py_feval_ll;
- %rename(feval) py_feval;
- %rename(feval_p) py_feval_p;
-}
-
-%include <gnuradio/py_feval.h>
-
-namespace gr {
- // examples / test cases
- %rename(feval_dd_example) gr::feval_dd_example;
- %rename(feval_cc_example) gr::feval_cc_example;
- %rename(feval_ll_example) gr::feval_ll_example;
- %rename(feval_example) gr::feval_example;
-}
-
-#endif // SWIGPYTHON
diff --git a/gnuradio-runtime/swig/gnuradio.i b/gnuradio-runtime/swig/gnuradio.i
deleted file mode 100644
index 55db0cf30d..0000000000
--- a/gnuradio-runtime/swig/gnuradio.i
+++ /dev/null
@@ -1,70 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2003,2004,2009,2012,2019 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-// Disable warning about base class types
-#pragma SWIG nowarn=401
-
-////////////////////////////////////////////////////////////////////////
-// gnuradio.i
-// SWIG interface definition
-////////////////////////////////////////////////////////////////////////
-
-%include "std_string.i"
-%include <gr_extras.i>
-
-#ifdef SW_RUNTIME
-%include <gr_types.i>
-#endif
-
-////////////////////////////////////////////////////////////////////////
-// Headers
-
-%feature("autodoc","1");
-
-// Required for a bug in SWIG 2.0.4 with GCC 4.6
-// see: http://sourceforge.net/p/swig/bugs/1187/
-%{
-#include <cstddef>
-%}
-
-// local file
-%include <gr_shared_ptr.i>
-%include <std_except.i>
-
-////////////////////////////////////////////////////////////////////////
-
-#ifndef SW_RUNTIME
-// import runtime_swig.i for all but sw_runtime, since it needs to %include
-%import <runtime_swig.i>
-%import <gr_types.i>
-#endif
-
-////////////////////////////////////////////////////////////////////////
-
-%{
-#include <gnuradio/block.h>
-#include <gnuradio/sync_block.h>
-#include <gnuradio/sync_decimator.h>
-#include <gnuradio/sync_interpolator.h>
-#include <gnuradio/tagged_stream_block.h>
-#include <gnuradio/block_gateway.h>
-#include <gnuradio/feval.h>
-#include <gnuradio/py_feval.h>
-#include <gnuradio/high_res_timer.h>
-%}
-
-%include <gnuradio/high_res_timer.h>
-
-////////////////////////////////////////////////////////////////////////
-// Python 2/3 compatibility
-
-%begin %{
-#define SWIG_PYTHON_CAST_MODE
-%}
diff --git a/gnuradio-runtime/swig/gr_ctrlport.i b/gnuradio-runtime/swig/gr_ctrlport.i
deleted file mode 100644
index f65030fd95..0000000000
--- a/gnuradio-runtime/swig/gr_ctrlport.i
+++ /dev/null
@@ -1,88 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#ifdef GR_CTRLPORT
-
-typedef uint32_t DisplayType;
-
-// DisplayType Plotting types
-const uint32_t DISPNULL = 0x0000;
-const uint32_t DISPTIME = 0x0001;
-const uint32_t DISPXY = 0x0002;
-const uint32_t DISPPSD = 0x0004;
-const uint32_t DISPSPEC = 0x0008;
-const uint32_t DISPRAST = 0x0010;
-
-// DisplayType Options
-const uint32_t DISPOPTCPLX = 0x0100;
-const uint32_t DISPOPTLOG = 0x0200;
-const uint32_t DISPOPTSTEM = 0x0400;
-const uint32_t DISPOPTSTRIP = 0x0800;
-const uint32_t DISPOPTSCATTER = 0x1000;
-
-enum priv_lvl_t {
- RPC_PRIVLVL_ALL = 0,
- RPC_PRIVLVL_MIN = 9,
- RPC_PRIVLVL_NONE = 10
-};
-
-enum KnobType {
- KNOBBOOL, KNOBCHAR, KNOBINT, KNOBFLOAT,
- KNOBDOUBLE, KNOBSTRING, KNOBLONG, KNOBVECBOOL,
- KNOBCOMPLEX, KNOBCOMPLEXD,
- KNOBVECCHAR, KNOBVECINT, KNOBVECFLOAT, KNOBVECDOUBLE,
- KNOBVECSTRING, KNOBVECLONG
-};
-
-%{
-#include <gnuradio/rpcserver_booter_base.h>
-#include <gnuradio/rpcserver_booter_aggregator.h>
-#include <gnuradio/pycallback_object.h>
-%}
-
-%include <gnuradio/rpcserver_booter_base.h>
-%include <gnuradio/rpcserver_booter_aggregator.h>
-%include <gnuradio/pycallback_object.h>
-
-// Declare this class here but without the nested templated class
-// inside (replaces include of rpcmanager.h)
-class GR_RUNTIME_API rpcmanager : public virtual rpcmanager_base
-{
- public:
- rpcmanager();
- ~rpcmanager();
-
- static rpcserver_booter_base* get();
-
- static void register_booter(rpcserver_booter_base* booter);
-};
-
-
-// Attach a new python callback method to Python function
-%extend pycallback_object {
- // Set a Python function object as a callback function
- // Note : PyObject *pyfunc is remapped with a typempap
- void activate(PyObject *pyfunc)
- {
- self->set_callback(pyfunc);
- Py_INCREF(pyfunc);
- }
-}
-
-%template(RPC_get_string) pycallback_object<std::string>;
-%template(RPC_get_int) pycallback_object<int>;
-%template(RPC_get_float) pycallback_object<float>;
-%template(RPC_get_double) pycallback_object<double>;
-%template(RPC_get_complex) pycallback_object<gr_complex>;
-%template(RPC_get_complexd) pycallback_object<gr_complexd>;
-%template(RPC_get_vector_float) pycallback_object<std::vector<float> >;
-%template(RPC_get_vector_gr_complex) pycallback_object<std::vector<gr_complex> >;
-
-#endif /* GR_CTRLPORT */
diff --git a/gnuradio-runtime/swig/gr_extras.i b/gnuradio-runtime/swig/gr_extras.i
deleted file mode 100644
index 5047572dba..0000000000
--- a/gnuradio-runtime/swig/gr_extras.i
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright 2011,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#ifndef GR_EXTRAS_I
-#define GR_EXTRAS_I
-
-////////////////////////////////////////////////////////////////////////
-// Language independent exception handler
-////////////////////////////////////////////////////////////////////////
-%include exception.i
-
-%exception {
- try {
- $action
- }
- catch(std::invalid_argument &e) {
- SWIG_exception(SWIG_TypeError, e.what());
- }
- catch(std::exception &e) {
- SWIG_exception(SWIG_RuntimeError, e.what());
- }
- catch(...) {
- SWIG_exception(SWIG_RuntimeError, "Unknown exception");
- }
-
-}
-
-////////////////////////////////////////////////////////////////////////
-// Wrapper for python calls that may block
-////////////////////////////////////////////////////////////////////////
-
-/*!
- * Use GR_PYTHON_BLOCKING_CODE when calling code that blocks.
- *
- * The try/catch is to save us from boost::thread::interrupt:
- * If a thread from the scheduler (or any other boost thread)
- * is blocking the routine and throws an interrupt exception.
- */
-%{
-
-#define GR_PYTHON_BLOCKING_CODE(code) { \
- PyThreadState *_save; \
- _save = PyEval_SaveThread(); \
- try{code} \
- catch(...){PyEval_RestoreThread(_save); throw;} \
- PyEval_RestoreThread(_save); \
-}
-
-%}
-
-#endif /*GR_EXTRAS_I*/
diff --git a/gnuradio-runtime/swig/gr_logger.i b/gnuradio-runtime/swig/gr_logger.i
deleted file mode 100644
index 7687cc8a46..0000000000
--- a/gnuradio-runtime/swig/gr_logger.i
+++ /dev/null
@@ -1,74 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2012,2019 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-/*******************************************************************************
-* Copyright 2011 Johns Hopkins University Applied Physics Lab
-* Author: Mark Plett
-* Description:
-* SWIG interface generator file for gr_logger module. gr_logger wraps log4cpp logging
-* for gnuradio.
-*******************************************************************************/
-
-%feature("autodoc", "1"); // generate python docstrings
-
-%include "exception.i"
-%import "gnuradio.i" // the common stuff
-
-%{
-#include <stdexcept>
-%}
-
-//-----------------------------------
-
-%{
-// The .h files
-#include <gnuradio/logger.h>
-%}
-
-%rename(logger) gr::logger;
-%rename(logger_config) gr_logger_config;
-%rename(logger_get_names) gr_logger_get_logger_names;
-%rename(logger_reset_config) gr_logger_reset_config;
-
-void gr_logger_config(const std::string config_filename,unsigned int watch_period = 0);
-std::vector<std::string> gr_logger_get_logger_names(void);
-void gr_logger_reset_config(void);
-
-namespace gr {
-
-// void logger_config(const std::string config_filename, unsigned int watch_period = 0);
-// std::vector<std::string> logger_get_logger_names(void);
-// void logger_reset_config(void);
-
- class logger
- {
- public:
- logger(std::string logger_name);
- void set_level(std::string level){LOG_SET_LEVEL(d_logger,level);}
- void get_level(std::string &level){LOG_GET_LEVEL(d_logger,level);}
- void debug(std::string msg){LOG_DEBUG(d_logger,msg);};
- void info(std::string msg){LOG_INFO(d_logger,msg);};
- void notice(std::string msg){LOG_NOTICE(d_logger,msg);};
- void warn(std::string msg){LOG_WARN(d_logger,msg);};
- void error(std::string msg){LOG_ERROR(d_logger,msg);};
- void crit(std::string msg){LOG_CRIT(d_logger,msg);};
- void alert(std::string msg){LOG_ALERT(d_logger,msg);};
- void fatal(std::string msg){LOG_FATAL(d_logger,msg);};
- void emerg(std::string msg){LOG_EMERG(d_logger,msg);};
- void errorIF(bool cond,std::string msg){LOG_ERRORIF(d_logger,cond,msg);};
- void log_assert(bool cond,std::string msg){LOG_ASSERT(d_logger,cond,msg);};
- void add_console_appender(std::string target,std::string pattern);
- void add_file_appender(std::string filename,bool append,std::string pattern);
- void add_rollingfile_appender(std::string filename, size_t filesize,
- int bkup_index, bool append, mode_t mode,
- std::string pattern);
- };
-
-} /* namespace gr */
diff --git a/gnuradio-runtime/swig/gr_shared_ptr.i b/gnuradio-runtime/swig/gr_shared_ptr.i
deleted file mode 100644
index 3e601038f5..0000000000
--- a/gnuradio-runtime/swig/gr_shared_ptr.i
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// shared_ptr
-//
-// An enhanced relative of scoped_ptr with reference counted copy semantics.
-// The object pointed to is deleted when the last shared_ptr pointing to it
-// is destroyed or reset.
-//
-
-//
-// This is highly hacked up version of std::shared_ptr
-// We just need enough to get SWIG to "do the right thing" and
-// generate "Smart Pointer" code.
-//
-
-namespace std {
-
-template<class T> class shared_ptr
-{
-public:
-
- shared_ptr()
- {
- }
-
- shared_ptr (T * p)
- {
- }
-
-
- T * operator-> () // never throws
- {
- return px;
- }
-
-
-private:
-
- T * px; // contained pointer
- int pn;
-
-}; // shared_ptr
-
-}; \ No newline at end of file
diff --git a/gnuradio-runtime/swig/gr_swig_block_magic.i b/gnuradio-runtime/swig/gr_swig_block_magic.i
deleted file mode 100644
index 82f79b5e76..0000000000
--- a/gnuradio-runtime/swig/gr_swig_block_magic.i
+++ /dev/null
@@ -1,56 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2010,2012,2018 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-%define GR_SWIG_BLOCK_MAGIC(PKG, BASE_NAME)
-_GR_SWIG_BLOCK_MAGIC_HELPER(PKG, BASE_NAME, PKG ## _ ## BASE_NAME)
-%enddef
-
-%define _GR_SWIG_BLOCK_MAGIC_HELPER_COMMON(PKG, BASE_NAME, FULL_NAME)
-class FULL_NAME;
-typedef std::shared_ptr<FULL_NAME> FULL_NAME ## _sptr;
-%template(FULL_NAME ## _sptr) std::shared_ptr<FULL_NAME>;
-%rename(BASE_NAME) PKG ## _make_ ## BASE_NAME;
-%ignore FULL_NAME;
-%enddef
-
-#ifdef SWIGPYTHON
-%define _GR_SWIG_BLOCK_MAGIC_HELPER(PKG, BASE_NAME, FULL_NAME)
-_GR_SWIG_BLOCK_MAGIC_HELPER_COMMON(PKG, BASE_NAME, FULL_NAME)
-%pythoncode %{
-FULL_NAME ## _sptr.__repr__ = lambda self: "<gr_block %s (%d)>" % (self.name(), self.unique_id ())
-%}
-%enddef
-#endif
-
-%define GR_SWIG_BLOCK_MAGIC2(PKG, BASE_NAME)
-%template(BASE_NAME ## _sptr) std::shared_ptr<gr:: ## PKG ## :: ## BASE_NAME>;
-%pythoncode %{
-BASE_NAME ## _sptr.__repr__ = lambda self: "<gr_block %s (%d)>" % (self.name(), self.unique_id())
-BASE_NAME = BASE_NAME.make;
-%}
-%enddef
-
-%define GR_SWIG_BLOCK_MAGIC2_TMPL(PKG, BASE_NAME, TARGET_NAME...)
-%template(BASE_NAME) gr:: ## PKG ## :: ## TARGET_NAME;
-%template(BASE_NAME ## _sptr) std::shared_ptr<gr:: ## PKG ## :: ## TARGET_NAME ## >;
-%pythoncode %{
-BASE_NAME ## _sptr.__repr__ = lambda self: "<gr_block %s (%d)>" % (self.name(), self.unique_id())
-BASE_NAME = BASE_NAME.make
-%}
-%enddef
-
-
-%define GR_SWIG_BLOCK_MAGIC_FACTORY(PKG, BASE_NAME, FACTORY)
-%template(FACTORY ## _sptr) std::shared_ptr<gr:: ## PKG ## :: ## BASE_NAME>;
-%pythoncode %{
-FACTORY ## _sptr.__repr__ = lambda self: "<gr_block %s (%d)>" % (self.name(), self.unique_id())
-FACTORY = BASE_NAME ## _make_ ## FACTORY;
-%}
-%enddef
diff --git a/gnuradio-runtime/swig/gr_types.i b/gnuradio-runtime/swig/gr_types.i
deleted file mode 100644
index 8fbc597e76..0000000000
--- a/gnuradio-runtime/swig/gr_types.i
+++ /dev/null
@@ -1,86 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#ifndef SWIG_GR_TYPES_I
-#define SWIG_GR_TYPES_I
-
-%include "stdint.i"
-
-%{
-#include <memory>
-#include <boost/any.hpp>
-#include <complex>
-#include <string>
-#include <stddef.h> // size_t
-#include <stdint.h>
-#include <gnuradio/types.h>
-%}
-
-%include <std_complex.i>
-%include <std_vector.i>
-%include <stl.i>
-
-typedef std::complex<float> gr_complex;
-typedef std::complex<double> gr_complexd;
-typedef unsigned long long uint64_t;
-typedef long long int64_t;
-
-namespace std {
- %template() vector<unsigned char>;
- %template() vector<signed char>;
- %template() vector<char>;
-
- %template() vector<unsigned short>;
- %template() vector<short>;
-
- %template() vector<int>;
- %template() vector<unsigned int>;
-
- %template() vector<long int>;
- %template() vector<long unsigned int>;
-
- %template() vector<float>;
- %template() vector<double>;
-
- %template() vector< vector< unsigned char > >;
- %template() vector< vector< char > >;
- %template() vector< vector< short > >;
- %template() vector< vector< int > >;
- %template() vector< vector< long int> >;
- %template() vector< vector< float > >;
- %template() vector< vector< double > >;
-
- %template() vector<string>;
-
- %template(gr_vsize_t) std::vector<size_t>;
- %template(gr_vvvsize_t) std::vector< std::vector< std::vector<size_t> > >;
-};
-
-%template(gr_vector_complexf) std::vector< std::complex<float> >;
-%template(gr_vector_complexd) std::vector< std::complex<double> >;
-%template(gr_vector_vector_complexf) std::vector< std::vector< std::complex<float> > >;
-%template(gr_vector_vector_complexd) std::vector< std::vector< std::complex<double> > >;
-
-// Fix for Issue #529: replace std::vector<size_t> with its equivalent
-// in element size, one of "unsigned int", "unsigned long", or
-// "unsigned long long". The replacement depends on the sizeof each
-// type, as determined in GrSwig.cmake GR_SWIG_MAKE. For SWIG >=
-// 3.0.0, none of these will be defined because this issue seems to
-// have been fixed.
-
-#if defined(SIZE_T_UINT)
- %apply std::vector<unsigned int> { std::vector<size_t> };
-#elif defined(SIZE_T_UL)
- %apply std::vector<unsigned long> { std::vector<size_t> };
-#elif defined(SIZE_T_ULL)
- %apply std::vector<unsigned long long> { std::vector<size_t> };
-#endif
-
-#endif /* SWIG_GR_TYPES_I */
diff --git a/gnuradio-runtime/swig/hier_block2.i b/gnuradio-runtime/swig/hier_block2.i
deleted file mode 100644
index 0b21870c5c..0000000000
--- a/gnuradio-runtime/swig/hier_block2.i
+++ /dev/null
@@ -1,97 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005-2007,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-%include <basic_block.i>
-
-class gr::hier_block2;
-typedef std::shared_ptr<gr::hier_block2> gr::hier_block2_sptr;
-%template(hier_block2_sptr) std::shared_ptr<gr::hier_block2>;
-
-namespace gr {
- // Hack to have a Python shim implementation of gr.hier_block2
- // that instantiates one of these and passes through calls
- %rename(hier_block2_swig) make_hier_block2;
- gr::hier_block2_sptr
- make_hier_block2(const std::string name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature)
- noexcept(false);
-}
-
-// Rename connect and disconnect so that we can more easily build a
-// better interface in scripting land.
-%rename(primitive_connect) gr::hier_block2::connect;
-%rename(primitive_disconnect) gr::hier_block2::disconnect;
-%rename(primitive_msg_connect) gr::hier_block2::msg_connect;
-%rename(primitive_msg_disconnect) gr::hier_block2::msg_disconnect;
-%rename(primitive_message_port_register_hier_in) gr::hier_block2::message_port_register_hier_in;
-%rename(primitive_message_port_register_hier_out) gr::hier_block2::message_port_register_hier_out;
-
-namespace gr {
- class hier_block2 : public gr::basic_block
- {
- private:
- hier_block2(const std::string name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature);
-
- public:
- ~hier_block2 ();
-
- void connect(gr::basic_block_sptr block)
- noexcept(false);
- void connect(gr::basic_block_sptr src, int src_port,
- gr::basic_block_sptr dst, int dst_port)
- noexcept(false);
- void msg_connect(gr::basic_block_sptr src, pmt::pmt_t srcport,
- gr::basic_block_sptr dst, pmt::pmt_t dstport)
- noexcept(false);
- void msg_connect(gr::basic_block_sptr src, std::string srcport,
- gr::basic_block_sptr dst, std::string dstport)
- noexcept(false);
- void msg_disconnect(gr::basic_block_sptr src, pmt::pmt_t srcport,
- gr::basic_block_sptr dst, pmt::pmt_t dstport)
- noexcept(false);
- void msg_disconnect(gr::basic_block_sptr src, std::string srcport,
- gr::basic_block_sptr dst, std::string dstport)
- noexcept(false);
-
- void disconnect(gr::basic_block_sptr block)
- noexcept(false);
- void disconnect(gr::basic_block_sptr src, int src_port,
- gr::basic_block_sptr dst, int dst_port)
- noexcept(false);
- void disconnect_all();
- void lock();
- void unlock();
-
- void message_port_register_hier_in(pmt::pmt_t port_id);
- void message_port_register_hier_out(pmt::pmt_t port_id);
-
- void set_processor_affinity(const std::vector<int> &mask);
- void unset_processor_affinity();
- std::vector<int> processor_affinity();
-
- void set_log_level(std::string level);
- std::string log_level();
-
- // Methods to manage block's min/max buffer sizes.
- size_t max_output_buffer(int i);
- void set_max_output_buffer(size_t max_output_buffer);
- void set_max_output_buffer(int port, size_t max_output_buffer);
- size_t min_output_buffer(int i);
- void set_min_output_buffer(size_t min_output_buffer);
- void set_min_output_buffer(int port, size_t min_output_buffer);
-
- gr::hier_block2_sptr to_hier_block2(); // Needed for Python type coercion
- };
-
- std::string dot_graph(hier_block2_sptr hierblock2);
-}
diff --git a/gnuradio-runtime/swig/io_signature.i b/gnuradio-runtime/swig/io_signature.i
deleted file mode 100644
index 7fc029fc07..0000000000
--- a/gnuradio-runtime/swig/io_signature.i
+++ /dev/null
@@ -1,57 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2005,2007,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-namespace gr {
-
- class GR_RUNTIME_API io_signature
- {
- io_signature(int min_streams, int max_streams,
- const std::vector<int> &sizeof_stream_items);
-
- public:
- typedef std::shared_ptr<io_signature> sptr;
-
- // Avoids a swig warning, otherwise we could just
- // #include <gnuradio/io_signature.h> instead of redoing this
- // #entire class
- //static const int IO_INFINITE = -1;
-
- ~io_signature();
-
-
- static sptr make(int min_streams, int max_streams,
- int sizeof_stream_item);
- static sptr make2(int min_streams, int max_streams,
- int sizeof_stream_item1,
- int sizeof_stream_item2);
- static sptr make3(int min_streams, int max_streams,
- int sizeof_stream_item1,
- int sizeof_stream_item2,
- int sizeof_stream_item3);
- static sptr makev(int min_streams, int max_streams,
- const std::vector<int> &sizeof_stream_items);
-
- int min_streams() const { return d_min_streams; }
- int max_streams() const { return d_max_streams; }
- int sizeof_stream_item(int index) const;
- std::vector<int> sizeof_stream_items() const;
- };
-
-} /* namespace gr */
-
-
-%template(io_signature_sptr) std::shared_ptr<gr::io_signature>;
-%pythoncode %{
-io_signature_sptr.__repr__ = lambda self: "<io_signature: %d, %d>" % (self.min_streams(), self.max_streams())
-io_signaturev = io_signature.makev;
-io_signature3 = io_signature.make3;
-io_signature2 = io_signature.make2;
-io_signature = io_signature.make;
-%}
diff --git a/gnuradio-runtime/swig/message.i b/gnuradio-runtime/swig/message.i
deleted file mode 100644
index 4265d3a9ab..0000000000
--- a/gnuradio-runtime/swig/message.i
+++ /dev/null
@@ -1,66 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-namespace gr {
-
- %pythonappend message::to_string %{
- import sys
- if sys.version_info[0] > 2:
- val = val.encode("utf8", errors="surrogateescape")
- %}
-
- /*!
- * \brief Message.
- *
- * The ideas and method names for adjustable message length were
- * lifted from the click modular router "Packet" class.
- */
- class message
- {
- public:
- typedef std::shared_ptr<message> sptr;
-
- private:
- message(long type, double arg1, double arg2, size_t length);
-
- unsigned char *buf_data() const;
- size_t buf_len() const;
-
- public:
- static sptr make(long type = 0, double arg1 = 0, double arg2 = 0, size_t length = 0);
-
- static sptr make_from_string(const std::string s, long type = 0,
- double arg1 = 0, double arg2 = 0);
-
- ~message();
-
- long type() const;
- double arg1() const;
- double arg2() const;
-
- void set_type(long type);
- void set_arg1(double arg1);
- void set_arg2(double arg2);
-
- size_t length() const;
- std::string to_string() const;
- };
-
- %rename(message_ncurrently_allocated) message_ncurrently_allocated;
- long message_ncurrently_allocated();
-}
-
-
-
-%template(message_sptr) std::shared_ptr<gr::message>;
-%pythoncode %{
-message_from_string = message.make_from_string
-message = message.make
-%}
diff --git a/gnuradio-runtime/swig/msg_handler.i b/gnuradio-runtime/swig/msg_handler.i
deleted file mode 100644
index ab4c2c3ed3..0000000000
--- a/gnuradio-runtime/swig/msg_handler.i
+++ /dev/null
@@ -1,21 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-/*!
- * \brief abstract class of message handlers
- */
-class gr::msg_handler
-{
-public:
- virtual ~msg_handler () = 0;
-
- //! handle \p msg
- virtual void handle(gr::message::sptr msg) = 0;
-};
diff --git a/gnuradio-runtime/swig/msg_queue.i b/gnuradio-runtime/swig/msg_queue.i
deleted file mode 100644
index 20ca9d16ef..0000000000
--- a/gnuradio-runtime/swig/msg_queue.i
+++ /dev/null
@@ -1,96 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2009-2011,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-namespace gr {
- /*!
- * \brief thread-safe message queue
- */
- class msg_queue : public gr::msg_handler
- {
- public:
- typedef std::shared_ptr<msg_queue> sptr;
-
- static sptr make(unsigned int limit=0);
-
- msg_queue(unsigned int limit);
- ~msg_queue();
-
- //! Generic msg_handler method: insert the message.
- //void handle(gr::message::sptr msg) { insert_tail (msg); }
-
- /*!
- * \brief Insert message at tail of queue.
- * \param msg message
- *
- * Block if queue if full.
- */
- //void insert_tail(gr::message::sptr msg);
-
- /*!
- * \brief Delete message from head of queue and return it.
- * Block if no message is available.
- */
- //gr::message::sptr delete_head();
-
- /*!
- * \brief If there's a message in the q, delete it and return it.
- * If no message is available, return 0.
- */
- gr::message::sptr delete_head_nowait();
-
- //! is the queue empty?
- bool empty_p() const;
-
- //! is the queue full?
- bool full_p() const;
-
- //! return number of messages in queue
- unsigned int count() const;
-
- //! Delete all messages from the queue
- void flush();
- };
-}
-
-/*
- * The following kludge-o-rama releases the Python global interpreter
- * lock around these potentially blocking calls. We don't want
- * libgnuradio-runtime to be dependent on Python, thus we create these
- * functions that serve as replacements for the normal C++ delete_head
- * and insert_tail methods. The %pythoncode smashes these new C++
- * functions into the gr.msg_queue wrapper class, so that everything
- * appears normal. (An evil laugh is heard in the distance...)
- */
-#ifdef SWIGPYTHON
-%inline %{
- gr::message::sptr py_msg_queue__delete_head(gr::msg_queue::sptr q) {
- gr::message::sptr msg;
- GR_PYTHON_BLOCKING_CODE(
- msg = q->delete_head();
- )
- return msg;
- }
-
- void py_msg_queue__insert_tail(gr::msg_queue::sptr q, gr::message::sptr msg) {
- GR_PYTHON_BLOCKING_CODE(
- q->insert_tail(msg);
- )
- }
-%}
-
-// smash in new python delete_head and insert_tail methods...
-%template(msg_queue_sptr) std::shared_ptr<gr::msg_queue>;
-%pythoncode %{
-msg_queue_sptr.delete_head = py_msg_queue__delete_head
-msg_queue_sptr.insert_tail = py_msg_queue__insert_tail
-msg_queue_sptr.handle = py_msg_queue__insert_tail
-msg_queue = msg_queue.make
-%}
-#endif // SWIGPYTHON
diff --git a/gnuradio-runtime/swig/pmt_swig.i b/gnuradio-runtime/swig/pmt_swig.i
deleted file mode 100644
index c830590129..0000000000
--- a/gnuradio-runtime/swig/pmt_swig.i
+++ /dev/null
@@ -1,325 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2011-2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#pragma SWIG nowarn=401
-
-%include "std_string.i"
-%include "stdint.i"
-
-%{
-#include <memory>
-#include <boost/any.hpp>
-#include <complex>
-#include <string>
-#include <stddef.h> // size_t
-#include <stdint.h>
-#include <iosfwd>
-#include <stdexcept>
-#include <pmt/pmt.h>
-
-namespace pmt {
- // Wrapper for serialize_str(), so we always have raw byte strings
- std::vector<uint8_t> _serialize_str_u8(pmt_t obj)
- {
- std::string serialized_str(serialize_str(obj));
- return std::vector<uint8_t>(serialized_str.begin(), serialized_str.end());
- }
-
- // Wrapper for deserialize_str(), so we always have raw byte strings
- pmt_t _deserialize_str_u8(std::vector<uint8_t> py_str)
- {
- std::string cpp_str(py_str.begin(), py_str.end());
- return deserialize_str(cpp_str);
- }
-} /* namespace pmt */
-
-%}
-
-%feature("autodoc","1");
-
-//load generated python docstrings
-%include "pmt_swig_doc.i"
-
-%include <gr_extras.i>
-
-%include <std_complex.i>
-%include <std_vector.i>
-%include <gr_shared_ptr.i>
-%template(pmt_vector_int8) std::vector<int8_t>;
-%template(pmt_vector_uint8) std::vector<uint8_t>;
-%template(pmt_vector_int16) std::vector<int16_t>;
-%template(pmt_vector_uint16) std::vector<uint16_t>;
-%template(pmt_vector_int32) std::vector<int32_t>;
-%template(pmt_vector_uint32) std::vector<uint32_t>;
-%template(pmt_vector_float) std::vector<float>;
-%template(pmt_vector_double) std::vector<double>;
-%template(pmt_vector_cfloat) std::vector< std::complex<float> >;
-%template(pmt_vector_cdouble) std::vector< std::complex<double> >;
-
-////////////////////////////////////////////////////////////////////////
-// Language independent exception handler
-////////////////////////////////////////////////////////////////////////
-
-%template(swig_pmt_ptr) std::shared_ptr<pmt::pmt_base>;
-
-namespace pmt{
- class pmt_base;
- typedef std::shared_ptr<pmt::pmt_base> pmt_t;
-
- %pythoncode
- %{
- swig_pmt_ptr.__repr__ = lambda self: write_string(self)
- %}
-
- pmt_t get_PMT_NIL();
- pmt_t get_PMT_T();
- pmt_t get_PMT_F();
- pmt_t get_PMT_EOF();
-
- #define PMT_NIL get_PMT_NIL()
- #define PMT_T get_PMT_T()
- #define PMT_F get_PMT_F()
- #define PMT_EOF get_PMT_EOF()
-
- bool is_bool(pmt_t obj);
- bool is_true(pmt_t obj);
- bool is_false(pmt_t obj);
- pmt_t from_bool(bool val);
- bool to_bool(pmt_t val);
-
- bool is_symbol(const pmt_t& obj);
- pmt_t string_to_symbol(const std::string &s);
- pmt_t intern(const std::string &s);
- const std::string symbol_to_string(const pmt_t& sym);
-
- bool is_number(pmt_t obj);
- bool is_integer(pmt_t x);
- pmt_t from_long(long x);
- long to_long(pmt_t x);
-
- bool is_uint64(pmt_t x);
- pmt_t from_uint64(uint64_t x);
- uint64_t to_uint64(pmt_t x);
-
- bool is_real(pmt_t obj);
- pmt_t from_double(double x);
- double to_double(pmt_t x);
- pmt_t from_float(double x);
- double to_float(pmt_t x);
-
- bool is_complex(pmt_t obj);
- pmt_t make_rectangular(double re, double im);
- pmt_t from_complex(const std::complex<double> &z);
- std::complex<double> to_complex(pmt_t z);
-
- bool is_null(const pmt_t& x);
- bool is_pair(const pmt_t& obj);
- pmt_t cons(const pmt_t& x, const pmt_t& y);
- pmt_t car(const pmt_t& pair);
- pmt_t cdr(const pmt_t& pair);
- void set_car(pmt_t pair, pmt_t value);
- void set_cdr(pmt_t pair, pmt_t value);
-
- pmt_t caar(pmt_t pair);
- pmt_t cadr(pmt_t pair);
- pmt_t cdar(pmt_t pair);
- pmt_t cddr(pmt_t pair);
- pmt_t caddr(pmt_t pair);
- pmt_t cadddr(pmt_t pair);
-
- bool is_tuple(pmt_t x);
- pmt_t make_tuple();
- pmt_t make_tuple(const pmt_t &e0);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3, const pmt_t &e4);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3, const pmt_t &e4, const pmt_t &e5);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3, const pmt_t &e4, const pmt_t &e5, const pmt_t &e6);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3, const pmt_t &e4, const pmt_t &e5, const pmt_t &e6, const pmt_t &e7);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3, const pmt_t &e4, const pmt_t &e5, const pmt_t &e6, const pmt_t &e7, const pmt_t &e8);
- pmt_t make_tuple(const pmt_t &e0, const pmt_t &e1, const pmt_t &e2, const pmt_t &e3, const pmt_t &e4, const pmt_t &e5, const pmt_t &e6, const pmt_t &e7, const pmt_t &e8, const pmt_t &e9);
-
- pmt_t to_tuple(const pmt_t &x);
- pmt_t tuple_ref(const pmt_t &tuple, size_t k);
-
- bool is_vector(pmt_t x);
- pmt_t make_vector(size_t k, pmt_t fill);
- pmt_t vector_ref(pmt_t vector, size_t k);
- void vector_set(pmt_t vector, size_t k, pmt_t obj);
- void vector_fill(pmt_t vector, pmt_t fill);
-
- bool is_blob(pmt_t x);
- pmt_t make_blob(const void *buf, size_t len);
- const void *blob_data(pmt_t blob);
- size_t blob_length(pmt_t blob);
-
- bool is_uniform_vector(pmt_t x);
- bool is_u8vector(pmt_t x);
- bool is_s8vector(pmt_t x);
- bool is_u16vector(pmt_t x);
- bool is_s16vector(pmt_t x);
- bool is_u32vector(pmt_t x);
- bool is_s32vector(pmt_t x);
- bool is_u64vector(pmt_t x);
- bool is_s64vector(pmt_t x);
- bool is_f32vector(pmt_t x);
- bool is_f64vector(pmt_t x);
- bool is_c32vector(pmt_t x);
- bool is_c64vector(pmt_t x);
- size_t uniform_vector_itemsize(pmt_t x);
- pmt_t make_u8vector(size_t k, uint8_t fill);
- pmt_t make_s8vector(size_t k, int8_t fill);
- pmt_t make_u16vector(size_t k, uint16_t fill);
- pmt_t make_s16vector(size_t k, int16_t fill);
- pmt_t make_u32vector(size_t k, uint32_t fill);
- pmt_t make_s32vector(size_t k, int32_t fill);
- pmt_t make_u64vector(size_t k, uint64_t fill);
- pmt_t make_s64vector(size_t k, int64_t fill);
- pmt_t make_f32vector(size_t k, float fill);
- pmt_t make_f64vector(size_t k, double fill);
- pmt_t make_c32vector(size_t k, std::complex<float> fill);
- pmt_t make_c64vector(size_t k, std::complex<double> fill);
- pmt_t init_u8vector(size_t k, const std::vector<uint8_t> &data);
- pmt_t init_s8vector(size_t k, const std::vector<int8_t> &data);
- pmt_t init_u16vector(size_t k, const std::vector<uint16_t> &data);
- pmt_t init_s16vector(size_t k, const std::vector<int16_t> &data);
- pmt_t init_u32vector(size_t k, const std::vector<uint32_t> &data);
- pmt_t init_s32vector(size_t k, const std::vector<int32_t> &data);
- pmt_t init_f32vector(size_t k, const std::vector<float> &data);
- pmt_t init_f64vector(size_t k, const std::vector<double> &data);
- pmt_t init_c32vector(size_t k, const std::vector<std::complex<float> > &data);
- pmt_t init_c64vector(size_t k, const std::vector<std::complex<double> > &data);
- uint8_t u8vector_ref(pmt_t v, size_t k);
- int8_t s8vector_ref(pmt_t v, size_t k);
- uint16_t u16vector_ref(pmt_t v, size_t k);
- int16_t s16vector_ref(pmt_t v, size_t k);
- uint32_t u32vector_ref(pmt_t v, size_t k);
- int32_t s32vector_ref(pmt_t v, size_t k);
- uint64_t u64vector_ref(pmt_t v, size_t k);
- int64_t s64vector_ref(pmt_t v, size_t k);
- float f32vector_ref(pmt_t v, size_t k);
- double f64vector_ref(pmt_t v, size_t k);
- std::complex<float> c32vector_ref(pmt_t v, size_t k);
- std::complex<double> c64vector_ref(pmt_t v, size_t k);
- void u8vector_set(pmt_t v, size_t k, uint8_t x); //< v[k] = x
- void s8vector_set(pmt_t v, size_t k, int8_t x);
- void u16vector_set(pmt_t v, size_t k, uint16_t x);
- void s16vector_set(pmt_t v, size_t k, int16_t x);
- void u32vector_set(pmt_t v, size_t k, uint32_t x);
- void s32vector_set(pmt_t v, size_t k, int32_t x);
- void u64vector_set(pmt_t v, size_t k, uint64_t x);
- void s64vector_set(pmt_t v, size_t k, int64_t x);
- void f32vector_set(pmt_t v, size_t k, float x);
- void f64vector_set(pmt_t v, size_t k, double x);
- void c32vector_set(pmt_t v, size_t k, std::complex<float> x);
- void c64vector_set(pmt_t v, size_t k, std::complex<double> x);
-
- %apply size_t & INOUT { size_t &len };
- const void *uniform_vector_elements(pmt_t v, size_t &len);
-
- const std::vector<uint8_t> u8vector_elements(pmt_t v);
- const std::vector<int8_t> s8vector_elements(pmt_t v);
- const std::vector<uint16_t> u16vector_elements(pmt_t v);
- const std::vector<int16_t> s16vector_elements(pmt_t v);
- const std::vector<uint32_t> u32vector_elements(pmt_t v);
- const std::vector<int32_t> s32vector_elements(pmt_t v);
- const std::vector<float> f32vector_elements(pmt_t v);
- const std::vector<double> f64vector_elements(pmt_t v);
- const std::vector<std::complex<float> > c32vector_elements(pmt_t v);
- const std::vector<std::complex<double> > c64vector_elements(pmt_t v);
-
- bool is_dict(const pmt_t &obj);
- pmt_t make_dict();
- pmt_t dcons(const pmt_t& x, const pmt_t& y);
- pmt_t dict_add(const pmt_t &dict, const pmt_t &key, const pmt_t &value);
- pmt_t dict_delete(const pmt_t &dict, const pmt_t &key);
- bool dict_has_key(const pmt_t &dict, const pmt_t &key);
- pmt_t dict_ref(const pmt_t &dict, const pmt_t &key, const pmt_t &not_found);
- pmt_t dict_items(pmt_t dict);
- pmt_t dict_keys(pmt_t dict);
- pmt_t dict_update(const pmt_t &dict1, const pmt_t &dict2);
- pmt_t dict_values(pmt_t dict);
-
- bool is_any(pmt_t obj);
- pmt_t make_any(const boost::any &any);
- boost::any any_ref(pmt_t obj);
- void any_set(pmt_t obj, const boost::any &any);
-
- bool is_msg_accepter(const pmt_t &obj);
- pmt_t make_msg_accepter(std::shared_ptr<gr::messages::msg_accepter> ma);
- std::shared_ptr<gr::messages::msg_accepter> msg_accepter_ref(const pmt_t &obj);
-
- bool is_pdu(const pmt_t& obj);
- bool eq(const pmt_t& x, const pmt_t& y);
- bool eqv(const pmt_t& x, const pmt_t& y);
- bool equal(const pmt_t& x, const pmt_t& y);
- size_t length(const pmt_t& v);
- pmt_t assq(pmt_t obj, pmt_t alist);
- pmt_t assv(pmt_t obj, pmt_t alist);
- pmt_t assoc(pmt_t obj, pmt_t alist);
- pmt_t map(pmt_t proc(const pmt_t&), pmt_t list);
- pmt_t reverse(pmt_t list);
- pmt_t reverse_x(pmt_t list);
- inline static pmt_t acons(pmt_t x, pmt_t y, pmt_t a);
- pmt_t nth(size_t n, pmt_t list);
- pmt_t nthcdr(size_t n, pmt_t list);
- pmt_t memq(pmt_t obj, pmt_t list);
- pmt_t memv(pmt_t obj, pmt_t list);
- pmt_t member(pmt_t obj, pmt_t list);
- bool subsetp(pmt_t list1, pmt_t list2);
-
- pmt_t list1(const pmt_t& x1);
- pmt_t list2(const pmt_t& x1, const pmt_t& x2);
- pmt_t list3(const pmt_t& x1, const pmt_t& x2, const pmt_t& x3);
- pmt_t list4(const pmt_t& x1, const pmt_t& x2, const pmt_t& x3, const pmt_t& x4);
- pmt_t list5(const pmt_t& x1, const pmt_t& x2, const pmt_t& x3, const pmt_t& x4, const pmt_t& x5);
- pmt_t list6(const pmt_t& x1, const pmt_t& x2, const pmt_t& x3, const pmt_t& x4, const pmt_t& x5, const pmt_t& x6);
- pmt_t list_add(pmt_t list, const pmt_t& item);
- pmt_t list_rm(pmt_t list, const pmt_t& item);
- bool list_has(pmt_t list, const pmt_t& item);
-
- bool is_eof_object(pmt_t obj);
- pmt_t read(std::istream &port);
- void write(pmt_t obj, std::ostream &port);
- std::string write_string(pmt_t obj);
-
- //void pmt_print(pmt_t v);
-
- bool serialize(pmt_t obj, std::streambuf &sink);
- pmt_t deserialize(std::streambuf &source);
- void dump_sizeof();
-
- std::vector<uint8_t> _serialize_str_u8(pmt_t obj);
- pmt_t _deserialize_str_u8(std::vector<uint8_t> py_str);
-
- %rename(_serialize_str) serialize_str;
- std::string serialize_str(pmt_t obj);
-
- %rename(_deserialize_str) deserialize_str;
- pmt_t deserialize_str(std::string str);
-
-} //namespace pmt
-
-%pythoncode %{
- def serialize_str(pmt_obj):
- import sys
- if sys.version_info.major == 2:
- return _serialize_str(pmt_obj)
- import array
- return array.array('B', _serialize_str_u8(pmt_obj)).tobytes()
-
- def deserialize_str(pmt_str):
- import sys
- if sys.version_info.major == 2:
- return _deserialize_str(pmt_str)
- return _deserialize_str_u8(tuple(x for x in pmt_str))
-
-%}
diff --git a/gnuradio-runtime/swig/prefs.i b/gnuradio-runtime/swig/prefs.i
deleted file mode 100644
index ece0b689df..0000000000
--- a/gnuradio-runtime/swig/prefs.i
+++ /dev/null
@@ -1,51 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2006,2015 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::prefs
-{
-public:
- static gr::prefs *singleton();
-
- void add_config_file(const std::string &configfile);
-
- virtual ~prefs();
-
- std::string to_string();
-
- void save();
-
- virtual bool has_section(const std::string &section);
- virtual bool has_option(const std::string &section, const std::string &option);
-
- virtual const std::string get_string(const std::string &section,
- const std::string &option,
- const std::string &default_val);
- virtual void set_string(const std::string &section,
- const std::string &option,
- const std::string &val);
- virtual bool get_bool(const std::string &section,
- const std::string &option,
- bool default_val);
- virtual void set_bool(const std::string &section,
- const std::string &option,
- bool val);
- virtual long get_long(const std::string &section,
- const std::string &option,
- long default_val);
- virtual void set_long(const std::string &section,
- const std::string &option,
- long val);
- virtual double get_double(const std::string &section,
- const std::string &option,
- double default_val);
- virtual void set_double(const std::string &section,
- const std::string &option,
- double val);
-};
diff --git a/gnuradio-runtime/swig/realtime.i b/gnuradio-runtime/swig/realtime.i
deleted file mode 100644
index 15202ca555..0000000000
--- a/gnuradio-runtime/swig/realtime.i
+++ /dev/null
@@ -1,30 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2008,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-%rename(enable_realtime_scheduling) gr::enable_realtime_scheduling;
-
-// NOTE: This is duplicated from gnuradio-runtime/include/realtime.h,
-// and must be kept in sync with it. This is the least evil workaround
-// for allowing 3rd party code builds to work when GNU Radio is
-// installed from binary packages into the standard system directories.
-// Otherwise, they can't find #include <realtime.h>, since
-// pkg-config strips -I/usr/include from the --cflags path.
-
-namespace gr {
-
- typedef enum {
- RT_OK = 0,
- RT_NOT_IMPLEMENTED,
- RT_NO_PRIVS,
- RT_OTHER_ERROR
- } rt_status_t;
-
- gr::rt_status_t gr::enable_realtime_scheduling();
-}
diff --git a/gnuradio-runtime/swig/runtime_swig.i b/gnuradio-runtime/swig/runtime_swig.i
deleted file mode 100644
index e5defdcbbd..0000000000
--- a/gnuradio-runtime/swig/runtime_swig.i
+++ /dev/null
@@ -1,87 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-#define GR_RUNTIME_API
-
-#ifndef SWIGIMPORTED
-%include "runtime_swig_doc.i"
-%module(directors="1") runtime_swig
-#endif
-
-%feature("autodoc", "1"); // generate python docstrings
-
-#define SW_RUNTIME
-%include "gnuradio.i" // the common stuff
-
-%{
-#include <gnuradio/runtime_types.h>
-%}
-
-%include <gnuradio/runtime_types.h>
-
-%{
-#include <gnuradio/block.h>
-#include <gnuradio/block_detail.h>
-#include <gnuradio/buffer.h>
-#include <gnuradio/constants.h>
-#include <gnuradio/endianness.h>
-#include <gnuradio/feval.h>
-#include <gnuradio/hier_block2.h>
-#include <gnuradio/io_signature.h>
-#include <gnuradio/message.h>
-#include <gnuradio/msg_handler.h>
-#include <gnuradio/msg_queue.h>
-#include <gnuradio/prefs.h>
-#include <gnuradio/realtime.h>
-#include <gnuradio/sync_block.h>
-#include <gnuradio/sync_decimator.h>
-#include <gnuradio/sync_interpolator.h>
-#include <gnuradio/tags.h>
-#include <gnuradio/tagged_stream_block.h>
-#include <gnuradio/top_block.h>
-#include <gnuradio/logger.h>
-#include <gnuradio/math.h>
-#include <gnuradio/random.h>
-%}
-
-%constant int sizeof_char = sizeof(char);
-%constant int sizeof_short = sizeof(short);
-%constant int sizeof_int = sizeof(int);
-%constant int sizeof_float = sizeof(float);
-%constant int sizeof_double = sizeof(double);
-%constant int sizeof_gr_complex = sizeof(gr_complex);
-
-%include <gnuradio/endianness.h>
-%include "basic_block.i"
-%include "block.i"
-%include "block_detail.i"
-%include "buffer.i"
-%include "constants.i"
-%include "feval.i"
-%include "hier_block2.i"
-%include "io_signature.i"
-%include "message.i"
-%include "msg_handler.i"
-%include "msg_queue.i"
-%include "prefs.i"
-%include "realtime.i"
-%include "sync_block.i"
-%include "sync_decimator.i"
-%include "sync_interpolator.i"
-%include "tagged_stream_block.i"
-%include "tags.i"
-%include "top_block.i"
-%include "block_gateway.i"
-%include "gr_logger.i"
-%include "gr_swig_block_magic.i"
-%include "gr_ctrlport.i"
-
-%include "gnuradio/math.h"
-%include "gnuradio/random.h"
diff --git a/gnuradio-runtime/swig/sync_block.i b/gnuradio-runtime/swig/sync_block.i
deleted file mode 100644
index 1f2091e4c6..0000000000
--- a/gnuradio-runtime/swig/sync_block.i
+++ /dev/null
@@ -1,18 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::sync_block : public gr::block
-{
- protected:
-
- sync_block(const std::string &name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature);
-};
diff --git a/gnuradio-runtime/swig/sync_decimator.i b/gnuradio-runtime/swig/sync_decimator.i
deleted file mode 100644
index 14553cb7b8..0000000000
--- a/gnuradio-runtime/swig/sync_decimator.i
+++ /dev/null
@@ -1,19 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::sync_decimator : public gr::sync_block
-{
- protected:
-
- sync_decimator(const std::string &name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature,
- unsigned decimation);
-};
diff --git a/gnuradio-runtime/swig/sync_interpolator.i b/gnuradio-runtime/swig/sync_interpolator.i
deleted file mode 100644
index f3d95edf73..0000000000
--- a/gnuradio-runtime/swig/sync_interpolator.i
+++ /dev/null
@@ -1,19 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2004,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::sync_interpolator : public gr::sync_block
-{
- protected:
-
- sync_interpolator(const std::string &name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature,
- unsigned interpolation);
-};
diff --git a/gnuradio-runtime/swig/tagged_stream_block.i b/gnuradio-runtime/swig/tagged_stream_block.i
deleted file mode 100644
index c21401f69d..0000000000
--- a/gnuradio-runtime/swig/tagged_stream_block.i
+++ /dev/null
@@ -1,19 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-class gr::tagged_stream_block : public gr::block
-{
- protected:
- tagged_stream_block(const std::string &name,
- gr::io_signature::sptr input_signature,
- gr::io_signature::sptr output_signature,
- const std::string &length_tag_key);
-};
-
diff --git a/gnuradio-runtime/swig/tags.i b/gnuradio-runtime/swig/tags.i
deleted file mode 100644
index 476c402aee..0000000000
--- a/gnuradio-runtime/swig/tags.i
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright 2011,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-%{
-#include <gnuradio/tags.h>
-%}
-
-%import <pmt_swig.i> //for pmt support
-
-%ignore gr::tag_t::operator=;
-%include <gnuradio/tags.h>
-
-//gives support for a vector of tags (get tags in range)
-%include "std_vector.i"
-%template(tags_vector_t) std::vector<gr::tag_t>;
diff --git a/gnuradio-runtime/swig/top_block.i b/gnuradio-runtime/swig/top_block.i
deleted file mode 100644
index 71a0fd2c45..0000000000
--- a/gnuradio-runtime/swig/top_block.i
+++ /dev/null
@@ -1,96 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2007,2008,2010,2013 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * SPDX-License-Identifier: GPL-3.0-or-later
- *
- */
-
-%template(top_block_sptr) std::shared_ptr<gr::top_block>;
-
-namespace gr {
- // Hack to have a Python shim implementation of gr.top_block
- // that instantiates one of these and passes through calls
- %rename(top_block_swig) make_top_block;
- gr::top_block_sptr make_top_block(const std::string name, bool catch_exceptions)
- throw (std::logic_error);
-
- class top_block : public gr::hier_block2
- {
- private:
- top_block(const std::string &name, bool catch_exceptions=true);
-
- public:
- ~top_block();
-
- void start(int max_noutput_items=100000000) noexcept(false);
- void stop();
- //void wait();
- //void run() throw (std::runtime_error);
- void lock();
- void unlock() noexcept(false);
- std::string edge_list();
- std::string msg_edge_list();
- void dump();
-
- int max_noutput_items();
- void set_max_noutput_items(int nmax);
-
- gr::top_block_sptr to_top_block(); // Needed for Python type coercion
- };
-}
-
-#ifdef SWIGPYTHON
-
-%inline %{
-void top_block_run_unlocked(gr::top_block_sptr r) noexcept(false)
-{
- GR_PYTHON_BLOCKING_CODE
- (
- r->run();
- )
-}
-
-void top_block_start_unlocked(gr::top_block_sptr r, int max_noutput_items) noexcept(false)
-{
- GR_PYTHON_BLOCKING_CODE
- (
- r->start(max_noutput_items);
- )
-}
-
-void top_block_wait_unlocked(gr::top_block_sptr r) noexcept(false)
-{
- GR_PYTHON_BLOCKING_CODE
- (
- r->wait();
- )
-}
-
-void top_block_stop_unlocked(gr::top_block_sptr r) noexcept(false)
-{
- GR_PYTHON_BLOCKING_CODE
- (
- r->stop();
- )
-}
-
-void top_block_unlock_unlocked(gr::top_block_sptr r) noexcept(false)
-{
- GR_PYTHON_BLOCKING_CODE
- (
- r->unlock();
- )
-}
-
-std::string
-dot_graph_tb(gr::top_block_sptr r)
-{
- return dot_graph(r);
-}
-
-%}
-
-#endif