Implementing a standart audio filter

Status
Not open for further replies.

isopropanol

New member
Hi

I'd like to create an audio filter using the teensy audio tool.
This lowpass filter should have it's center frequency set at 120 Hz with a roll-off of 18dB /octave and same phase response as analog filters. Is this possible with teensy?

Regards Fred.
 
Currently the state variable filter is probably your only good option. The biquads don't work great for really low corner frequencies, but maybe worth a try anyway.

Maybe you can end up with something similar to a particular (unspecified) analog filter.
 
Okay I'll have to test it.
So is it still possible with the biquad filter to get a 6/12/18 dB per octave roll-off? I'm not sure what "stage" means, propably stage 0 is 6dB, stage 1 is 12dB etc.
 
That is typically the number of second-order sections (biquad). Hence 4 stages implements 4 biquad sections in series. That would equate to an 8th order IIR.

Look at an elliptical filter design. They roll off much faster than butterworth. Chebyshev would be my 2nd.
 
After re-reading the OP, wouldn't you just want a first, second, and third order IIR to give you 6,12,18dB/oct rolloffs? A butterworth filter meets those specs. All you would need is to come up with coeffs, which is definitely something you can implement with the biquad block.
 
In my dream world, where there's a *lot* more programming hours in every day, I'd love to create a nice web GUI for configuring these filters. It would export a chuck of code for the filter coefficients. It'd also do some magic to arrange the stages so higher-Q stages come later, so their gain > 1.0 at certain frequencies wouldn't be able to cause clipping inside the filter. Or if a response with passband gain is chosen, at least the user would be given some visual indication and maybe helpful message in the exported code about allowable signal levels.

I also want to add a hires biquad, which would use all 64 bit coefficients and internal representation. Hopefully that would allow any filter response to be done easily, and the GUI would of course automatically guide people on whether the fast object or the highres one would be needed to implement their desired response.

If only there were more hours in the day....
 
Status
Not open for further replies.
Back
Top