Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Butterworth Filter (FPGA Module)

LabVIEW 8.5 FPGA Module Help
August 2007

NI Part Number:
371599C-01

»View Product Info

Filters one or more input signals using a lowpass or highpass IIR Butterworth filter.

The filter can be of order 1, 2, or 4.

Details  

Dialog Box Options
Block Diagram Inputs
Block Diagram Outputs

Dialog Box Options

ParameterDescription
Filter SpecificationsContains the following options:
  • Type—Specifies whether the filter type is Lowpass or Highpass.
  • Order—Specifies the filter order. You can select 1 (first order), 2 (second order), or 4 (fourth order).
  • Expected sample rate (S/s)—Specifies the sample rate of the input signal. This Express VI uses the rate you specify to calculate the normalized cutoff frequency, which is Cutoff frequency/Expected sample rate.
    Caution  The actual sample rate is specified elsewhere in the application. If the sample rate changes, you must change the Expected sample rate in this VI. Otherwise, this VI might not behave as expected.
  • Cutoff frequency (Hz)—Specifies the cutoff frequency of the filter. The allowable frequency range depends on the Expected sample rate you specify. The normalized cutoff frequency (Cutoff frequency/Expected sample rate) must be less than 0.5, which corresponds to the Nyquist frequency.
ImplementationContains the following options:
  • Input resolution—Specifies the range of the input signal in number of bits. This option determines the data type of the input signal and allows LabVIEW to optimize the implementation. Contains the following options:
    • 16 bit—Input data is represented as a signed 16-bit integer.
    • 24 bit—Input data range is limited to 24 bits aligned to the least significant bit, although this Express VI represents the data as a signed 32-bit integer. Select 24 bit if the input data is from a 24-bit input module.
    • 32 bit—Input data is represented as a signed 32-bit integer and covers a range that is greater than 24 bits.
  • Number of channels—Specifies the number of channels of input data to process. The calling VI must supply a sequential channel scan to input data on successive calls to this Express VI. The channel order must be fixed.
  • Show reset terminal—Specifies whether this Express VI includes a reset input on the block diagram to reset the filter at run time. You can save resources on the FPGA if you do not place a checkmark in the Show reset terminal checkbox.
  • Show configuration terminal—Specifies whether the VI provides an input terminal to enable loading new filter coefficients while the VI runs. When you configure the VI for a single channel, this input terminal is called scaled coefficients. When you configure the VI for multiple channels, this input terminal is called configuration.
    Note  Adding a configuration terminal increases the FPGA resource usage of this Express VI.
Filter ResponseDisplays the actual magnitude response of the filter.

Block Diagram Inputs

ParameterDescription
resetResets the filter states of the input data channel to zero if TRUE. Resetting the filter states does not reset the filter coefficients. This input is available only when you place a checkmark in the Show reset terminal checkbox on the configuration dialog box.
input dataSpecifies the input signal to filter. You can wire a 16- or 32-bit signed integer to this input depending on the Input resolution you specify in the configuration dialog box.
scaled coefficientsSpecifies single-channel filter coefficients to load at run time. Scaled coefficients is a fixed-size array of 32-bit signed integers. The size of the array depends on the order you specify. If the filter order is one, the array contains two elements. If the filter order is two, the array contains three elements. If the filter order is four, the array contains six elements.

The filter coefficients must correspond to the filter type and order you specify using the Type and Order options. You cannot alter the order or type of the filter at run-time.

This parameter is available only when you configure the VI for single-channel input and place a checkmark in the Show configuration terminal checkbox on the configuration dialog box.
configurationSpecifies the scaled coefficients to load at run time for the channel index you specify using the channel index element of this cluster. This Express VI continues to use either the default coefficients or the last coefficients you specified for the channel until you specify new coefficients. This parameter is available only when you configure the VI for multi-channel input and place a checkmark in the Show configuration terminal checkbox on the configuration dialog box.

Block Diagram Outputs

ParameterDescription
output dataReturns the filtered signal corresponding to the input data channel. If the actual result of the calculation exceeds the range of the data type, the output saturates, and output data returns the maximum numeric magnitude representable by the data type. The output has the same sign as the actual result of the calculation. For example, if the data type is I16 and the actual result of the calculation is −32,800, output data returns −32,768. Refer to Numeric Data Types for information about data type ranges.

Butterworth Filter Details

Refer to the Developer Zone for more information about the accuracy of the FPGA Math and Analysis VIs.


Resources


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit