Post Go back to editing

Question about Biquad function

I am trying to implement a 8-pole butterworth filter on the ADSP-21479 and have a question about the biquad function provided by filter.h.

In the manual it states that, "For the vector versions of the biquad function, the five coefficients must be stored in the order: A2, A1, B2, B1, B0" and the number of coefficients is given as 5*sections.

My first question was if the coefficients need to be stored in the order
Stage1_A2, Stage1_A1, Stage1_B2, Stage1_B1, Stage1_B0,
Stage2_A2, Stage2_A1, Stage2_B2, Stage2_B1, Stage2_B0


Stage1_A2, Stage2_A2, Stage1_A1, Stage2_A1,

Stage1_B2, Stage2_B2, Stage1_B1, Stage2_B1,

Stage1_B0, Stage2_B0

My second question was when using Matlab to generate filter coefficients, specifically the butter function, is it valid to assume that the a and b in [b,a] = butter(n,Wn) are directly relatable to the A and B stated by the manual?

Thanks for your help

  • Certainly it is the first answer, if you have 8-pole butterworth filter, it will be consisted of four Biquad filter. Every filter has five coffies, you must reorder the coffies as A2, A1, B2, B1, B0.  

    Also have a question, when you generate the coffies from Matlab, you put the coffies into DSP , you must minus the denominator, the coffies are -A2,-A1,B2,B1,B0