4
\$\begingroup\$

I have a project that I would like to get some help with and would like some things confirmed. I want to construct a 2nd order Low pass Sallen-Key filter with variable cut-off frequency using one or two potentiometers (variable resistor). The topology can be found here: Sallen-Key topology. Low pass filter - Application one

The filter should be able to take away all frequencies above 5kHz and all frequencies above 20kHz. I.e. it should be able to take away all frequencies above 5kHz when the potentiometer is set for a specific value (ohm) And take away all frequencies above 20kHz when the potentiometer is set for another specific value.

First of all, anyone have any tips or advice in how to begin the design? What components are the most critical and how do I determine them? I´m not really asking for any specific answers, more of guidelines in how to proceed. I have no restrictions in any component values (except the natural of course).

Moreover, I need the phase shift to begin as near the cut-off frequency as possible due to the fact that a phase shift more or less equals a time shift and I don´t want any of the passing frequencies (as few as possible at least) to be affected of this time shift. This mean a want a high Q-value, correct?

Also, one question about the cut-off frequency. The wiki-page states that the "natural frequency" is: $$ f_0 = \frac{1}{2*pi\sqrt{R_1R_2C_1C_2}} $$

So if I have understood this correctly, to get the cut-off frequency I just go down three dB from this (natural frequency)?

\$\endgroup\$
6
  • \$\begingroup\$ One aspect worth mentioning: depending on how your LPF is designed, shifting the cutoff frequency may change your gain as well. There are ways around it, but knowing that it's a side effect of some designs is always good. \$\endgroup\$
    – Jay Greco
    Jun 25, 2013 at 15:23
  • \$\begingroup\$ Please have a look at this question and its answers. It is realizing a high pass filter, but the basics principles are same and could be applied to a low pass filter easily. \$\endgroup\$ Jun 25, 2013 at 15:49
  • 1
    \$\begingroup\$ Sallen-Key or any reasonable analogue filter that you can tune will not take away all the frequencies above a certain point. You need to be pragmatic about this and recognize that a 2nd order SK filter will pass (0dB attenuation) lower frequencies up to a certain point called F (3dB attenuation) and at twice F the attenuation will be 12dB and 24dB at 4*F. There is no practical realization of a brickwall filter. You tell us what is acceptable,don't say you want a 2nd order SK unless you know what to expect. \$\endgroup\$
    – Andy aka
    Jun 25, 2013 at 16:22
  • 1
    \$\begingroup\$ If this is audio, I would talk you out of worrying about phase. It might matter at the very low frequencies. There are for instance equalizers that have a phase adjustment for low bass, and that is basically a done with an all-pass filter. Above low bass, nobody can hear phase. Certainly not in the 5 kHz to 20 kHz range. 90 degrees is a quarter of a wavelength. At 5 kHz, that is a 50 microsecond delay. Graphic equalizers mess with the phase throughout the audible spectrum; they are used anyway because nobody cares. \$\endgroup\$
    – Kaz
    Jun 25, 2013 at 20:21
  • \$\begingroup\$ In fact, the entire high end above 5 kHz or so can be filtered out completely and reconstructed as a fake by extrapolating the lower order harmonics and the original frequency envelope: en.wikipedia.org/wiki/Spectral_band_replication \$\endgroup\$
    – Kaz
    Jun 25, 2013 at 20:22

3 Answers 3

5
\$\begingroup\$

The -3dB point is your cutoff frequency. It's just standard practice to define it that way. In order to find what your values should be, I'd go with equal element implementation (it's simpler, and you can correct for gain with a simple gain stage later if you need to). Choose R1=R2, C1=C2, and pick a value for either R or C. This yields the following formula for the cutoff frequency: $$f_0=\frac{1}{2\pi RC}$$ I generally choose a value of C initially, as it's easier to find or make a resistor with a strange value, whereas it's more difficult with capacitors. So, set your cutoff frequency equal to f0, and solve for R.

Here's an example: let's say I want a LPF with f0=250 Hz. I'll choose C to be 0.1 micro and solve for R. $$250=\frac{1}{2\pi RC} \rightarrow 250=\frac{1}{2\pi R(0.1x10^{-6})}\rightarrow R\approx6400\Omega.$$

From there, all you need to do is implement your circuit. Once you know what your value for R is supposed to be, you can use a dual-channel potentiometer that has the correct resistance within it's range in place of the two resistors (for the above example, something like a 10k ohm potentiometer would do the trick). This will allow you to change your cutoff frequency, since it's based upon both R and C.

Edit: As Matt Young suggested in the comments, adding a resistor in series with the potentiometer will set the maximum cutoff, and prevent shorts. It's an excellent addition to the circuit, and will keep some sanity when adding the potentiometers.

\$\endgroup\$
3
  • 2
    \$\begingroup\$ Put a resistor the size of your smallest value in series with the rheostat configured pot. That will set your maximum value, and prevent shorts. \$\endgroup\$
    – Matt Young
    Jun 25, 2013 at 16:35
  • \$\begingroup\$ Thanks Jay and Matt for your inputs! Very appreciated, I must say. A couple of questions more though. How does the value(s) of the capacitors matter? I mean, what difference, if any, will it be if I randomly choose 1nF compared to 0.1micro? \$\endgroup\$ Jun 26, 2013 at 17:16
  • \$\begingroup\$ And one more regarding the formula for the cut-off frequency. The one you gave there $$f_o = \frac{1}{2\pi RC}$$ is based on the one Wiki states for the "natural frequency" (because you´ve set the Cs and Rs equal), correct? But what is the difference between this "natural" and the cut-off frequency? \$\endgroup\$ Jun 26, 2013 at 17:26
3
\$\begingroup\$

The example in Wiki gives you a low pass filter at 15.9kHz - so start with that.

enter image description here

C1 = C2 = 1nF

R1 = R2 = 10k

Because R1 = R2 and C1 = C2 then Q = 0.5

The values of C1 and C2 (=C) are fine, so the question is what value should the resistors be for a 5 to 20kHz filter. (a much simpler problem)

Provided we keep R1 = R2 = R

Then w = 1/CR

for 5kHz

     2 *pi*5000 = 1/CR
              R = 32K (approx)

for 20KHz

      2 * pi*20000 = 1/CR 
                 R = 8k (approx)

By using a ganged variable resistor you can change both resistance values at the same time which will maintain the Q value.

enter image description here

\$\endgroup\$
1
  • 3
    \$\begingroup\$ Put a resistor the size of your smallest value in series with the rheostat configured pot. That will set your maximum value, and prevent shorts. \$\endgroup\$
    – Matt Young
    Jun 25, 2013 at 16:35
0
\$\begingroup\$

Without working out the math for you, this is often harder than it seems it should be. It's probably not solvable just by changing one resistor for a pot, and you probably don't want to start using varicaps. Do you really need continuous change, or do you really need two different cutoffs. If you need two cutoffs, I suggest gang-switching however many components you need to, or maybe even building two separate filters and switching the outputs.

Also, keep in mind that a two pole filter is not a magic device that cuts off frequencies like a brick wall. The cutoff slope will be -40dB/decade, which may or may not be enough to meet your need.

Another approach would be to use a switched capacitor filter with more poles, and change the clock frequency to change your cutoff.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.