-1

I used the Matlab Filter Design tool to create a lowpass filter bank. I exported the bank into a Simulink model. With double precision everything works fine. But if I convert the filter into fixed-point arithmetic with the Filter Design tool, the output signal is just noise or zero.

Originally, I wanted to create a VHDL filter for an int16 audio signal. But eigther fi(1,16,0) or some other fixed-point configuration does work.

fixed-point settings

testbench and input signal settings

output signal

1 Answers1

0

Many typical IIR filter configurations require more bits of precision and a greater dynamic range for the intermediate and feedback terms than for the input and output. Depending on the filter type, the number of extra bits needed can be roughly proportional to the ratio between the sample rate and the filter cut-off frequency or to the steepness of the transition band. To debug, you might want to try printing out those intermediate terms to inspect and make sure they don't overflow or underflow.

hotpaw2
  • 70,107
  • 14
  • 90
  • 153