Coefficient reloading and reordering –4, Figure 4–2, Coefficient reloading and reordering – Altera FIR Compiler User Manual
Page 46
4–4
Chapter 4: Functional Description
FIR Compiler
© May 2011
Altera Corporation
Coefficient Reloading and Reordering
All of the FIR Compiler structures allow multiple coefficient sets, and the filter can
switch between coefficient sets dynamically. Additionally, while the filter uses one
coefficient set, you can update other sets. Therefore, your filter can switch between an
infinite number of coefficient sets.
To maximize silicon efficiency, coefficients are not stored in their natural order.
Reordering is performed automatically during the initial design. However, if the filter
coefficients are reloadable, any new coefficient set that you want to reload during the
filter operation must be reordered before the reload. A C++ program that can be used
to reorder coefficients is provided. A precompiled executable for Windows is also
provided.
The program can be found in <install path>\fir_compiler\misc. The C++ source code
file is named coef_seq.cpp and the executable program (for the Windows operating
system) is coef_seq.exe. You can add the source code to your coefficient generation
program, or use the executable file to re-order the coefficients.
The command to use
coef_seq.exe
is:
coef_seq.exe
<path>/
input.txt
<path>/
output.txt
<FIR structure>
<coefficient store> <allow or disallow symmetry> <number of calculations for MCV|
coefficient bit width for others> <number of coefficient sets> <filter rate> <filter factor>
<coefficient bit width>
1
You should include the directory path with the input and output coefficient
file names, as indicated above.
Figure 4–2. Six-Tap Symmetrical FIR Filter
Data In
Data Out
Z
-1
C
0
Z
-1
C
1
C
2
Z
-1
Z
-1
Z
-1
Z
-1