Functional description, Fir compiler, Number systems and fixed-point precision – Altera FIR Compiler User Manual

Page 43: Generating or importing coefficients, Chapter 4. functional description, Fir compiler –1

Advertising
background image

© May 2011

Altera Corporation

FIR Compiler User Guide

4. Functional Description

FIR Compiler

The FIR Compiler has an interactive wizard-driven interface that allows you to easily
create custom FIR filters. The wizard outputs IP functional simulation model files for
use with Verilog HDL and VHDL simulators.

Number Systems and Fixed-Point Precision

The FIR Compiler function supports signed or unsigned fixed-point numbers from 4-
to 32-bits-wide in two's complement and signed binary fractional formats.

The entire filter operates in a single number system. The coefficient precision is
independent of input data width; you can specify the output precision.

Generating or Importing Coefficients

You can use the FIR Compiler function to create coefficients, or you can create them
using another application such as MATLAB, save them as an ASCII file, and read
them into the FIR Compiler.

Coefficients can be expressed as floating-point or integer numbers; each one must be
listed on a separate line.

1

If you specify negative values for the coefficients, the FIR Compiler generates a two’s
complement signed number.

Figure 4–1

shows the contents of a sample coefficient text file.

The FIR Compiler automatically creates coefficients (with a user-specified number of
taps) for the following filters:

Low Pass

High Pass

Band Pass

Figure 4–1. Sample Filter Coefficients

-3.09453e-005
-0.000772299
-0.00104106
-0.000257845

0.00150377

.
.
.

0.00163125
0.00278506
0.00150377

-0.000257845
-0.00104106
-0.000772299
-3.09453e-005

Advertising