summaryrefslogtreecommitdiff
path: root/gr-blocks/include
diff options
context:
space:
mode:
authorTom Rondeau <trondeau@vt.edu>2013-03-02 15:32:01 -0500
committerTom Rondeau <trondeau@vt.edu>2013-03-02 15:32:01 -0500
commitdb5fd745919ac0f4bff5fbd528ebeff13536b057 (patch)
treeb536de1ff19af7baf1d631db19ccb48750eeff0b /gr-blocks/include
parent4c164f4cbb7fc9284bec147809b078d0a8ed9f88 (diff)
blocks: moving mute, probe_signal, probe_signal_v, and sample_and_hold to gr-blocks.
Diffstat (limited to 'gr-blocks/include')
-rw-r--r--gr-blocks/include/blocks/CMakeLists.txt4
-rw-r--r--gr-blocks/include/blocks/mute_XX.h.t54
-rw-r--r--gr-blocks/include/blocks/probe_signal_X.h.t52
-rw-r--r--gr-blocks/include/blocks/probe_signal_vX.h.t53
-rw-r--r--gr-blocks/include/blocks/sample_and_hold_XX.h.t53
5 files changed, 216 insertions, 0 deletions
diff --git a/gr-blocks/include/blocks/CMakeLists.txt b/gr-blocks/include/blocks/CMakeLists.txt
index f1799a4ffc..585810864a 100644
--- a/gr-blocks/include/blocks/CMakeLists.txt
+++ b/gr-blocks/include/blocks/CMakeLists.txt
@@ -76,8 +76,12 @@ expand_h(max_XX ff ii ss)
expand_h(multiply_XX ss ii)
expand_h(multiply_const_XX ss ii)
expand_h(multiply_const_vXX ss ii ff cc)
+expand_h(mute_XX ss ii ff cc)
expand_h(not_XX bb ss ii)
expand_h(or_XX bb ss ii)
+expand_h(probe_signal_X b s i f c)
+expand_h(probe_signal_vX b s i f c)
+expand_h(sample_and_hold_XX bb ss ii ff)
expand_h(sub_XX ss ii ff cc)
expand_h(xor_XX bb ss ii)
expand_h(packed_to_unpacked_XX bb ss ii)
diff --git a/gr-blocks/include/blocks/mute_XX.h.t b/gr-blocks/include/blocks/mute_XX.h.t
new file mode 100644
index 0000000000..3033248c4e
--- /dev/null
+++ b/gr-blocks/include/blocks/mute_XX.h.t
@@ -0,0 +1,54 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2004,2013 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.
+ */
+
+// @WARNING@
+
+#ifndef @GUARD_NAME@
+#define @GUARD_NAME@
+
+#include <blocks/api.h>
+#include <gr_sync_block.h>
+
+namespace gr {
+ namespace blocks {
+
+ /*!
+ * \brief output = input or zero if muted.
+ * \ingroup level_blk
+ */
+ class BLOCKS_API @NAME@ : virtual public gr_sync_block
+ {
+ public:
+ // gr::blocks::@NAME@::sptr
+ typedef boost::shared_ptr<@NAME@> sptr;
+
+ static sptr make(bool mute);
+
+ virtual bool mute() const = 0;
+ virtual void set_mute(bool mute) = 0;
+ };
+
+ } /* namespace blocks */
+} /* namespace gr */
+
+#endif /* @GUARD_NAME@ */
+
diff --git a/gr-blocks/include/blocks/probe_signal_X.h.t b/gr-blocks/include/blocks/probe_signal_X.h.t
new file mode 100644
index 0000000000..01b7bad0c4
--- /dev/null
+++ b/gr-blocks/include/blocks/probe_signal_X.h.t
@@ -0,0 +1,52 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2005,2012-2013 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.
+ */
+
+// @WARNING@
+
+#ifndef @GUARD_NAME@
+#define @GUARD_NAME@
+
+#include <blocks/api.h>
+#include <gr_sync_block.h>
+
+namespace gr {
+ namespace blocks {
+
+ /*!
+ * \brief Sink that allows a sample to be grabbed from Python.
+ * \ingroup sink_blk
+ */
+ class BLOCKS_API @NAME@ : virtual public gr_sync_block
+ {
+ public:
+ // gr::blocks::@NAME@::sptr
+ typedef boost::shared_ptr<@NAME@> sptr;
+
+ static sptr make();
+
+ virtual @TYPE@ level() const = 0;
+ };
+
+ } /* namespace blocks */
+} /* namespace gr */
+
+#endif /* @GUARD_NAME@ */
diff --git a/gr-blocks/include/blocks/probe_signal_vX.h.t b/gr-blocks/include/blocks/probe_signal_vX.h.t
new file mode 100644
index 0000000000..487f280db4
--- /dev/null
+++ b/gr-blocks/include/blocks/probe_signal_vX.h.t
@@ -0,0 +1,53 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2005,2012-2013 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.
+ */
+
+// @WARNING@
+
+#ifndef @GUARD_NAME@
+#define @GUARD_NAME@
+
+#include <vector>
+#include <blocks/api.h>
+#include <gr_sync_block.h>
+
+namespace gr {
+ namespace blocks {
+
+ /*!
+ * \brief Sink that allows a vector of samples to be grabbed from Python.
+ * \ingroup sink_blk
+ */
+ class BLOCKS_API @NAME@ : virtual public gr_sync_block
+ {
+ public:
+ // gr::blocks::@NAME@::sptr
+ typedef boost::shared_ptr<@NAME@> sptr;
+
+ static sptr make(size_t size);
+
+ virtual std::vector<@TYPE@> level() const = 0;
+ };
+
+ } /* namespace blocks */
+} /* namespace gr */
+
+#endif /* @GUARD_NAME@ */
diff --git a/gr-blocks/include/blocks/sample_and_hold_XX.h.t b/gr-blocks/include/blocks/sample_and_hold_XX.h.t
new file mode 100644
index 0000000000..3266523efb
--- /dev/null
+++ b/gr-blocks/include/blocks/sample_and_hold_XX.h.t
@@ -0,0 +1,53 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2007,2013 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.
+ */
+
+// @WARNING@
+
+#ifndef @GUARD_NAME@
+#define @GUARD_NAME@
+
+#include <blocks/api.h>
+#include <gr_sync_block.h>
+
+namespace gr {
+ namespace blocks {
+
+ /*!
+ * \brief sample and hold circuit
+ * \ingroup level_blk
+ *
+ * Samples the data stream (input stream 0) and holds the value if
+ * the control signal is 1 (intput stream 1).
+ */
+ class BLOCKS_API @NAME@ : virtual public gr_sync_block
+ {
+ public:
+ // gr::blocks::@NAME@::sptr
+ typedef boost::shared_ptr<@NAME@> sptr;
+
+ static sptr make();
+ };
+
+ } /* namespace blocks */
+} /* namespace gr */
+
+#endif /* @GUARD_NAME@ */