aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt1
-rw-r--r--cmake/Modules/GnuradioConfig.cmake.in1
-rw-r--r--docs/doxygen/Doxyfile.in4
-rw-r--r--docs/doxygen/other/build_guide.dox.in7
-rw-r--r--docs/sphinx/source/comedi_blocks.rst7
-rw-r--r--docs/sphinx/source/index.rst1
-rw-r--r--gnuradio-runtime/python/gnuradio/__init__.py1
-rw-r--r--gr-comedi/CMakeLists.txt68
-rw-r--r--gr-comedi/gnuradio-comedi.pc.in11
-rw-r--r--gr-comedi/include/gnuradio/comedi/CMakeLists.txt29
-rw-r--r--gr-comedi/include/gnuradio/comedi/api.h33
-rw-r--r--gr-comedi/include/gnuradio/comedi/sink_s.h58
-rw-r--r--gr-comedi/include/gnuradio/comedi/source_s.h58
-rw-r--r--gr-comedi/lib/CMakeLists.txt41
-rw-r--r--gr-comedi/lib/sink_s_impl.cc239
-rw-r--r--gr-comedi/lib/sink_s_impl.h73
-rw-r--r--gr-comedi/lib/source_s_impl.cc236
-rw-r--r--gr-comedi/lib/source_s_impl.h73
-rw-r--r--gr-comedi/python/comedi/CMakeLists.txt49
-rw-r--r--gr-comedi/python/comedi/__init__.py34
-rw-r--r--gr-comedi/python/comedi/qa_comedi.py40
-rw-r--r--gr-comedi/swig/CMakeLists.txt49
-rw-r--r--gr-comedi/swig/comedi_swig.i39
23 files changed, 2 insertions, 1150 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0eaabc157..c26eedb68 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -495,7 +495,6 @@ add_subdirectory(gr-analog)
add_subdirectory(gr-digital)
add_subdirectory(gr-dtv)
add_subdirectory(gr-audio)
-add_subdirectory(gr-comedi)
add_subdirectory(gr-channels)
add_subdirectory(gr-qtgui)
add_subdirectory(gr-trellis)
diff --git a/cmake/Modules/GnuradioConfig.cmake.in b/cmake/Modules/GnuradioConfig.cmake.in
index 832e8fcca..1e5ad20ec 100644
--- a/cmake/Modules/GnuradioConfig.cmake.in
+++ b/cmake/Modules/GnuradioConfig.cmake.in
@@ -91,7 +91,6 @@ set(GR_COMPONENTS
digital
dtv
audio
- comedi
channels
qtgui
trellis
diff --git a/docs/doxygen/Doxyfile.in b/docs/doxygen/Doxyfile.in
index 72e7977df..bd60d7cc3 100644
--- a/docs/doxygen/Doxyfile.in
+++ b/docs/doxygen/Doxyfile.in
@@ -151,8 +151,6 @@ STRIP_FROM_INC_PATH = @CMAKE_SOURCE_DIR@/gnuradio-runtime/include \
@CMAKE_BINARY_DIR@/gr-blocks/include \
@CMAKE_SOURCE_DIR@/gr-channels/include \
@CMAKE_BINARY_DIR@/gr-channels/include \
- @CMAKE_SOURCE_DIR@/gr-comedi/include \
- @CMAKE_BINARY_DIR@/gr-comedi/include \
@CMAKE_SOURCE_DIR@/gr-digital/include \
@CMAKE_BINARY_DIR@/gr-digital/include \
@CMAKE_SOURCE_DIR@/gr-dtv/include \
@@ -760,8 +758,6 @@ EXCLUDE = @abs_top_srcdir@/volk \
@abs_top_builddir@/gr-blocks/lib \
@abs_top_srcdir@/gr-channels/lib \
@abs_top_builddir@/gr-channels/lib \
- @abs_top_srcdir@/gr-comedi/lib \
- @abs_top_builddir@/gr-comedi/lib \
@abs_top_srcdir@/gr-digital/lib \
@abs_top_builddir@/gr-digital/lib \
@abs_top_srcdir@/gr-dtv/lib \
diff --git a/docs/doxygen/other/build_guide.dox.in b/docs/doxygen/other/build_guide.dox.in
index cf9cc39ba..aa4f190ac 100644
--- a/docs/doxygen/other/build_guide.dox.in
+++ b/docs/doxygen/other/build_guide.dox.in
@@ -25,8 +25,8 @@ systems on gnuradio.org
Not all dependencies are required for all components, and not all
components are required for a given installation. The list of required
components is determined by what the user requires from GNU Radio. If,
-for example, you do not use any Comedi-based hardware, do not worry
-about building gr-comedi.
+for example, you do not use any UHD-based hardware, do not worry
+about building gr-uhd.
Before trying to build these from source, please try your system's
installation tool (apt-get, pkg_install, YaST, yum, urpmi, etc.)
@@ -102,9 +102,6 @@ audio-osx and audio-windows to be either satisfied or built.
\subsection dep_gr_video_sdl gr-video-sdl: PAL and NTSC display (rarely used)
\li SDL (>= 1.2.0) http://www.libsdl.org/download-1.2.php
-\subsection dep_gr_comedi gr-comedi: Comedi hardware interface (only if you know what this is)
-\li comedilib (>= 0.8.1) http://www.comedi.org/
-
\ref page_ctrlport may use various backends to perform the RPC
process, and each is its own dependency.
diff --git a/docs/sphinx/source/comedi_blocks.rst b/docs/sphinx/source/comedi_blocks.rst
deleted file mode 100644
index 570be745d..000000000
--- a/docs/sphinx/source/comedi_blocks.rst
+++ /dev/null
@@ -1,7 +0,0 @@
-gnuradio.comedi
-===============
-
-.. automodule:: gnuradio.comedi
-
-.. autoblock:: gnuradio.comedi.sink_s
-.. autoblock:: gnuradio.comedi.source_s
diff --git a/docs/sphinx/source/index.rst b/docs/sphinx/source/index.rst
index c5521550c..fb74a22ca 100644
--- a/docs/sphinx/source/index.rst
+++ b/docs/sphinx/source/index.rst
@@ -10,7 +10,6 @@ gnuradio
blocks_analog <analog_blocks>
blocks_blocks <blocks_blocks>
blocks_channels <channels_blocks>
- blocks_comedi <comedi_blocks>
blocks_digital <digital_blocks>
blocks_dtv <dtv_blocks>
blocks_fec <fec_blocks>
diff --git a/gnuradio-runtime/python/gnuradio/__init__.py b/gnuradio-runtime/python/gnuradio/__init__.py
index c1735c3d8..7e7b6d8bc 100644
--- a/gnuradio-runtime/python/gnuradio/__init__.py
+++ b/gnuradio-runtime/python/gnuradio/__init__.py
@@ -40,7 +40,6 @@ if path.endswith(path_ending):
__path__.append(os.path.join(build_path, 'gr-qtgui', 'python'))
__path__.append(os.path.join(build_path, 'gr-video-sdl', 'python'))
__path__.append(os.path.join(build_path, 'gr-vocoder', 'python'))
- __path__.append(os.path.join(build_path, 'gr-comedi', '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'))
diff --git a/gr-comedi/CMakeLists.txt b/gr-comedi/CMakeLists.txt
deleted file mode 100644
index be0b17dad..000000000
--- a/gr-comedi/CMakeLists.txt
+++ /dev/null
@@ -1,68 +0,0 @@
-# Copyright 2012,2019 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-
-########################################################################
-# Setup dependencies
-########################################################################
-include(GrBoost)
-include(FindPkgConfig)
-
-PKG_CHECK_MODULES(COMEDI comedilib)
-
-########################################################################
-# Register component
-########################################################################
-include(GrComponent)
-GR_REGISTER_COMPONENT("gr-comedi" ENABLE_GR_COMEDI
- COMEDI_FOUND
- Boost_FOUND
- ENABLE_GNURADIO_RUNTIME
-)
-
-SET(GR_PKG_COMEDI_EXAMPLES_DIR ${GR_PKG_DATA_DIR}/examples/comedi)
-
-########################################################################
-# Begin conditional configuration
-########################################################################
-if(ENABLE_GR_COMEDI)
-
-########################################################################
-# Add subdirectories
-########################################################################
-add_subdirectory(include/gnuradio/comedi)
-add_subdirectory(lib)
-if(ENABLE_PYTHON)
- add_subdirectory(swig)
- add_subdirectory(python/comedi)
-endif(ENABLE_PYTHON)
-
-########################################################################
-# Create Pkg Config File
-########################################################################
-configure_file(
- ${CMAKE_CURRENT_SOURCE_DIR}/gnuradio-comedi.pc.in
- ${CMAKE_CURRENT_BINARY_DIR}/gnuradio-comedi.pc
-@ONLY)
-
-install(
- FILES ${CMAKE_CURRENT_BINARY_DIR}/gnuradio-comedi.pc
- DESTINATION ${GR_LIBRARY_DIR}/pkgconfig
-)
-
-endif(ENABLE_GR_COMEDI)
diff --git a/gr-comedi/gnuradio-comedi.pc.in b/gr-comedi/gnuradio-comedi.pc.in
deleted file mode 100644
index 0f3ac4cae..000000000
--- a/gr-comedi/gnuradio-comedi.pc.in
+++ /dev/null
@@ -1,11 +0,0 @@
-prefix=@prefix@
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-includedir=@includedir@
-
-Name: gnuradio-comedi
-Description: GNU Radio blocks for the comedi library
-Requires: gnuradio-runtime
-Version: @LIBVER@
-Libs: -L${libdir} -lgnuradio-comedi
-Cflags: -I${includedir}
diff --git a/gr-comedi/include/gnuradio/comedi/CMakeLists.txt b/gr-comedi/include/gnuradio/comedi/CMakeLists.txt
deleted file mode 100644
index 601c1fb91..000000000
--- a/gr-comedi/include/gnuradio/comedi/CMakeLists.txt
+++ /dev/null
@@ -1,29 +0,0 @@
-# Copyright 2012 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-
-########################################################################
-# Install header files
-########################################################################
-install(FILES
- api.h
- sink_s.h
- source_s.h
- DESTINATION ${GR_INCLUDE_DIR}/gnuradio/comedi
-)
-
diff --git a/gr-comedi/include/gnuradio/comedi/api.h b/gr-comedi/include/gnuradio/comedi/api.h
deleted file mode 100644
index 1afaf0d18..000000000
--- a/gr-comedi/include/gnuradio/comedi/api.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright 2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef INCLUDED_COMEDI_API_H
-#define INCLUDED_COMEDI_API_H
-
-#include <gnuradio/attributes.h>
-
-#ifdef gnuradio_comedi_EXPORTS
-# define COMEDI_API __GR_ATTR_EXPORT
-#else
-# define COMEDI_API __GR_ATTR_IMPORT
-#endif
-
-#endif /* INCLUDED_COMEDI_API_H */
diff --git a/gr-comedi/include/gnuradio/comedi/sink_s.h b/gr-comedi/include/gnuradio/comedi/sink_s.h
deleted file mode 100644
index 6d60b7606..000000000
--- a/gr-comedi/include/gnuradio/comedi/sink_s.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef INCLUDED_COMEDI_SINK_H
-#define INCLUDED_COMEDI_SINK_H
-
-#include <gnuradio/comedi/api.h>
-#include <gnuradio/sync_block.h>
-
-namespace gr {
- namespace comedi {
-
- /*!
- * \brief sink using COMEDI
- *
- * The sink has one input stream of signed short integers.
- *
- * Input samples must be in the range [-32768,32767].
- */
- class COMEDI_API sink_s : virtual public sync_block
- {
- public:
- // gr::comedi::sink_s::sptr
- typedef boost::shared_ptr<sink_s> sptr;
-
- /*!
- * \brief make a COMEDI sink.
- *
- * \param sampling_freq sampling rate in Hz
- * \param dev COMEDI device name, e.g., "/dev/comedi0"
- */
- static sptr make(int sampling_freq,
- const std::string dev = "/dev/comedi0");
- };
-
- } /* namespace comedi */
-} /* namespace gr */
-
-#endif /* INCLUDED_COMEDI_SINK_H */
diff --git a/gr-comedi/include/gnuradio/comedi/source_s.h b/gr-comedi/include/gnuradio/comedi/source_s.h
deleted file mode 100644
index cab6f8201..000000000
--- a/gr-comedi/include/gnuradio/comedi/source_s.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef INCLUDED_COMEDI_SOURCE_S_H
-#define INCLUDED_COMEDI_SOURCE_S_H
-
-#include <gnuradio/comedi/api.h>
-#include <gnuradio/sync_block.h>
-
-namespace gr {
- namespace comedi {
-
- /*!
- * \brief source using COMEDI
- *
- * The source has one to many input stream of signed short integers.
- *
- * Output samples will be in the range [-32768,32767].
- */
- class COMEDI_API source_s : virtual public sync_block
- {
- public:
- // gr::comedi::source_s::sptr
- typedef boost::shared_ptr<source_s> sptr;
-
- /*!
- * \brief make a COMEDI source.
- *
- * \param sampling_freq sampling rate in Hz
- * \param dev COMEDI device name, e.g., "/dev/comedi0"
- */
- static sptr make(int sampling_freq,
- const std::string dev = "/dev/comedi0");
- };
-
- } /* namespace comedi */
-} /* namespace gr */
-
-#endif /* INCLUDED_COMEDI_SOURCE_S_H */
diff --git a/gr-comedi/lib/CMakeLists.txt b/gr-comedi/lib/CMakeLists.txt
deleted file mode 100644
index 43054ef9d..000000000
--- a/gr-comedi/lib/CMakeLists.txt
+++ /dev/null
@@ -1,41 +0,0 @@
-# Copyright 2011,2012,2019 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-
-########################################################################
-# Setup library
-########################################################################
-add_library(gnuradio-comedi
- sink_s_impl.cc
- source_s_impl.cc
-)
-
-target_link_libraries(gnuradio-comedi
- gnuradio-runtime
- ${COMEDI_LIBRARIES}
-)
-
-target_include_directories(gnuradio-comedi
- PUBLIC
- $<INSTALL_INTERFACE:include>
- $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/../include>
- )
-
-if(BUILD_SHARED_LIBS)
- GR_LIBRARY_FOO(gnuradio-comedi)
-endif()
diff --git a/gr-comedi/lib/sink_s_impl.cc b/gr-comedi/lib/sink_s_impl.cc
deleted file mode 100644
index df2040adf..000000000
--- a/gr-comedi/lib/sink_s_impl.cc
+++ /dev/null
@@ -1,239 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2010,2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <sys/mman.h>
-
-#include "sink_s_impl.h"
-#include <gnuradio/io_signature.h>
-#include <stdio.h>
-#include <errno.h>
-#include <iostream>
-#include <stdexcept>
-
-namespace gr {
- namespace comedi {
-
- /*
- * comedi_sink_s is untested because I don't own appropriate hardware.
- * Feedback is welcome! --SF
- */
-
- static std::string
- default_device_name()
- {
- return "/dev/comedi0";
- }
-
- // ----------------------------------------------------------------
-
- sink_s::sptr
- sink_s::make(int sampling_freq, const std::string dev)
- {
- return gnuradio::get_initial_sptr
- (new sink_s_impl(sampling_freq, dev));
- }
-
- sink_s_impl::sink_s_impl(int sampling_freq,
- const std::string device_name)
- : sync_block("comedi_sink_s",
- io_signature::make(0, 0, 0),
- io_signature::make(0, 0, 0)),
- d_sampling_freq(sampling_freq),
- d_device_name(device_name.empty() ? default_device_name() : device_name),
- d_dev(0),
- d_subdevice(COMEDI_SUBD_AO),
- d_n_chan(1), // number of input channels
- d_map(0),
- d_buffer_size(0),
- d_buf_front(0),
- d_buf_back(0)
- {
- int aref=AREF_GROUND;
- int range=0;
-
- d_dev = comedi_open(d_device_name.c_str());
- if(d_dev == 0) {
- comedi_perror(d_device_name.c_str());
- throw std::runtime_error("sink_s_impl");
- }
-
- unsigned int chanlist[256];
-
- for(int i=0; i<d_n_chan; i++) {
- chanlist[i] = CR_PACK(i,range,aref);
- }
-
- comedi_cmd cmd;
- int ret;
-
- ret = comedi_get_cmd_generic_timed(d_dev,d_subdevice,
- &cmd, d_n_chan,
- (unsigned int)(1e9/sampling_freq));
- if(ret < 0)
- bail("comedi_get_cmd_generic_timed", comedi_errno());
-
- // TODO: check period_ns is not to far off sampling_freq
-
- d_buffer_size = comedi_get_buffer_size(d_dev, d_subdevice);
- if(d_buffer_size <= 0)
- bail("comedi_get_buffer_size", comedi_errno());
-
- d_map = mmap(NULL, d_buffer_size, PROT_WRITE,
- MAP_SHARED, comedi_fileno(d_dev), 0);
- if(d_map == MAP_FAILED)
- bail("mmap", errno);
-
- cmd.chanlist = chanlist;
- cmd.chanlist_len = d_n_chan;
- cmd.scan_end_arg = d_n_chan;
-
- cmd.stop_src = TRIG_NONE;
- cmd.stop_arg = 0;
-
- /* comedi_command_test() tests a command to see if the trigger
- * sources and arguments are valid for the subdevice. If a
- * trigger source is invalid, it will be logically ANDed with
- * valid values (trigger sources are actually bitmasks), which
- * may or may not result in a valid trigger source. If an
- * argument is invalid, it will be adjusted to the nearest valid
- * value. In this way, for many commands, you can test it
- * multiple times until it passes. Typically, if you can't get
- * a valid command in two tests, the original command wasn't
- * specified very well. */
- ret = comedi_command_test(d_dev,&cmd);
-
- if(ret < 0)
- bail("comedi_command_test", comedi_errno());
-
- ret = comedi_command_test(d_dev,&cmd);
-
- if(ret < 0)
- bail("comedi_command_test", comedi_errno());
-
- /* start the command */
- ret = comedi_command(d_dev,&cmd);
-
- if(ret < 0)
- bail("comedi_command", comedi_errno());
-
- set_output_multiple(d_n_chan*sizeof(sampl_t));
-
- assert(sizeof(sampl_t) == sizeof(short));
- set_output_signature(io_signature::make(1, 1, sizeof(sampl_t)));
- }
-
- bool
- sink_s_impl::check_topology(int ninputs, int noutputs)
- {
- if(ninputs > d_n_chan)
- throw std::runtime_error("sink_s_impl");
-
- return true;
- }
-
- sink_s_impl::~sink_s_impl()
- {
- if(d_map) {
- munmap(d_map, d_buffer_size);
- d_map = 0;
- }
-
- comedi_close(d_dev);
- }
-
- int
- sink_s_impl::work(int noutput_items,
- gr_vector_const_void_star &input_items,
- gr_vector_void_star &output_items)
- {
- int ret;
-
- int work_left = noutput_items * sizeof(sampl_t) * d_n_chan;
- sampl_t *pbuf = (sampl_t*)d_map;
-
- do {
- do {
- ret = comedi_get_buffer_contents(d_dev, d_subdevice);
- if(ret < 0)
- bail("comedi_get_buffer_contents", comedi_errno());
-
- assert(ret % sizeof(sampl_t) == 0);
- assert(work_left % sizeof(sampl_t) == 0);
-
- ret = std::min(ret, work_left);
- d_buf_front += ret;
-
- assert(d_buffer_size%d_n_chan == 0);
- if(d_buf_front-d_buf_back > (unsigned)d_buffer_size) {
- d_buf_front+=d_buffer_size;
- d_buf_back +=d_buffer_size;
- }
-
- if(d_buf_front==d_buf_back){
- usleep(1000000*std::min(work_left,
- d_buffer_size/2)/(d_sampling_freq*sizeof(sampl_t)*d_n_chan));
- continue;
- }
- } while(d_buf_front==d_buf_back);
-
- for(unsigned i = d_buf_back/sizeof(sampl_t); i < d_buf_front/sizeof(sampl_t); i++) {
- int chan = i%d_n_chan;
- int i_idx = noutput_items-work_left/d_n_chan/sizeof(sampl_t) + \
- (i-d_buf_back/sizeof(sampl_t))/d_n_chan;
-
- pbuf[i%(d_buffer_size/sizeof(sampl_t))] = input_items[chan]==0 ? 0 :
- (int)((short*)(input_items[chan]))[i_idx] + 32767;
- }
-
- // FIXME: how to tell comedi the buffer is *written* ?
- ret = comedi_mark_buffer_read(d_dev, d_subdevice, d_buf_front-d_buf_back);
- if(ret < 0)
- bail("comedi_mark_buffer_read", comedi_errno());
-
- work_left -= d_buf_front-d_buf_back;
-
- d_buf_back = d_buf_front;
- } while(work_left > 0);
-
- return noutput_items;
- }
-
- void
- sink_s_impl::output_error_msg(const char *msg, int err)
- {
- fprintf(stderr, "sink_s_impl[%s]: %s: %s\n",
- d_device_name.c_str(), msg, comedi_strerror(err));
- }
-
- void
- sink_s_impl::bail(const char *msg, int err) throw (std::runtime_error)
- {
- output_error_msg(msg, err);
- throw std::runtime_error("sink_s_impl");
- }
-
- } /* namespace comedi */
-} /* namespace gr */
diff --git a/gr-comedi/lib/sink_s_impl.h b/gr-comedi/lib/sink_s_impl.h
deleted file mode 100644
index 738664c28..000000000
--- a/gr-comedi/lib/sink_s_impl.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef INCLUDED_COMEDI_SINK_IMPL_H
-#define INCLUDED_COMEDI_SINK_IMPL_H
-
-#include <gnuradio/comedi/sink_s.h>
-#include <string>
-#include <comedilib.h>
-#include <stdexcept>
-
-namespace gr {
- namespace comedi {
-
- class sink_s_impl : public sink_s
- {
- private:
- // typedef for pointer to class work method
- typedef int (sink_s::*work_t)(int noutput_items,
- gr_vector_const_void_star &input_items,
- gr_vector_void_star &output_items);
-
- unsigned int d_sampling_freq;
- std::string d_device_name;
-
- comedi_t *d_dev;
- int d_subdevice;
- int d_n_chan;
- void *d_map;
- int d_buffer_size;
- unsigned d_buf_front;
- unsigned d_buf_back;
-
- // random stats
- int d_nunderuns; // count of underruns
-
- void output_error_msg(const char *msg, int err);
- void bail(const char *msg, int err) throw (std::runtime_error);
-
- public:
- sink_s_impl(int sampling_freq, const std::string device_name);
- ~sink_s_impl();
-
- bool check_topology(int ninputs, int noutputs);
-
- int work(int noutput_items,
- gr_vector_const_void_star &input_items,
- gr_vector_void_star &output_items);
- };
-
- } /* namespace comedi */
-} /* namespace gr */
-
-#endif /* INCLUDED_COMEDI_SINK_IMPL_H */
diff --git a/gr-comedi/lib/source_s_impl.cc b/gr-comedi/lib/source_s_impl.cc
deleted file mode 100644
index 4e3d9e1c0..000000000
--- a/gr-comedi/lib/source_s_impl.cc
+++ /dev/null
@@ -1,236 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2010 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifdef HAVE_CONFIG_H
-#include "config.h"
-#endif
-
-#include <sys/mman.h>
-
-#include "source_s_impl.h"
-#include <gnuradio/io_signature.h>
-#include <stdio.h>
-#include <errno.h>
-#include <iostream>
-#include <stdexcept>
-
-// FIXME these should query some kind of user preference
-
-namespace gr {
- namespace comedi {
-
- static std::string
- default_device_name()
- {
- return "/dev/comedi0";
- }
-
- // ----------------------------------------------------------------
-
- source_s::sptr
- source_s::make(int sampling_freq, const std::string dev)
- {
- return gnuradio::get_initial_sptr
- (new source_s_impl(sampling_freq, dev));
- }
-
- source_s_impl::source_s_impl(int sampling_freq,
- const std::string device_name)
- : sync_block("comedi_source_s",
- io_signature::make(0, 0, 0),
- io_signature::make(0, 0, 0)),
- d_sampling_freq(sampling_freq),
- d_device_name(device_name.empty() ? default_device_name() : device_name),
- d_dev(0),
- d_subdevice(0/*COMEDI_SUBD_AI*/),
- d_n_chan(1), // number of input channels
- d_map(0),
- d_buffer_size(0),
- d_buf_front(0),
- d_buf_back(0)
- {
- int aref = AREF_GROUND;
- int range = 0;
-
- d_dev = comedi_open(d_device_name.c_str());
- if(d_dev == 0) {
- comedi_perror(d_device_name.c_str());
- throw std::runtime_error("source_s_impl");
- }
-
- unsigned int chanlist[256];
-
- for(int i=0; i<d_n_chan; i++) {
- chanlist[i] = CR_PACK(i,range,aref);
- }
-
- comedi_cmd cmd;
- int ret;
-
- ret = comedi_get_cmd_generic_timed(d_dev, d_subdevice,
- &cmd, d_n_chan,
- (unsigned int)(1e9/sampling_freq));
- if(ret < 0)
- bail("comedi_get_cmd_generic_timed", comedi_errno());
-
- // TODO: check period_ns is not to far off sampling_freq
-
- d_buffer_size = comedi_get_buffer_size(d_dev, d_subdevice);
- if(d_buffer_size <= 0)
- bail("comedi_get_buffer_size", comedi_errno());
-
- d_map = mmap(NULL, d_buffer_size, PROT_READ,
- MAP_SHARED, comedi_fileno(d_dev),0);
- if(d_map == MAP_FAILED)
- bail("mmap", errno);
-
- cmd.chanlist = chanlist;
- cmd.chanlist_len = d_n_chan;
- cmd.scan_end_arg = d_n_chan;
-
- cmd.stop_src = TRIG_NONE;
- cmd.stop_arg = 0;
-
- /* comedi_command_test() tests a command to see if the trigger
- * sources and arguments are valid for the subdevice. If a
- * trigger source is invalid, it will be logically ANDed with
- * valid values (trigger sources are actually bitmasks), which
- * may or may not result in a valid trigger source. If an
- * argument is invalid, it will be adjusted to the nearest valid
- * value. In this way, for many commands, you can test it
- * multiple times until it passes. Typically, if you can't get
- * a valid command in two tests, the original command wasn't
- * specified very well. */
- ret = comedi_command_test(d_dev,&cmd);
-
- if(ret < 0)
- bail("comedi_command_test", comedi_errno());
-
- ret = comedi_command_test(d_dev,&cmd);
-
- if(ret < 0)
- bail("comedi_command_test", comedi_errno());
-
- /* start the command */
- ret = comedi_command(d_dev,&cmd);
-
- if(ret < 0)
- bail("comedi_command", comedi_errno());
-
- set_output_multiple(d_n_chan*sizeof(sampl_t));
-
- assert(sizeof(sampl_t) == sizeof(short));
- set_output_signature(io_signature::make(1, 1, sizeof(sampl_t)));
- }
-
- bool
- source_s_impl::check_topology(int ninputs, int noutputs)
- {
- if(noutputs > d_n_chan)
- throw std::runtime_error("source_s_impl");
-
- return true;
- }
-
- source_s_impl::~source_s_impl()
- {
- if(d_map) {
- munmap(d_map, d_buffer_size);
- d_map = 0;
- }
-
- comedi_close(d_dev);
- }
-
- int
- source_s_impl::work(int noutput_items,
- gr_vector_const_void_star &input_items,
- gr_vector_void_star &output_items)
- {
- int ret;
-
- int work_left = noutput_items * sizeof(sampl_t) * d_n_chan;
- sampl_t *pbuf = (sampl_t*)d_map;
-
- do {
- do {
- ret = comedi_get_buffer_contents(d_dev, d_subdevice);
- if(ret < 0)
- bail("comedi_get_buffer_contents", comedi_errno());
-
- assert(ret % sizeof(sampl_t) == 0);
- assert(work_left % sizeof(sampl_t) == 0);
-
- ret = std::min(ret, work_left);
- d_buf_front += ret;
-
- assert(d_buffer_size%d_n_chan == 0);
- if(d_buf_front-d_buf_back > (unsigned)d_buffer_size) {
- d_buf_front+=d_buffer_size;
- d_buf_back +=d_buffer_size;
- }
-
- if(d_buf_front==d_buf_back) {
- usleep(1000000*std::min(work_left,
- d_buffer_size/2)/(d_sampling_freq*sizeof(sampl_t)*d_n_chan));
- continue;
- }
- } while(d_buf_front == d_buf_back);
-
- for(unsigned i=d_buf_back/sizeof(sampl_t); i < d_buf_front/sizeof(sampl_t); i++) {
- int chan = i%d_n_chan;
- int o_idx = noutput_items-work_left/d_n_chan/sizeof(sampl_t) + \
- (i-d_buf_back/sizeof(sampl_t))/d_n_chan;
-
- if(output_items[chan])
- ((short*)(output_items[chan]))[o_idx] =
- (int)pbuf[i%(d_buffer_size/sizeof(sampl_t))] - 32767;
- }
-
- ret = comedi_mark_buffer_read(d_dev,d_subdevice, d_buf_front-d_buf_back);
- if(ret < 0)
- bail("comedi_mark_buffer_read", comedi_errno());
-
- work_left -= d_buf_front-d_buf_back;
-
- d_buf_back = d_buf_front;
- } while(work_left > 0);
-
- return noutput_items;
- }
-
- void
- source_s_impl::output_error_msg(const char *msg, int err)
- {
- fprintf(stderr, "source_s_impl[%s]: %s: %s\n",
- d_device_name.c_str(), msg, comedi_strerror(err));
- }
-
- void
- source_s_impl::bail(const char *msg, int err) throw (std::runtime_error)
- {
- output_error_msg(msg, err);
- throw std::runtime_error("source_s_impl");
- }
-
- } /* namespace comedi */
-} /* namespace gr */
diff --git a/gr-comedi/lib/source_s_impl.h b/gr-comedi/lib/source_s_impl.h
deleted file mode 100644
index d3ba10d23..000000000
--- a/gr-comedi/lib/source_s_impl.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#ifndef INCLUDED_COMEDI_SOURCE_S_IMPL_H
-#define INCLUDED_COMEDI_SOURCE_S_IMPL_H
-
-#include <gnuradio/comedi/source_s.h>
-#include <string>
-#include <comedilib.h>
-#include <stdexcept>
-
-namespace gr {
- namespace comedi {
-
- class source_s_impl : public source_s
- {
- private:
- // typedef for pointer to class work method
- typedef int(source_s::*work_t)(int noutput_items,
- gr_vector_const_void_star &input_items,
- gr_vector_void_star &output_items);
-
- unsigned int d_sampling_freq;
- std::string d_device_name;
-
- comedi_t *d_dev;
- int d_subdevice;
- int d_n_chan;
- void *d_map;
- int d_buffer_size;
- unsigned d_buf_front;
- unsigned d_buf_back;
-
- // random stats
- int d_noverruns; // count of overruns
-
- void output_error_msg(const char *msg, int err);
- void bail(const char *msg, int err) throw (std::runtime_error);
-
- public:
- source_s_impl(int sampling_freq, const std::string device_name);
- ~source_s_impl();
-
- bool check_topology(int ninputs, int noutputs);
-
- int work(int noutput_items,
- gr_vector_const_void_star &input_items,
- gr_vector_void_star &output_items);
- };
-
- } /* namespace comedi */
-} /* namespace gr */
-
-#endif /* INCLUDED_COMEDI_SOURCE_S_IMPL_H */
diff --git a/gr-comedi/python/comedi/CMakeLists.txt b/gr-comedi/python/comedi/CMakeLists.txt
deleted file mode 100644
index 01a917807..000000000
--- a/gr-comedi/python/comedi/CMakeLists.txt
+++ /dev/null
@@ -1,49 +0,0 @@
-# Copyright 2012 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-
-########################################################################
-# Setup python install
-########################################################################
-include(GrPython)
-
-GR_PYTHON_INSTALL(
- FILES
- __init__.py
- DESTINATION ${GR_PYTHON_DIR}/gnuradio/comedi
-)
-
-########################################################################
-# Handle the unit tests
-########################################################################
-if(ENABLE_TESTING)
-
- set(GR_TEST_TARGET_DEPS "")
- set(GR_TEST_LIBRARY_DIRS "")
- set(GR_TEST_PYTHON_DIRS
- ${CMAKE_BINARY_DIR}/gnuradio-runtime/python
- ${CMAKE_BINARY_DIR}/gnuradio-runtime/swig
- )
-
- include(GrTest)
- file(GLOB py_qa_test_files "qa_*.py")
- foreach(py_qa_test_file ${py_qa_test_files})
- get_filename_component(py_qa_test_name ${py_qa_test_file} NAME_WE)
- GR_ADD_TEST(${py_qa_test_name} ${QA_PYTHON_EXECUTABLE} -B ${py_qa_test_file})
- endforeach(py_qa_test_file)
-endif(ENABLE_TESTING)
diff --git a/gr-comedi/python/comedi/__init__.py b/gr-comedi/python/comedi/__init__.py
deleted file mode 100644
index f9f1124e5..000000000
--- a/gr-comedi/python/comedi/__init__.py
+++ /dev/null
@@ -1,34 +0,0 @@
-# Copyright 2012 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-#
-
-'''
-Blocks and utilities for COMEDI devices
-'''
-from __future__ import unicode_literals
-
-# The presence of this file turns this directory into a Python package
-import os
-
-try:
- from .comedi_swig import *
-except ImportError:
- dirname, filename = os.path.split(os.path.abspath(__file__))
- __path__.append(os.path.join(dirname, "..", "..", "swig"))
- from .comedi_swig import *
diff --git a/gr-comedi/python/comedi/qa_comedi.py b/gr-comedi/python/comedi/qa_comedi.py
deleted file mode 100644
index f4dc7b777..000000000
--- a/gr-comedi/python/comedi/qa_comedi.py
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright 2005,2007,2012 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-#
-
-
-from gnuradio import gr, gr_unittest, comedi
-
-class test_comedi(gr_unittest.TestCase):
-
- def setUp(self):
- self.tb = gr.top_block()
-
- def tearDown(self):
- self.tb = None
-
- def test_000_nop(self):
- """Just see if we can import the module...
- They may not have COMEDI library, etc. Don't try to run anything"""
- pass
-
-if __name__ == '__main__':
- gr_unittest.run(test_comedi, "test_comedi.xml")
diff --git a/gr-comedi/swig/CMakeLists.txt b/gr-comedi/swig/CMakeLists.txt
deleted file mode 100644
index 77edb0ca8..000000000
--- a/gr-comedi/swig/CMakeLists.txt
+++ /dev/null
@@ -1,49 +0,0 @@
-# Copyright 2012,2019 Free Software Foundation, Inc.
-#
-# This file is part of GNU Radio
-#
-# GNU Radio is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GNU Radio is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Radio; see the file COPYING. If not, write to
-# the Free Software Foundation, Inc., 51 Franklin Street,
-# Boston, MA 02110-1301, USA.
-
-########################################################################
-# Setup swig generation
-########################################################################
-include(GrPython)
-include(GrSwig)
-
-set(GR_SWIG_INCLUDE_DIRS $<TARGET_PROPERTY:runtime_swig,INCLUDE_DIRECTORIES>)
-set(GR_SWIG_TARGET_DEPS runtime_swig)
-
-set(GR_SWIG_DOC_FILE ${CMAKE_CURRENT_BINARY_DIR}/analog_swig_doc.i)
-# Setup swig docs to depend on includes and pull in from build directory
-set(GR_SWIG_DOC_FILE ${CMAKE_CURRENT_BINARY_DIR}/comedi_swig_doc.i)
-set(GR_SWIG_DOC_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/../include/gnuradio/comedi)
-set(GR_SWIG_DOCS_TARGET_DEPS runtime_swig_swig_doc)
-
-set(GR_SWIG_LIBRARIES gnuradio-comedi)
-
-GR_SWIG_MAKE(comedi_swig comedi_swig.i)
-
-GR_SWIG_INSTALL(
- TARGETS comedi_swig
- DESTINATION ${GR_PYTHON_DIR}/gnuradio/comedi
-)
-
-install(
- FILES
- comedi_swig.i
- ${CMAKE_CURRENT_BINARY_DIR}/comedi_swig_doc.i
- DESTINATION ${GR_INCLUDE_DIR}/gnuradio/swig
-)
diff --git a/gr-comedi/swig/comedi_swig.i b/gr-comedi/swig/comedi_swig.i
deleted file mode 100644
index 57f8dec5b..000000000
--- a/gr-comedi/swig/comedi_swig.i
+++ /dev/null
@@ -1,39 +0,0 @@
-/* -*- c++ -*- */
-/*
- * Copyright 2005,2009,2012 Free Software Foundation, Inc.
- *
- * This file is part of GNU Radio
- *
- * GNU Radio is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 3, or (at your option)
- * any later version.
- *
- * GNU Radio is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GNU Radio; see the file COPYING. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street,
- * Boston, MA 02110-1301, USA.
- */
-
-#define COMEDI_API
-
-%include "gnuradio.i"
-
-//load generated python docstrings
-%include "comedi_swig_doc.i"
-
-%{
-#include "gnuradio/comedi/sink_s.h"
-#include "gnuradio/comedi/source_s.h"
-%}
-
-%include "gnuradio/comedi/sink_s.h"
-%include "gnuradio/comedi/source_s.h"
-
-GR_SWIG_BLOCK_MAGIC2(comedi, sink_s);
-GR_SWIG_BLOCK_MAGIC2(comedi, source_s);