Coefficient scaling –2, Coefficient scaling – Altera FIR Compiler User Manual
Page 44

4–2
Chapter 4: Functional Description
FIR Compiler
© May 2011
Altera Corporation
■
Band Reject
■
Raised Cosine
■
Root Raised Cosine
■
Half Band (low pass)
You can adjust the number of taps, cut-off frequencies, sample rate, filter type, and
window method to build a custom frequency response. Each time you apply the
settings, the FIR Compiler calculates the coefficient values and displays the frequency
response on a logarithmic scale. The coefficients are floating-point numbers and must
be scaled.
The values are displayed in the Coefficients scroll-box, of the Coefficients Generator
Dialog
box, refer to
.
When the FIR Compiler reads in the coefficients, it automatically detects any
symmetry. The filter gives you several scaling options, for example, scaling to a
specified number of bits or scaling by a user-specified factor.
The scaled coefficients are displayed in the Time Response & Coefficient Values tab
of the Parameterize FIR Compiler page, refer to
Coefficient Scaling
Coefficient values are often represented as floating-point numbers. To convert these
numbers to a fixed-point system, the coefficients must be multiplied by a scaling
factor and rounded. The FIR Compiler provides five scaling options:
■
Auto scale to a specified number of precision bits—Because the coefficients are
represented by a certain number of bits, it is possible to apply whatever gain factor
is required such that the maximum coefficient value equals the maximum possible
value for a given number of bits. This approach produces coefficient values with
the maximum signal-to-noise ratio.
■
Auto with a power of 2—With this approach, the FIR Compiler selects the largest
power of two scaling factor that can represent the largest number within a
particular number of bits of resolution. Multiplying all of the coefficients by a
particular gain factor is the same as adding a gain factor before the FIR filter. In
this case, applying a power of two scaling factor makes it relatively easy to remove
the gain factor by shifting a binary decimal point.
■
Manual—The FIR Compiler lets you manually scale the coefficient values by a
specified gain factor.
■
Signed binary fractional—You can specify how many digits to use on either side of
the decimal point (supported in the variable architecture only).
■
None—The FIR Compiler can read in pre-scaled integer values for the coefficients
and not apply scaling factors.