commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] [gnuradio] 04/09: filter: add variable_band_pass_filte


From: git
Subject: [Commit-gnuradio] [gnuradio] 04/09: filter: add variable_band_pass_filter_taps
Date: Tue, 14 Apr 2015 15:02:56 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

jcorgan pushed a commit to branch master
in repository gnuradio.

commit d42760342231b2a8a15940fccf82e256578d186e
Author: Johnathan Corgan <address@hidden>
Date:   Wed Apr 8 14:23:20 2015 -0700

    filter: add variable_band_pass_filter_taps
    
    Convenience block in GRC to generate taps using
    firdes.bandpass(...) or firdes.complex_bandpass(...)
---
 gr-filter/grc/CMakeLists.txt                     |  1 +
 gr-filter/grc/filter_block_tree.xml              |  1 +
 gr-filter/grc/variable_band_pass_filter_taps.xml | 97 ++++++++++++++++++++++++
 3 files changed, 99 insertions(+)

diff --git a/gr-filter/grc/CMakeLists.txt b/gr-filter/grc/CMakeLists.txt
index e2df15b..b31b404 100644
--- a/gr-filter/grc/CMakeLists.txt
+++ b/gr-filter/grc/CMakeLists.txt
@@ -47,6 +47,7 @@ install(FILES
     filter_root_raised_cosine_filter.xml
     variable_low_pass_filter_taps.xml
     variable_high_pass_filter_taps.xml
+    variable_band_pass_filter_taps.xml
     DESTINATION ${GRC_BLOCKS_DIR}
     COMPONENT "filter_python"
 )
diff --git a/gr-filter/grc/filter_block_tree.xml 
b/gr-filter/grc/filter_block_tree.xml
index 4442343..eac192a 100644
--- a/gr-filter/grc/filter_block_tree.xml
+++ b/gr-filter/grc/filter_block_tree.xml
@@ -33,6 +33,7 @@
       <!-- FIR filter tap generators -->
       <block>variable_low_pass_filter_taps</block>
       <block>variable_high_pass_filter_taps</block>
+      <block>variable_band_pass_filter_taps</block>
       <!-- FIR convenience filters -->
       <block>low_pass_filter</block>
       <block>high_pass_filter</block>
diff --git a/gr-filter/grc/variable_band_pass_filter_taps.xml 
b/gr-filter/grc/variable_band_pass_filter_taps.xml
new file mode 100644
index 0000000..6cdfcc0
--- /dev/null
+++ b/gr-filter/grc/variable_band_pass_filter_taps.xml
@@ -0,0 +1,97 @@
+<?xml version="1.0"?>
+<!--
+#######################################################
+# Convenience wrapper for calling firdes.band_pass(...)
+# or firdes.complex_bandpass(...)
+#######################################################
+ -->
+<block>
+  <name>Band-pass Filter Taps</name>
+  <key>variable_band_pass_filter_taps</key>
+  <import>from gnuradio.filter import firdes</import>
+  <var_make>
+self.$(id) = $(id) = firdes.$(type.fcn)($gain, $samp_rate, $low_cutoff_freq, 
$high_cutoff_freq, $width, $win, $beta)
+  </var_make>
+  <var_value>firdes.$(type.fcn)($gain, $samp_rate, $low_cutoff_freq, 
$high_cutoff_freq, $width, $win, $beta)</var_value>
+  <make></make>
+
+  <param>
+    <name>Tap Type</name>
+    <key>type</key>
+    <type>enum</type>
+    <option>
+      <name>Real</name>
+      <key>taps_real</key>
+      <opt>fcn:band_pass</opt>
+    </option>
+    <option>
+      <name>Complex</name>
+      <key>taps_complex</key>
+      <opt>fcn:complex_band_pass</opt>
+    </option>
+  </param>
+  <param>
+    <name>Gain</name>
+    <key>gain</key>
+    <value>1.0</value>
+    <type>float</type>
+  </param>
+  <param>
+    <name>Sample Rate (Hz)</name>
+    <key>samp_rate</key>
+    <value>samp_rate</value>
+    <type>float</type>
+  </param>
+  <param>
+    <name>Low Cutoff Freq (Hz)</name>
+    <key>low_cutoff_freq</key>
+    <type>float</type>
+  </param>
+  <param>
+    <name>High Cutoff Freq (Hz)</name>
+    <key>high_cutoff_freq</key>
+    <type>float</type>
+  </param>
+  <param>
+    <name>Transition Width (Hz)</name>
+    <key>width</key>
+    <type>float</type>
+  </param>
+  <param>
+    <name>Window</name>
+    <key>win</key>
+    <value>firdes.WIN_HAMMING</value>
+    <type>int</type>
+    <option>
+      <name>Hamming</name>
+      <key>firdes.WIN_HAMMING</key>
+    </option>
+    <option>
+      <name>Hann</name>
+      <key>firdes.WIN_HANN</key>
+    </option>
+    <option>
+      <name>Blackman</name>
+      <key>firdes.WIN_BLACKMAN</key>
+    </option>
+    <option>
+      <name>Rectangular</name>
+      <key>firdes.WIN_RECTANGULAR</key>
+    </option>
+    <option>
+      <name>Kaiser</name>
+      <key>firdes.WIN_KAISER</key>
+    </option>
+  </param>
+  <param>
+    <name>Beta</name>
+    <key>beta</key>
+    <value>6.76</value>
+    <type>float</type>
+  </param>
+  <doc>
+    This is a convenience wrapper for calling firdes.band_pass() or 
firdes.complex_band_pass()
+
+    The beta paramater only applies to the Kaiser window.
+  </doc>
+</block>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]