ΣSigmaStudio Ask AI Русский Log in

Custom IIR block on Sigma Studio

SigmaDSP & SigmaStudio MaxAudioDSP Oct 20, 2015 00:00 4 replies Original on forum ↗
Subscribe
MaxAudioDSP Question
Oct 20, 2015 00:00

Hi everyone,

I wish I could have an all pass filter block with voltage control on frequency on Sigma Studio Library for a guitar phaser project

with Aida DSP.

So I've made a 1st order IIR filter path and I'm wondering if it's correct in theory. I've tested it a bit and it doesn't work as expected.

Basically I need to calculate only b0 coefficient, while a1 it's b0 inverted. It's a very simple project, however it seems don't work.

C=1e-6;

100<Rx<10000

Ts=1/48kHz

Any suggestions?

7f3f95503148f4848e53a9faf822da32.png
7f3f95503148f4848e53a9faf822da32.png
7f3f95503148f4848e53a9faf822da32.png-620x268.png
7f3f95503148f4848e53a9faf822da32.png-620x268.png
KJBob Reply
Oct 23, 2015 00:00

Starting with the first-order allpass formulas found at:

General (1st-Order) [Analog Devices Wiki]

For allpass filters,

A1 = 2.7^(-2 * PI * frequency/fs))

B0 = -gain * A1

B1 = gain

I tested these coefficients by typing them into a General Second-Order Filter, leaving its higher-order coefficients zero. They worked as expected. After several tries it's running on the hardware. The phase shift is inaudible to me, so I set up a test by mixing the filter output with the input audio, causing a noticeable response shift -- so it's doing something. The circuit is shown below and attached. I had to change the I2C address and DAC assignments to run it on a -1701MINIZ board -- of course you'll need to change these back.

Operation with 0.01 control input:

With 0.877 (1 KHz) input:

It should also be possible to get a more or less linear frequency control via interpolated lookup table or Taylor series approximation.

Best regards,

Bob

6aae80e5e452092bbc4b65a4dcb5019d.png
6aae80e5e452092bbc4b65a4dcb5019d.png
6aae80e5e452092bbc4b65a4dcb5019d.png-620x353.png
6aae80e5e452092bbc4b65a4dcb5019d.png-620x353.png
5d610ef6ccb50f1b45f36a0484e4436b.png
5d610ef6ccb50f1b45f36a0484e4436b.png
5d610ef6ccb50f1b45f36a0484e4436b.png-620x445.png
5d610ef6ccb50f1b45f36a0484e4436b.png-620x445.png
b118f2cf01304f20560e5b1cde8110b3.png
b118f2cf01304f20560e5b1cde8110b3.png
b118f2cf01304f20560e5b1cde8110b3.png-620x351.png
b118f2cf01304f20560e5b1cde8110b3.png-620x351.png
e071199f9e4f3a5ea960e2e703a4bc41.png
e071199f9e4f3a5ea960e2e703a4bc41.png
e071199f9e4f3a5ea960e2e703a4bc41.png-620x358.png
e071199f9e4f3a5ea960e2e703a4bc41.png-620x358.png
KJBob Reply
Oct 25, 2015 00:00

I just tried five cascaded voltage-controlled allpass filters -- now even I can hear the effect!

Bob

edd41b5ee1438f1ea3ba1b09e1f014ce.png
edd41b5ee1438f1ea3ba1b09e1f014ce.png
edd41b5ee1438f1ea3ba1b09e1f014ce.png-620x163.png
edd41b5ee1438f1ea3ba1b09e1f014ce.png-620x163.png
FluidKevin Reply
Mar 11, 2018 00:00

Hi again, Bob,

Do you have a version of this All Pass Filter I can try with my 1761? I'm looking for a decent Phaser guitar sound as well.

Thanks and best,

Kevin

KJBob Reply
Mar 12, 2018 00:00

Hello Kevin,

I didn't have a -1761 version already made, but it only took a few minutes to port it over. Problem is, I can't test it because my laptop and my hardware haven't been on speaking terms for a month now -- see:

https://ez.analog.com/thread/103919-usbi-comm-error-with-windows-10

Thus the attached project may need adjustments in the -1761 HW Configuration as well as in the signal flow before it works.

Best regards,

Bob