From: Tim Wescott on
On 07/29/2010 12:47 PM, Steve Pope wrote:
> Pete Fraser<pfraser(a)covad.net> wrote:
>
>> I am working on a project where I need to
>> implement 6-th order Butterworth low-pass
>> filters in an FPGA. In some the bandwidth is
>> low relative to the input data rate, whereas
>> others have higher bandwidth. I can use ScopeIIR
>> or Matlab to give me a good idea of coefficient
>> accuracy for any given ratio of bandwidth to
>> input sample rate.
>>
>> However, I'm not sure what data-path accuracy
>> I need (for 20-bit input / output accuracy).
>> Is there a rule-of-thumb I can use, or do I just
>> have to simulate the filter with real data and
>> see what gives me low enough noise?
>
> You should simulate the fixed-point filter. When simulating,
> you do not necessarily have to stimulate it with realistic data. I
> often will stimulate the design being tested with bandlimited noise, and
> measure the RMS error of output (relative to the same design, but in full
> floating-point). Plotting the RMS error (in dBc) vs. RMS input level
> gives you a very good idea of the dynamic range of the fixed point
> design.
>
>> I was planning on using biquads, but I'm not sure
>> whether I'm better off with DF1 or DF2 sections.
>
> You can do this, or you can use a lattice topology
> (called "ARMA" in matlab/fdatool), which is the most
> well-behaved topology.
>
> Steve

I did a quick search on "digital lattice filter" and didn't come up with
any really coherent discussion. There was lots of stuff about how to
use this or that lattice filter in this or that specialized application,
but not "this is DF1, this is DF2, this is a digital lattice filter...".

Got any references?

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Do you need to implement control loops in software?
"Applied Control Theory for Embedded Systems" was written for you.
See details at http://www.wescottdesign.com/actfes/actfes.html
From: Tim Wescott on
On 07/29/2010 12:23 PM, Pete Fraser wrote:
> I am working on a project where I need to
> implement 6-th order Butterworth low-pass
> filters in an FPGA. In some the bandwidth is
> low relative to the input data rate, whereas
> others have higher bandwidth. I can use ScopeIIR
> or Matlab to give me a good idea of coefficient
> accuracy for any given ratio of bandwidth to
> input sample rate.
>
> However, I'm not sure what data-path accuracy
> I need (for 20-bit input / output accuracy).
> Is there a rule-of-thumb I can use, or do I just
> have to simulate the filter with real data and
> see what gives me low enough noise?
>
> I was planning on using biquads, but I'm not sure
> whether I'm better off with DF1 or DF2 sections.

What Vladimir and Steve said. If you want to know for sure, make a
block diagram of the filter, put in summing junctions for the
quantizers, then find the transfer function from that summing junction
to the output. Do a Bode plot, and figure that your output noise will
be your quantization noise times the worst-case gain.

--

Tim Wescott
Wescott Design Services
http://www.wescottdesign.com

Do you need to implement control loops in software?
"Applied Control Theory for Embedded Systems" was written for you.
See details at http://www.wescottdesign.com/actfes/actfes.html
From: Steve Pope on
Tim Wescott <tim(a)seemywebsite.com> wrote:

>I did a quick search on "digital lattice filter" and didn't come up with
>any really coherent discussion. There was lots of stuff about how to
>use this or that lattice filter in this or that specialized application,
>but not "this is DF1, this is DF2, this is a digital lattice filter...".

>Got any references?

A classical description of lattice filters is in Rabiner and
Schafer, where they are called "lattice filters". But in
the Mathworks world, they are called "ARMA filters", or
sometimes "lattice ARMA" filters.

Something like the Mathworks Filter Design Toolbox has a passable
explanation of this topology.

Steve
From: gretzteam on
>I did a quick search on "digital lattice filter" and didn't come up with
>any really coherent discussion. There was lots of stuff about how to
>use this or that lattice filter in this or that specialized application,
>but not "this is DF1, this is DF2, this is a digital lattice filter...".
>
>Got any references?


Hi Tim,
I`ve sucessfully used this Matlab toolbox to design various lattice/wave
filters.
http://ens.ewi.tudelft.nl/~huib/mtbx/get_files_ga_ens.php

The user guide and reference guide (pfds) are very good at explaining what
is happening behind the scenes.

I would say that if the OP can realize his filter using a wave/lattice
topology, he most likely would save storage/area/bits. I`ve designed ~18
bits filters using a 20 bits datapath. Of course, all of this is less true
when using an off-the-shelf DSP.

Hope this helps,



From: Steve Pope on
gretzteam <gretzteam(a)n_o_s_p_a_m.yahoo.com> wrote:

> [attribution lost] wrote,

>>I did a quick search on "digital lattice filter" and didn't come up with
>>any really coherent discussion. There was lots of stuff about how to
>>use this or that lattice filter in this or that specialized application,
>>but not "this is DF1, this is DF2, this is a digital lattice filter...".

>>Got any references?

>Hi Tim,
>I`ve sucessfully used this Matlab toolbox to design various lattice/wave
>filters.

What's a wave filter?

>http://ens.ewi.tudelft.nl/~huib/mtbx/get_files_ga_ens.php

>The user guide and reference guide (pfds) are very good at explaining what
>is happening behind the scenes.

>I would say that if the OP can realize his filter using a wave/lattice
>topology, he most likely would save storage/area/bits. I`ve designed ~18
>bits filters using a 20 bits datapath. Of course, all of this is less true
>when using an off-the-shelf DSP.


S.