| Author |
Message |
Steveg

Joined: Apr 23, 2015 Posts: 184 Location: Perth, Australia
|
Posted: Sat May 16, 2015 10:11 pm Post subject:
Three PWM controlled Oscillators Subject description: Obviously madness |
 |
|
I was having a read of synaesthesia's current controlled oscillators and I was thinking of other ways to achieve the result so I came up with the PWM controlled oscillator. You may ask what is the advantage of controlling the oscillator this way if you just need another oscillator to control it? Well one PWM oscillator can control a whole bank of different pitch oscillators. See PWM-1.
U1B is needed so that the output remains a square wave otherwise you get duty cycle control not frequency control as in PWM-2. The structure D1/D1/R1/U1B is an alternative OR gate that has a lower chip count if you are only building one or two oscillators. U1B could be any non-inverting gate which is needed to correctly provide a current sink.
You can also partially control the oscillator using something like PWM-3. The RV1A/R1/RV1B structure is intended to control the degree of modulation but I think it is wrong. I think I need to split R1 into two and connect the center to half the supply voltage. Using a second dual pot RV2A/B keeps the relative contributions of the two current sources proportional so they track nicely across the frequency range.
In all three cases the PWM frequency needs to be higher than the output frequency to get accurate control. If the two frequencies are close the you will get aliasing effects. With PWM-3 if the PWM source is a 50% duty square wave with a lower frequency than the output you will get frequency modulation of the output.
| Description: |
|
| Filesize: |
15.3 KB |
| Viewed: |
438 Time(s) |
| This image has been reduced to fit the page. Click on it to enlarge. |

|
| Description: |
|
| Filesize: |
13.38 KB |
| Viewed: |
446 Time(s) |
| This image has been reduced to fit the page. Click on it to enlarge. |

|
| Description: |
|
| Filesize: |
12.7 KB |
| Viewed: |
412 Time(s) |
| This image has been reduced to fit the page. Click on it to enlarge. |

|
|
|
|
Back to top
|
|
 |
Steveg

Joined: Apr 23, 2015 Posts: 184 Location: Perth, Australia
|
Posted: Sat May 16, 2015 10:14 pm Post subject:
|
 |
|
Aargh! The preview shows the attachments in reverse order to how thew will actually be displayed!  |
|
|
Back to top
|
|
 |
joshs
Joined: Dec 05, 2014 Posts: 32 Location: Home
|
Posted: Sun May 17, 2015 9:17 am Post subject:
|
 |
|
| So varying the duty cycle controls the frequency of the oscillators? Got any sound samples of this? Might be useful for use with atmega chips since they have PWM but not analog outs. |
|
|
Back to top
|
|
 |
elektrouwe
Joined: May 27, 2012 Posts: 147 Location: Germany
|
|
|
Back to top
|
|
 |
Steveg

Joined: Apr 23, 2015 Posts: 184 Location: Perth, Australia
|
Posted: Mon May 18, 2015 1:00 am Post subject:
|
 |
|
Ooh! thanks for that electrouwe! I hadn't thought in terms of Analog switches or tri-state.
I'll have to see if I can simplify the FM modulator to use 4066s.
@joshs - sorry I haven't actually built any of these yet. |
|
|
Back to top
|
|
 |
|