Low Pass Filter Example

From GNU Radio
Revision as of 15:24, 25 January 2022 by Mattcarrick (talk | contribs)
Jump to navigation Jump to search

Template:TutorialNavigation

This tutorial describes how to use a low-pass filter in GNU Radio.

The next tutorial, Designing Filter Taps, describes how to design a set of low-pass filter taps and apply them against a signal.

Creating the Flowgraph

Begin by adding the following blocks to the GRC work space:

  1. Signal Source
  2. Low Pass Filter
  3. Throttle
  4. QT GUI Frequency Sink
  5. QT GUI Range

Connect the blocks in the following manner:

LPFTutorialFlowgraphStart.png

The QT GUI Range block will be used to control the frequency of the Signal Source block. Double-click the QT GUI Range block and edit the properties:

  • Id: frequency
  • Default Value: 0
  • Start: -samp_rate/2
  • Stop: samp_rate/2

SetQTGUIRangeValuesFrequency.png

Click OK to save.

Double-click the Signal Source block and enter frequency from the QT GUI Range variable:

EditSignalSourceFrequency.png

Click OK to save. The flowgraph will look like the following image. Notice that the Low Pass Filter has a Cutoff Freq and Transition Width of 0:

FlowgraphWithZeroCutoffFrequency.png


Double-click the Low Pass Filter block and edit the properties:

  • Cutoff freq: samp_rate/4
  • Transition Width: samp_rate/8

SetLowPassFilterProperties.png


The flowgraph is now complete and should look like the following:

CompleteLPFFlowgraph.png


Run the Flowgraph

The flowgraph is now complete! Run the flowgraph. The QT GUI Frequency Sink will appear with a frequency slider bar:

RunLPFFlowgraph.png


Scroll-wheel-click on the QT GUI Frequency window and select Max Hold:

SelectMaxHold.png


The Max Hold option will retain and display the maximum value at each frequency until the the flowgraph is closed. Clicking through multiple values of the frequency slider bar at the top will show the low pass filter response:

LPFMaxHoldDisplay.png


The next tutorial, Designing Filter Taps, describes how to design a set of low-pass filter taps and apply them against a signal.