Lattice Semiconductor Parallel FIR Filter User’s Guide
8
Decimation
Decimation is downsampling of the data stream. In a simple decimation filter with decimation ratio ‘D’, every D
th
sample of the input is sent to the output. The danger with downsampling is that aliasing can occur if the input signal
is not band-limited to 1/D of the original bandwidth. Therefore, to prevent aliasing, it is necessary to do a lowpass
filtering before downsampling. The decimation filter implementation is, therefore, a cascade of a lowpass filter and
a downsampler. The implementation of this is similar to a normal FIR, except that D - 1 samples are skipped at the
output, after every valid output. The output data rate is 1/D
th
of the input rate. The arithmetic resources are reused
in this design, as it is not necessary to compute an output for every input sample.
The output signal, ordy, goes high during the first cycle of each data output. For, complex-serial mode, there is an
additional output, real_out, which goes high during the first cycle of every real part of the complex data.
The timing diagrams for two decimation filter implementations are shown in Figures 6 and 7.
Figure 6. Timing for Real or Complex-parallel, Decimation Mode (Ratio = 3)
Figure 7. Timing for Complex-serial, Decimation Mode (Ratio = 3)
Interpolation
Interpolation is the reverse process of decimation. In this mode, the data is upsampled. For an interpolation ratio U,
U - 1 ‘zeros’ are introduced between any two consecutive samples and the resulting expanded stream is passed
through a lowpass filter. The operational environment of an interpolation filter is similar to a regular FIR filter, except
clk
din
1
2
3
4
5
6 7
1
4
internal data
processing
dout
1
ordy
4x
x
internal data
processing
clk
1
4
din
1r 1i
2r
2i 3r
3i
4r 4i
irdy
5r
5i
6r 6i
7r 7i
7
x
dout
ordy
1r
1i
real_out
4r
xx
x