DSPRelated.com
Forums

FIR coefficients

Started by jack kilby November 24, 2003
Fred Marshall wrote:

> "Randy Yates" <yates@ieee.org> wrote in message > news:THcxb.23273$Wy4.2940@newsread2.news.atl.earthlink.net... > >>jack kilby wrote: >> >>>Hello all, >>> Thanks for all of your responses.Kindly look in to the coeefficients >>>and help me cross the river.a of now i work like this >>>datain = 15 bits >>>1 input to multiplier (from the data)= 15 bits >>>2 input to multiplier (from coeff) = 10 bits (i multiply by 2 power >>>10) >>>output of multiplier = 25 bits >>>input to accumulato =25 bits >>>i finally take the last 16 bits out.... >> >>Hi Jack, >> >>If the coefficients are only 10 bits long, then multiplying the >>real coefficients below by 1024 (2^10) will overflow the largest >>one: >> >> round(0.538 * 1024) = 551. >> >>The largest value you can represent with a signed, two's complement >>10-bit number is 511. >> >>Perhaps this is your problem? > > > So, scale the coefficients by 511/0.538 = 949.8141264 or some other similar > number that might minimize the error in the coefficients or to directly > minimize the error in the filter response.
Ayup - that would fix it. -- % Randy Yates % "...the answer lies within your soul %% Fuquay-Varina, NC % 'cause no one knows which side %%% 919-577-9882 % the coin will fall." %%%% <yates@ieee.org> % 'Big Wheels', *Out of the Blue*, ELO http://home.earthlink.net/~yatescr