We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

AR# 36812

System Generator - FIR Compiler v5.0 - what methods exist to define coefficients in the FIR Compiler?


The FIR Compiler requires the user to define coefficients to define the Filter's frequency characteristics.

This is done by entering some representation of the coefficients in the 'Coefficient Vector' field in the FIR Compiler GUI.

There are several methods available using Matlab and System Generator to define the coefficients.


Method 1:Direct input

 In the blank to define the coefficients, the coefficients can be directly input as an array of values:
[-0.0053  -0.0028  0.0435  0.1695  0.2951  0.2951 0.1695  0.0435  -0.0028  -0.0053]

Method 2: Calling a Matlab filter function

Matlab has many built in functions available that can be used to design specific filter coefficients.

A couple of examples of these functions are FIR1 and FIRRCOS.

These functions can be used for the Coefficient Vector value.

An example using the FIR1 function is:

Method 3: Using the FDATool

The System Generator blockset includes a block that calls Matlab's FDATool.

When this block is used, it is convenient to use the FDATool to design filter coefficients.

When this block is included in the Sysgen design, the following command can be used for the Coefficient Vector:



Method 4: Calling a workspace variable
If the coefficients already exist in a variable in Matlab's workspace, it is possible to use the variable name for the Coefficient Vector to call the filter coefficients from the workspace.

AR# 36812
Date 03/23/2015
Status Active
Type General Article
  • Vivado Design Suite
Page Bookmarked