Author |
Message |
Cynosure
Site Admin
Joined: Dec 11, 2010 Posts: 966 Location: Toronto, Ontario - Canada
Audio files: 82
|
Posted: Wed May 29, 2013 3:19 pm Post subject:
CMOS Active Filter Simulator Subject description: PWM Controlled Filter |
|
|
As some of you might already know, I have been sick for the past while and spent a lot of time in bed and not able to do much. This gave me lots of time to think about crazy CMOS ideas. I ended up bringing a breadboard and a little kit of part to bed and testing things out when I felt well enough to plugin chips and parts. Some of my ideas didn't work too well, but here is one that I think turned out ok.
The idea came to me when I read a post by JovianPyx where he mentioned switched capacitors. I came up with the idea of switching the capacitor in a RC filter on and off at a fast rate with a 4066. This would allow the circuit to be controlled by PWM - something that is a lot easier to create and modify in lunetta land than a control voltage. It also means that the PWM control combined with the fact that it can run on a +5/0V power makes it a perfect circuit to pair up with an Arduino.
EXPLANATION OF THE SCHEMATIC
PWM
The filter is controlled by any PWM source that is running above 30kHz. This frequency shouldn't be a problem for most CMOS circuits. I will leave it up to you to create your own way for generating the PWM source, but I used an Arduino that also provides a squarewave sound source using the Tone function. Other options include sending a squarewave through a highpass filter and buffering the output with a schmitt filter, using a boolean sequencer, or sending white noise through a schmitt filter or shift register to create random modulations.
RESONANCE EMULATOR
NOTE: This is NOT resonance, but rather an attempt to simulate the effect that resonance has on the wave shape. The attached scope shot shows how it actually looks when applied to a square wave. The little wiggles at the top and bottom of the wave look similar to the wiggles you get from resonance (but are audibly different). It is actually more like a ringmod.
The idea here is that the PWM is inverted, and then filtered to create a control voltage. That control voltage is then used to control a 4046 VCO. Since the PWM was inverted, the VCO tracks in the opposite direction of the PWM. This means that the VCO frequency goes down as the source pulse width is widened. This is important (explained two paragraphs down).
The VCO's output is used to control a 4066 that switches a cap to ground in a low-pass filter configuration. When the switch is open, the level of the sound dips a bit because it is being filtered. When the switch is closed, the level of the sound goes back up. This creates the wiggle in the wave shape.
Since the VCO tracks in the opposite direction of the source PWM, the frequency of the wiggles decreases as the pulse width increases and the frequency increases as the pulse with decreases. This simulates the frequency response of resonance by lowering as the filter is closed, and creates a zappy sound similar to that created by resonance.
FILTER
The sound then passes through three low-pass RC filters. The caps on the filters are switched in and out of the circuit using the three remaining switches from the 4066.
The switching is controlled by the PWM. When the pulse width is increased, more of the high frequencies are filtered to ground.
SIGNAL CLEANER
The final stage of the circuit is two low-pass RC filters with a high cutoff that filter out the noise created by the switching.
CONCLUSION
You can now have a CMOS passive filter that sounds and behaves in a similar fashion to a standard VCF. While it doesn't sound exactly the same (especially the resonance) it does have a unique charm to it. It is also a perfect thing to pair up with an Arduino.
THINGS TO TRY
Here are some things I plan to try when I feel up to it. If you get to it before me, then please post here to let me know how it works out.
1. Change the filter section to a standard switched capacitor configuration with a linear 4069 as a buffer.
2. Change the type of filter that is switched on and off to a simple active filter (maybe one based on a linear 4069).
3. Try to add a simple linear 4069 or darlington pair amp to compensate for the amplitude loss. Maybe control its amplification with the PWM.
4. Experiment with buffer and feedback options that would also add real resonance to the circuit.
Description: |
|
Filesize: |
29.51 KB |
Viewed: |
905 Time(s) |
This image has been reduced to fit the page. Click on it to enlarge. |
|
Description: |
Simulated Resonance (Modulation) |
|
Filesize: |
8.37 KB |
Viewed: |
546 Time(s) |
This image has been reduced to fit the page. Click on it to enlarge. |
|
Description: |
Sound demo of the CMOS Filter Simulator. |
|
Download |
Filename: |
cmos_filter_demo.mp3 |
Filesize: |
20.34 MB |
Downloaded: |
1323 Time(s) |
_________________ JacobWatters.com |
|
Back to top
|
|
|
Draal
Joined: May 18, 2010 Posts: 308 Location: Oak Park, IL
Audio files: 5
|
Posted: Wed May 29, 2013 3:47 pm Post subject:
|
|
|
Hey, hope you are doing better bro. Great ideas there for experimenting with. In my 4046 pitch tracker I noticed I can get auto wah style effects with the bigger cap in the loop filter; crude but useful. Your idea is a step up and worth a build. Never seem to have enough 4046's and 4066's !
Hell, the "clean up" section alone can fill a dead spot in my big lunetta. Toning down those square waves is becoming more important for me lately. Thanks! _________________ Zontar Prevails! |
|
Back to top
|
|
|
Cynosure
Site Admin
Joined: Dec 11, 2010 Posts: 966 Location: Toronto, Ontario - Canada
Audio files: 82
|
|
Back to top
|
|
|
Cynosure
Site Admin
Joined: Dec 11, 2010 Posts: 966 Location: Toronto, Ontario - Canada
Audio files: 82
|
|
Back to top
|
|
|
ezekiel
Joined: Oct 17, 2009 Posts: 30 Location: Columbus Ohio
|
Posted: Tue Jun 04, 2013 5:58 pm Post subject:
|
|
|
Great filter in CMOS +5V! Thanks!
I am going to have to build this just for the "smoothing" of harsh sounds. The "resonance" is a bonus.
(I tried making a 4066-switched capacitor filter a couple years ago. I was doing it all wrong.)
This is surely "sound of the year" for lunettas. I predict many cool additions and variations based on this. |
|
Back to top
|
|
|
Cynosure
Site Admin
Joined: Dec 11, 2010 Posts: 966 Location: Toronto, Ontario - Canada
Audio files: 82
|
Posted: Tue Jun 04, 2013 7:12 pm Post subject:
|
|
|
Thanks ezekiel. I am glad that you like it. I was a little surprised by the lack of comments so far, but I am happy to see that some people may find it useful.
The method I am using isn't even the "proper" way of doing a switched capacitor, but it gives the control required.
There is plenty of room for experimenting, so let me know if you come up with some interesting modifications and how you generate your PWM control.
Cheers! _________________ JacobWatters.com |
|
Back to top
|
|
|
analog_backlash
Joined: Sep 04, 2012 Posts: 393 Location: Aldershot, UK
Audio files: 21
|
Posted: Wed Jun 05, 2013 2:23 am Post subject:
|
|
|
Hi Cynosure.
Cynosure wrote: | I was a little surprised by the lack of comments so far, but I am happy to see that some people may find it useful. |
I meant to reply to this, but I hadn't got round to it. I will definitely be trying this out as an addition to my slowly evolving lunetta, but it will have to join the list of many things to breadboard. I also need to commit some breadboarded circuits to perfboard so that I have some spare room .
P.S. Hope you're feeling a bit better.
Gary |
|
Back to top
|
|
|
dougseidel
Joined: Feb 10, 2010 Posts: 74 Location: NJ
|
Posted: Wed Jun 05, 2013 6:22 am Post subject:
|
|
|
I also think this is a very cool design - i've been studying it. thanks for putting it up! I hope you feel better! _________________ http://soundcloud.com/douglasmseidel |
|
Back to top
|
|
|
Mikmo
Joined: Dec 01, 2005 Posts: 150 Location: Copenhagen - Denmark
|
Posted: Wed Jun 05, 2013 8:45 am Post subject:
|
|
|
This is very interesting.
There have been a lack of good CMOS filters.
Hope you get better soon. _________________ Stay Cool
Mikael
http://www.mikmo.dk |
|
Back to top
|
|
|
RingMad
Joined: Jan 15, 2011 Posts: 427 Location: Montreal, Canada
Audio files: 4
|
Posted: Fri Jun 14, 2013 3:27 pm Post subject:
|
|
|
Looks and sounds pretty interesting, Cynosure. I'll put it on my pile-of-circuits-to-try. Thanks for posting it. And I hope you feel better.
James. |
|
Back to top
|
|
|
|