electro-music.com   Dedicated to experimental electro-acoustic
and electronic music
 
    Front Page  |  Articles  |  Radio
 |  Media  |  Forum  |  Wiki  |  Links  |  Store
Forum with support of Syndicator RSS
 FAQFAQ   CalendarCalendar   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   LinksLinks
 RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in  Chat RoomChat Room 
 Forum index » DIY Hardware and Software » Developers' Corner
Choosing a simple audio frequency sine wave generator
Post new topic   Reply to topic Moderators: DrJustice
Page 1 of 1 [8 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
thundarr



Joined: Jun 07, 2009
Posts: 124
Location: Newcastle upon Tyne

PostPosted: Sun Jun 07, 2009 12:59 am    Post subject: Choosing a simple audio frequency sine wave generator Reply with quote  Mark this post and the followings unread

Hello folks,

I recently started off in the world of audio DIY, half-way through assembling a Weird Sound Generator, and have been lurking on these forums a little as well as trying out various test circuits on a breadboard in the meantime.

Most of these test circuits have been based on combining 555 astable oscillators, but the square waves aren't too easy on the ear. I create slow, droning music currently using 'normal' instruments, and am going to try to create similar using some DIY circuits.

So here's the question: What method would you use to create reasonably clean adjustable audio-frequency sine waves from cheap components and a reasonably simple circuit? I have been looking at using a Wien bridge with a 327 incandescent bulb, combinations of light-sensitive resistors and LEDs, and various op-amps, but many of the circuits I stumble on are more suited to fixed-frequency generation, with multiple resistor/capacitor pairs that would need to be adjusted simultaneously to alter the frequency.
Back to top
View user's profile Send private message
JovianPyx



Joined: Nov 20, 2007
Posts: 1257
Location: West Red Spot, Jupiter
Audio files: 161

PostPosted: Sun Jun 07, 2009 7:08 am    Post subject: Reply with quote  Mark this post and the followings unread

Sinewaves can be created several different ways depending on the waveform one begins with. All have some problem or another.

Any waveform can be heavily filtered to get (mostly) just the fundamental's sinewave, but the amplitude will decrease as the frequency in increased.

There are various methods that use clever distortion of certain input waveforms to make sinewaves. These include diode and resistor "matrix" circuits. Waveform purity can be poor. Input waveform cannot be changed without losing the sinewave shape. Most of these use a triangle wave input. Another distortion method uses a CMOS inverter gate like a 4069UB to soft clip a triangle. Again, sinewave purity is difficult to attain.

Or you could use an oscillator IC like an 8038 - but these are difficult to voltage control (not impossible). This IC generates several waveforms, among them is sine.

A DAC can be used with a ROM to generate a sine using some digital cleverness.

However - I am going to guess that you really don't want a pure sinewave - they are actually a bit boring, especially when played alone. I will guess that what you really want is a lowpass filter - which will roll off the high harmonics of whatever you put into it. This will work with any waveform.

Another thing to do to make sounds more interesting is to use more than one (same waveform for both), but tune them slightly differently in pitch. This gives a familiar and interesting "phasing" sound.

My suggestion to you - build a voltage controlled lowpass filter. There are many designs, I like the state variable type - which can easily be reconfigured to make lowpass, highpass, bandpass and other shapes.

_________________
FPGA, dsPIC and Fatman Synth Stuff

Time flies like a banana.
Fruit flies when you're having fun.
BTW, Do these genes make my ass look fat?
corruptio optimi pessima
Back to top
View user's profile Send private message Visit poster's website
thundarr



Joined: Jun 07, 2009
Posts: 124
Location: Newcastle upon Tyne

PostPosted: Sun Jun 07, 2009 7:27 am    Post subject: Reply with quote  Mark this post and the followings unread

I was hoping to mix together several sine wave generators (mostly tuned near C in various octaves) and merge them into a constant drone to feed through a 700W bass amp, without any voice or rhythm to the sound, just pure notes droning on...

I guess I could settle for a triangular source, just not square or sawtooth, if a real sine wave generator is entirely impractical.

Do you think using a simple square wave oscillator with a lowpass filter would sound close enough?
Back to top
View user's profile Send private message
JovianPyx



Joined: Nov 20, 2007
Posts: 1257
Location: West Red Spot, Jupiter
Audio files: 161

PostPosted: Sun Jun 07, 2009 9:38 am    Post subject: Reply with quote  Mark this post and the followings unread

With enough filtering it can pass, but the filtering will also cause a drop in amplitude. If you won't be changing the frequency of the oscillator(s) then one can compensate for the amplitude loss with an amplifier (transistor or op-amp).

Look at the 8038 IC, it has a sinewave output that is fairly good - probably good enough that you want be able to tell the difference with your ears between a real sine and it's sine output.

Triangle waves are also good, they sound close to a sine to start with. Filtering will help a triangle too as will waveshaping with a CMOS 4069UB gate configured as a "linear amplifier" (the circuit and more info can be found in the data sheets for CD4069UB). There are also other ways to do the waveshaping from triangle to sine or near-sine.

_________________
FPGA, dsPIC and Fatman Synth Stuff

Time flies like a banana.
Fruit flies when you're having fun.
BTW, Do these genes make my ass look fat?
corruptio optimi pessima
Back to top
View user's profile Send private message Visit poster's website
thundarr



Joined: Jun 07, 2009
Posts: 124
Location: Newcastle upon Tyne

PostPosted: Sun Jun 07, 2009 9:52 am    Post subject: Reply with quote  Mark this post and the followings unread

Thanks a lot, I'll look into both of these right away Smile

I wonder if there's an easy way to frequency control a Wien bridge oscillator for something to try in the future... I think, to be honest, I just like the retro-ness of using an incandescent bulb. Wink
Back to top
View user's profile Send private message
JovianPyx



Joined: Nov 20, 2007
Posts: 1257
Location: West Red Spot, Jupiter
Audio files: 161

PostPosted: Sun Jun 07, 2009 10:33 am    Post subject: Reply with quote  Mark this post and the followings unread

A Wein bridge oscillator is probably one of the best oscillators for sine purity. However, it's not as easy to tune as other methods. A filter that self oscillates is also an excellent sinewave generator - but these can be tricky to get running. Also while retro has a cool factor, remember that an incandescent bulb has a limited lifetime and is sensitive to shock breakage. If you intend to gig with this, then that's something to consider.

You should determine and decide upon just how pure a sinewave you actually need. High purity is more difficult to come by and a few percent of distortion is not easily heard (if possible at all). My own work always tends toward a category of "good enough". why spend hours or dollars making something better than what is truly good enough? Personally, I've become a digital guy over the last few years and I can make some really good sinewaves with digital methods - I'll bet that you can't tell my digital sinewaves are digital in a blind test. Which goes back to "good enough". I would choose a method that is easy for you to understand (so you can fix it if it stops working) and has quality equal to or better than what your musical performance requirement is. You may find that the 8038 IC is your best friend in that regard. It sounds like the frequency will be fixed, so all you need is a pot for tuning. I believe that it has sine, triangle and square outputs available.

And anything that you need to control with a voltage is usually more complex than not needing voltage control.

_________________
FPGA, dsPIC and Fatman Synth Stuff

Time flies like a banana.
Fruit flies when you're having fun.
BTW, Do these genes make my ass look fat?
corruptio optimi pessima
Back to top
View user's profile Send private message Visit poster's website
Fenris



Joined: Jul 30, 2008
Posts: 109
Location: Horbury. UK
Audio files: 1

PostPosted: Sun Jun 07, 2009 4:50 pm    Post subject: Reply with quote  Mark this post and the followings unread

Hi there

heres a wein bridge circuit I use in conjunction with a passive ring mod to effect a voice modulator. The resistors marked in the schematic could be changed for a dual gang potentiometer to give you a greater range, R4 adjusts the amplitude the smaller trimpot is to adjust the symetry of the wave if the component pairs are slightly adrift. with the values given it has a frequency of around 30Hz. Hope it helps.

regards

Fenris


Wein_bridge.jpg
 Description:
Wein
 Filesize:  162.06 KB
 Viewed:  185 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

Wein_bridge.jpg


Back to top
View user's profile Send private message MSN Messenger
thundarr



Joined: Jun 07, 2009
Posts: 124
Location: Newcastle upon Tyne

PostPosted: Sun Jun 07, 2009 6:22 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thanks, you have both given me a lot to think on Smile
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Moderators: DrJustice
Page 1 of 1 [8 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
 Forum index » DIY Hardware and Software » Developers' Corner
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
e-m mkii

Please support our site. If you click through and buy from
our affiliate partners, we earn a small commission.


Forum with support of Syndicator RSS
Powered by phpBB © 2001, 2005 phpBB Group
Copyright © 2003 through 2009 by electro-music.com - Conditions Of Use