Jump to content
  • 0

Problem in fir compiler 5.0 core


Bushra

Question

I am struggling with the problem of getting clipped filter output...everything is ok..core is working fine as when i input the simple noisy sin wave it gives the correct filtered output...but when i input the real and imag signal to two different cores it gives the clipped output...plz do help me regarding this coz i am struggling with this from many weeks..

 

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Just to make certain we are talking about the same thing, I understand "clipping" to be an artifact of an internal overflow within the filter.  The output is then mapped to the maximum possible output value.  This requires over flow detection, and saturation on overflow to accomplish.  You can tell this is happening very easily by looking at a histogram of the data.  That histogram will have a disproportionate number of samples at the extreme values of the representation.  Hence, for 8'bit math, you'll get too many values at 8'h7f or 8'h80 (or 8'h81--depending on the implementation).

This is different from over-driving, where the amplifier is driven outside of its linear region.  The effect can look similar, but the over-driving effect is an analog effect, whereas clipping is digital.  In this case, you would get a disproportionate number of samples "near" the limits or your representation, but not necessarily at the limits.

Both clipped and overdriven audio will sound distorted (if you listen well), but will generally be recognizable.  They won't sound "noisy".

This is different from the  "ticking" effect the poster was struggling with in the post you started responding to, and so would be off topic there.

Clipping will only take place if you have overflow protection within your filtering IP core.  If you don't put such protection into the core (like me), you'll get another effect characterized by discontinuities in the outgoing data.  Unlike other distortions caused by a bug in signaling, clipping is usually really easy to fix.  Clipping, or indeed any type of overflow, can be solved by any one of the below approaches.

  1. Reduce the amplitude of the input
  2. Reduce the magnitude of the filter coefficients, or
  3. Add more bits to the data representation within the filter.

Any of these solutions should fix a problem with clipping.

Dan

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...