how to make a digital synthesize

Upload: waketek

Post on 05-Apr-2018

257 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/2/2019 How to Make a Digital Synthesize

    1/32

    How-To: Make a digital synthesizer

    posted May 1st 2008 11:55am by loganwilliamsfiled under: how-to

    This weeks How-To comes from our newest contributor: Logan Williams.

    M-Audio VenomFast & Free Shipping. Auth. Dealer.The Hottest New Place To BuyGear.ProAudioStar.com/Smokin-Deals

    Expert Sleepers ES-3Control your modular and analogsynths from your ADAT portwww.expert-sleepers.co.uk

    Rotary Position SensorSENSOFOIL: Ultra-flat membranepotentiometer, standard & customwww.sensofoil.com

    Ads by Google Synthesizer Oscillator Synth Download VST Synth Synth Sampler

    Page 1 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    2/32

    This simple guide will show you how to build a digital synthesizer that generates and manipulates square waves.Your synthesizer will have one oscillator, which produces a variable pitch controlled by a potentiometer, as wellas an LFO which modulates that pitch at a variable frequency. The part count for this project is quite low, and itcan be built for under $20.

    Finding the Parts

    The first step in building this digital synthesizer is toprocure the parts that you will need. Most of these can bebought at RadioShack, but RadioShacks prices are often much more expensive than ordering online. All of theparts for this project can be purchased at Jameco, Digi-Key, orMouser. Weve provided Jameco part numbersbelow. If you dont mind waiting, this is the best way to order parts.

    Item Name RadioShack Jameco

    9V Battery Clip 270-325 $1.99 11280 $0.30

    100K Linear Potentiometer R2 271-092 $2.99 255696 $1.35

    1M Linear Potentiometer R3 271-211 $2.99 255582 $1.35

    50K Linear Potentiometer R4 271-1716 $2.99 255549 $1.35

    10K Linear Potentiometer R5 271-1715 $2.99 255522 $1.35

    Page 2 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    3/32

    9V Battery

    IRF 510 MOSFET Transistor Q1 276-2072 $1.99 209234 $0.69

    3.5mm Audio Connector 274-333 $2.99 109496 $0.53

    7805 5V Voltage Regulator IC1 276-1770 $1.59 51262 $0.20

    0.1 uF capacitor C1 272-135 $1.49 151118 $0.20

    1.0 uF capacitor C2 272-1055 $1.59 544956 $0.20

    40106 Hex Inverter IC2 Fairchild $0.00 785071 $0.4747K Resistor R1 271-1342 $0.99 690540 $1.00

    1N4148 Diode D1 276-1620 $2.59 1537969 $0.27

    Solderless breadboard 276-002 $14.99 20723 $9.85

    Not Pictured

    Item Name RadioShack Jameco

    22AWG Solid-core 278-1221 $5.99 36792 $6.59

    Amplified speakers

    Tools

    Wire strippers

    Note: The potentiometers and audio jack must be either taped or soldered to 22 AWG solid core wire. Solderingis highly recommended, as it produces a more secure connection.

    Creating an oscillator

    Before we can begin with the digital synthesizer, we must generate the correct voltage. Most of you will befamiliar with using a 7805 5V voltage regulator. It is very simple; connect the +9V from the battery to the left

    hand pin, ground the middle pin, and the right hand is +5V.

    The most basic circuit in any synthesizer is the oscillator. A square wave oscillator constantly alternates betweentwo voltages, in this case +5V and 0V. We have a logic inverter to create this, which operates quite simply; if itis given +5V in (a logic 1), it gives 0V out(a logic 0) and if it is given a logic 0, it gives a logic 1 as output. When the input and output are connectedtogether, it will oscillate rapidly between those two values: a 0 goes in, comes out as a 1, goes in, comes out as a0, and so on.

    The problem is that it oscillates much too fast. A resistor capacitor (RC) delay circuit can be added to slow itdown. This forces the output current to charge the capacitor before it can pass through to the input. The resultingbrief delay slows the oscillations to audible frequencies.

    To build the oscillator, assemble the schematic below on a breadboard.

    Page 3 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    4/32

    When done, the oscillator should look something like this:

    Page 4 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    5/32

    Connect one side of the audio jack to 0V and the other side to the output, and it will sound like this:

    Controlling the oscillator

    We can make things more interesting by allowing the user to change the frequency. We replace the constantresistor R1 with a potentiometer, such as the 100K R2. This is a simple change to do, and is reflected in thisaltered schematic.

    Page 5 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    6/32

    Page 6 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    7/32

    Now the oscillator sounds like this:

    Much more interesting. Try playing an actual song, if you dare.

    Duty cycle adjustment

    We can add some basic timbre control to make the oscillator more interesting. The duty cycle of a square waveis how long it spends at logic 1 vs. at logic 0. For example, a wave that spends 1 ms at +5V and 1ms at 0V percycle would have a 50% duty cycle. 1.5 ms at +5V and 0.5 ms at 0V would be a 75% duty cycle. To adjust thewaves duty cycle, we can add another potentiometer and diode to the circuit. When the input is high and theoutput is low, current will be able to flow through both potentiometers, decreasing the amount of time it takes tocharge the capacitor, and increasing the duty cycle.

    Page 7 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    8/32

    Page 8 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    9/32

    It should sound like this when completed:

    Creating an LFO

    A low-frequency oscillator (LFO) is an oscillator that oscillates very slowly, from 1 to 100 cycles per second.We will use an LFO to alternate the pitch of our oscillator between two different frequencies. This can be used

    for siren like sound effects, timbre control, or musical sequences.

    The circuit to control the LFO is slightly more complex than the ones we have used before. Because it uses acapacitor with 10x the capacitance, and a potentiometer with 10x the resistance, the oscillations are 100x slowerthan our first oscillator. The LFO connects to the gate of the IRF 510 MOSFET transistor. When the output ofthe LFO is +5V, the transistor connects its source and drain pins. With these pins connected, current can flowthrough the second potentiometer, increasing the pitch. When the LFO returns to 0V, the potentiometer isdisconnected, and the pitch drops back to its original level.

    Page 9 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    10/32

    Page 10 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    11/32

    Share this: 1

    There are quite a number of sounds that can be produced with the LFO, such as this:

    and this:

    Conclusion

    You have now made your own simple digital synthesizer. Keep experimenting with different control methods.The frequency is adjusted with just resistance, so almost anything can be used for an input. Try aphotocell, or aflex sensor. Try combining the LFO and the duty cycle adjustment. Try using it to actually make music! Wedlove to see what you come up with.

    Comments [93]

    tagged: digitalsynth, digitalsynthesizer, feature, howto, lfo, lowfrequencyoscillator, oscillator, synth

    Page 11 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    12/32

    Reader Comments

    Excellent article, this is something I have always wanted to try but never had the time to figure out how to do itmyself. Now I can finally get some hacks in!

    Are we going to see follow up articles dealing with filters, etc?

    Posted at 12:48 pm on May 1st, 2008 by Adrian

    the photo is in color? whats going on here?

    Posted at 1:11 pm on May 1st, 2008 by reza

    love to see more stuff like this, stuff I can actually put together!

    Posted at 1:26 pm on May 1st, 2008 by kellen

    This is great. I was showing a friend some basic electronics and had him hook a photocell to an oscillator. Thisis the obvious next step. I look forward to a howto on a microcontroller with a home built programmer.

    Posted at 1:29 pm on May 1st, 2008 by Dave

    tutorials? is this going to be a weekly recurring theme here on h.a.d.? I hope so! If so Id vote for tutorial onbuilding a digital thermostat, great project for dealing with micro controllers, LCD outputs relays, analog sensorinputs, as well as human interfaces and nice packaging.

    This synth mod is quite cool, its simple enough too that I might already have all the parts I need to build one!

    Posted at 1:30 pm on May 1st, 2008 by twistedsymphony

    Interesting. Anyone have any idea how low this thing could create a stable wave at? I tried once to make a tonegenerator with a simple circuit using a 555 timer, but it wouldnt go any lower than about 100Hz before it gotreally unstable. I ended up just using my computers soundcard with some tone generator software, which tookme down to 1Hz without any problems.

    www FullCom ass com Ads b Goo le

    Page 12 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    13/32

    Posted at 1:35 pm on May 1st, 2008 by Urza

    The horrible sound samples remind me of a cigarbox in which I soldered a transistor noisemaker. With about thesame irritation level. Early 80ies?

    Posted at 1:43 pm on May 1st, 2008 by Chris

    Twistedsymphony:

    While thats a great project for learning, its not a good one to do for use unless youve got a great budget andplenty of resources and time for testing. Heres the reasons:

    1. Measuring temperature. Is there a temperature rise in the thermostat? Is it constant? At what point do youmeasure the temperature and how fast does it react to an ambient change? All things you can deal with but counton many spins and a lot of burn and learn code.

    2. Failure mode. This is the big one. It would sure suck to come home and find your temperature set to 120. Youcan imagine a lot of possibilities here.

    I know this because a few years ago I thought Im going to build a power stealing programmablecommunicating thermostat and I did. After a TON of work, it worked almost acceptably, but I scrapped theproject when I realized it could burn down my house.

    Posted at 2:01 pm on May 1st, 2008 by Dave

    Nice! with ducty cicle, we can do a PWM controls!

    Posted at 2:13 pm on May 1st, 2008 by Fred DASP

    what a great tutorial! now for a diy resonant filter????

    Posted at 2:27 pm on May 1st, 2008 by ron sense

    Definitely best noisemaker project Ive seen (although I havent seen that many), and it really gave goodexplanations about how the stuff worked. Thanks!

    Posted at 2:54 pm on May 1st, 2008 by DaveB

    This is cool, except square waves arent very nice to speakers. Id like to see a synth that could do sine waves.

    My other concern is to create real music with this, youre going to need close to perfect pitch, or some sort ofautomated controller.

    Its been a while since I spent any time working on electronics, but would it be non-trivial to design an oscillatorthat doesnt use an RC network to determine pitch? Mainly, I ask because Id be interested in building a musicaldevice which could generate at least an octave of accurate pitches.

    Posted at 3:10 pm on May 1st, 2008 by Dirk

    Page 13 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    14/32

    Looks like an analog synthesizer to me, not a digital one.

    Posted at 3:40 pm on May 1st, 2008 by ulf

    sweet, i might actually try this one.

    Posted at 3:45 pm on May 1st, 2008 by tjhow

    This is great. Does anyone know a good place to get these parts in the UK?

    Posted at 4:00 pm on May 1st, 2008 by Flump

    OMG, Why isnt the picture in black and white like all the others??? This is scary Nice article

    Posted at 4:30 pm on May 1st, 2008 by Dustcrazy

    Dirk:

    It sounds like you need a simple microcontroller (pic, avr, msp430- pick your poison) connected to a keypad (orjust a bunch of buttons), a transistor and a speaker.

    The cool thing is that you could actually approximate a sine wave with an H bridge and pulse width modulation.Very few parts, easy to wire.

    That would be a fun little project.

    Posted at 4:36 pm on May 1st, 2008 by Dave

    great how-to! I actually can build this one, and I love things to to with sound! I would love to see more like this!

    Posted at 4:44 pm on May 1st, 2008 by will

    analogue

    Posted at 4:45 pm on May 1st, 2008 by Sean

    @dave

    so just program the uC to output such and such frequency with such and such button press? I figured thatd bethe quickest route to take.

    As for approximating a sine wave with an h-bridge, after some quick reading it looks like that thered be nosmoothing of the signal, so instead of just slamming the cone (of the speaker) forward, it would also slam itbackwards. Wouldnt that be more harmful than a straight square wave?

    If Im wrong, do let me know.

    Page 14 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    15/32

    Posted at 4:59 pm on May 1st, 2008 by Dirk

    This is AWESOME! As many other people have said, alwasy wanted to do this, and glad to see some simplerhacks on the site for dumb people like me! :-)

    You say the frequency is adjusted with just resistance, so almost anything can be used for an input does

    this mean I could use my guitar to somehow trigger the thing?

    Posted at 5:14 pm on May 1st, 2008 by Peanut

    Looks cool but there is no way that I could get this one work.

    Posted at 5:36 pm on May 1st, 2008 by Jon Richards

    #17: Search for some Class D audio drivers. When designed properly, using PWM to drive a speaker is notgoing to break it.

    Posted at 6:25 pm on May 1st, 2008 by ed

    it is an analog synth, just outputing a digital signal because its a square wave.

    Re: pitch control, modular synth designers have been making voltage controlled oscilators for decades withoutmicroprocessors. Square, Saw, Sine, ring mods, VC filters, etc. There are tons of schematics on line if you areinterested, and you can pick up a cheap midi->control voltage converter to hook up to your computer or midikeyboard.

    Posted at 7:31 pm on May 1st, 2008 bypemdasi

    Cool!

    I did mine today, hopefully I had almost all the components.

    But there is a problem: you should NEVER connect pin 2 to a speaker, you need to double invert it, otherwisethe pitch will be different using other speaker (impedance changes)

    Posted at 8:39 pm on May 1st, 2008 by Gonzalo

    Im glad you guys enjoyed this project even if we cant seem to figure out the proper name for it.

    Posted at 8:41 pm on May 1st, 2008 by Eliot

    @gonzalo: yeah, I know. That is why I say that you should connect it to an amplified speaker, as then it will bebuffered.

    Posted at 9:26 pm on May 1st, 2008 by logan williams

    Page 15 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    16/32

    Great post! I would like to see more of these in the future. I still learning most of this stuff, and step wise articleswith explanations of the parts and design are wonderful. Keep up the good work!

    Posted at 12:12 am on May 2nd, 2008 by andy

    Ouch my ears. back to microcontrollers and stuff other than circuit-bending / crapiophile audio thanks!.

    Posted at 12:40 am on May 2nd, 2008 by John R

    for anyone looking to extend this, synthedit (http://www.synthedit.com/) might be helpful for prototyping.

    Posted at 7:07 am on May 2nd, 2008 by chris

    Well, no- speakers can only operate up to about 20kHz. Choose fets accordingly (fets that can run > 100kHz)and if you throw a higher duty cycle at 100kHz, its going to look to the speaker like a higher input voltage. Ifyou REALLY want to make sure that 100Khz square isnt buzzing the speaker at ultrasonic frequencies, you can

    put a RC filter on the way to smooth it out a little.

    Posted at 8:26 am on May 2nd, 2008 by Dave

    If you want to make a sine wave you just need to filter out all the odd harmonics. Easier said than donebut aninductor in series with the output should work.

    Posted at 8:48 am on May 2nd, 2008 by Fallen

    Featured on Packet Storm on the main page.

    packetstormsecurity.org

    Posted at 11:30 am on May 2nd, 2008 by w00tb0t

    Really Cool!! As a suggestion for followups!

    - how to modify the squarewave to become a sawtooth or sine- how to modify the circuit to use a control voltage instead of a pot (I think I have examples of this circuitsomewhere)

    Posted at 11:55 am on May 2nd, 2008 by th0mas

    Hehehe. Cool project. We should have learn that at school.Playing the two demos together is quiet funny too.

    Posted at 2:23 pm on May 2nd, 2008 by marc

    adding links to the music clips would be nice since I cant for some reason load them through the flash applet

    Page 16 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    17/32

    Posted at 9:09 pm on May 2nd, 2008 by andrew

    @dirk:

    If you get a handful of momentary switches and resistors in parallel you can make the R-C network generate anoctave of distinct pitches. Youd effectively be making a bunch of hard-coded resistances that are selectable

    instead of the linear sweep of the pot. It will be monophonic and youll probably have to do some work to tuneit, but thats the simplest way to do it IMHO.

    Also, Daves H-bridge idea would work *with* pulse width modulation, like he said originally. Without PWM,youre right, it would effectively just amplify the signal.

    Posted at 11:42 pm on May 2nd, 2008 by The One True Stickman

    This is going to be fun, I hope to see some addons to this. Filtering would be great, other types of OSC sources,etc Lets keep this one alive!!

    Cheers.

    Posted at 9:20 am on May 3rd, 2008 by Pat

    How many of these could you power off of one 9v battery if you modified the circuit? Im not veryknowledgeable about electronics, but Id like to have about twenty of the oscillators in one box, powered by aminimum number of batteries.

    It would be even cooler if you could use rechargeable AAs.

    Posted at 6:00 pm on May 3rd, 2008 by dalasv

    dalasv: You should be able to run quite a few, twenty no problem. Each 40106 only uses about 20 ma, max, Ithink, and each 40106 provides 8 different oscillators. The 7805 can regulate up to 1A of current.

    AAs? Sure, checkout Limor Frieds mintyboost schematic: http://ladyada.net/make/mintyboost/ . It can generate5V from 2xAA, and last longer then 1 9V battery as well.

    Posted at 6:53 pm on May 3rd, 2008 by logan williams

    the link to the radioshack 22AWG wire is incorrect, it links to their stranded 22awg wire. Here is the solid corewire:http://www.radioshack.com/product/index.jsp?productId=2049742&cp

    just so you dont get the wrong type if you are buying it from there.

    Posted at 7:01 pm on May 3rd, 2008 by will

    will: thanks, corrected.

    Posted at 8:12 pm on May 3rd, 2008 by logan williams

    Page 17 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    18/32

    Maybe just coincidence, but:Tristram Cary:created one of the firstelectronic music studios

    Dr Whotheme composerdead at 82

    April 28, 2008 02:03pmArticle from: AAP

    TRISTRAM Cary,the composer ofthe Dr Who theme tuneand a pioneer of electronic music,has died in Adelaideaged 82.

    Cary was also known for co-designing a synthesiserused by rock artists includingPink Floyd,The Who andRoxy MusicHe co-designed the VCS3 synthesiser,which became the must-have instrumentfor such avant-garde classical composers and rock artists asBrian Eno,The Who,Pink Floyd andKing Crimson..

    He founded the

    electronic music studio atLondons Royal College of Musicin 1967and,seven years latermigrated to Australiato establish a similar studio atthe University of AdelaidesElder Conservatorium of Music.

    The conservatoriums head of music technology studies,Stephen Whittington, said Carys contribution to musicwas impossible to quantify.

    He laid the foundations, Mr Whittington said today.

    Without him, we wouldnt have techno, hip-hop or any kind of musicwhich is sustained by technology.

    Cary, whose father was prominent Irish-born novelist Joyce Cary,came up with the idea of electronic and tape musicwhile a naval radar officer during World War II.

    Page 18 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    19/32

    He had a really unusual childhood, his father was an author and TSEliotand James Joyce were always coming around for tea, Mr Whittingtonsaid.

    After the war, the Americans, British and Germans had a huge amountof electronic gear which came onto the market and was incrediblycheap,

    Mr Whittington said.

    That is when he began fiddling with things.

    Cary composed for Hollywood feature films, television, theatreand concert music.

    In 1991, he was awarded the Medal of the Order of Australia (OAM)for services to Australian music.

    He died last week atthe Royal Adelaide Hospital.

    Posted at 9:26 pm on May 3rd, 2008 by bruce

    flump:

    Maplin are pretty good for electronic components. Although they may be a little on the pricey side.

    Very interesting tutorial though. I might have everything needed to make one of these already.

    Posted at 5:03 am on May 4th, 2008 byjack

    So, what are the logistics for creating a sine wave? Is it possible to create a true sine wave using a different typeof logic gate or something? I would imagine a slow-charge-slow-dump RC loop that might work, but Im not sohandy with the mental electronics planning.

    Posted at 12:00 pm on May 5th, 2008 by macgyver2210

    @macgyver:Not with a logic gate- the problem with gates is that theyre switching as fast as possible, giving as close to asquare wave as the hardware will allow. For a given frequency, you can do it with a filter, but since this is aninherently differing frequency, thats out too.

    If you dont mind analog circuitry, heres a link to a quadrature oscillator which will give you a nice sine wavewith a low parts count:

    http://www.play-hookey.com/analog/sine_wave_generator.html

    Posted at 2:57 pm on May 5th, 2008 by Dave

    you do the same thing basically using a 555 timer. i did this for a digital logic class. notes are known frequencesand can be found online. the 555 timer has i took 8 timers and using a formula and excel i used different

    Page 19 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    20/32

    resisters and capacitors and used push button switches to create a mini synth. the hardest part is troubleshootingwhen the notes arent correct.

    Posted at 4:54 pm on May 5th, 2008 by john

    i just built this and its awesome. sounds intergalactic. but id like to add a volume knob. any idea abt how thats

    done? i put a 10k linear potentiometer in line with the output but that doesnt seem to do anything.

    Posted at 3:45 am on May 7th, 2008 by leroy

    @anyone trying to work out if this is analogue or digital synth. Just because the output can be represented as 1sand 0s does not make it digital. This is as Lo-Fi analogue as you get. Id LOVE to see a similar project with arudimentary VCO. If there isnt one in 6 weeks when I get back from holidays I might work on it myself.

    Posted at 9:32 am on May 7th, 2008 by vespine

    Hello. Great project!Cant get it to work though. No sound at all.The voltage is transformed to 5V, so it works that far.Should there be voltage between pin 1 and 2 of the 40106 inverter or is there a way that I can check so it works?

    Posted at 11:02 am on May 8th, 2008 by Karlbe

    Never mind, it worked!I just had to invert the output once again as somebody already said here.

    Posted at 12:04 pm on May 8th, 2008 by Karlbe

    @karlbe:

    If its working, and your system is running at 5VDC, you should be able to set your DMM to read AC voltage,and you should see some voltage (youll probably see 3.5VAC unless you have a nice meter).

    If its NOT working, but the 40106 inverter is working correctly, you should see 5VDC difference between pin 1and 2.

    Best thing to do is take a DC and AC measurement from every pin on the 40106 to ground (the terminal of the9V). Report back here!

    Posted at 2:25 pm on May 8th, 2008 by Dave

    Is there a guide for beginners to this project? Im a beginner, and I really want to build my own synthesizer. Ibought all of my parts from a generic electronics supply shop, and I noted some differences from my parts to theparts shown on the breadboard circuit. Now I havent learned about the functional difference between a disccapacitor and a ceramic capacitor, but Id imagine that they are the same.

    If I am mistaken, please say so before I continue with this project. I intend to wire everything together as is(both on the circuit and as a circuit altogether), but this guide is pretty much designed for bread/printed circuitboard users.

    Page 20 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    21/32

    Now you may or may not think that Im crazy, but wired circuits are less prone to destruction when crushed and(when insultated) water damage than printed circuit and breadboards. Not only that, but I can make the circuitmore compact, which is what I am aiming for.

    tl;dr Im a beginner, I really want to build this project, but I need extra help. If help can be provided, that wouldbe great.

    On a side note, whats a good electronics site for people like me, who want to be able to understand a circuit like

    this (and other) circuits like professionals/hobbyists?

    Posted at 9:07 pm on May 10th, 2008 by some_person

    Bear in mind, nothing about this is actually digital. Its a completely analog synthesizer circuit.

    Posted at 12:54 am on May 11th, 2008 by wackyvorlon

    Hey thanks for the tutorial, I always wanted to build some circuit and now I did. yay

    Posted at 5:14 pm on May 17th, 2008 by dylan

    is it possible to get polyphony out of the single 40106? i cant get it to happen.

    Posted at 2:38 pm on May 18th, 2008 by dylan

    I just dont get I do think i understand breadboards or something because this is the umpteenth tutorial I tried tofollow and the umpteenth failure I have.http://www.flickr.com/photos/pandabrand/2529688175/ is a picture of what I am currently doing wrong. I put this together and I have no sound. If anybodys feels kind

    enough to show a idiot what hes doing wrong it would be greatly appreciated.

    Posted at 1:27 am on May 28th, 2008 by pandabrand

    @pandabrand:

    Hi. I just built this circuit. Im just getting started in electronics and I dont know nearly as much as anyone elsehere, but Ill try and help you. The first thing I notice is that it looks like you have resistor r1 and capacitor c1connected to a row which has nothing in it.

    As someone else mentioned, you will need to double invert the output to get sound. This just means that youwill need to connect pin 2 to pin 3 and then pin 4 will become your output. A diagram of the ic might helpexplain this better:

    http://www.alldatasheet.com/datasheet-pdf/pdf/50835/FAIRCHILD/CD40106BCN.html

    The output will need to be amplified for a speaker as the 5v the ic provides is not enough. To do this, I just tooka npn transistor, connected pin 4 to the base, 9v to the collector, and one wire of the speaker to the emitter. Thatmay not be the best way to do it, but it worked for me. The other wire of the speaker goes to ground.

    As for breadboards, heres a picture to help explain how they are connected:

    Page 21 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    22/32

    http://ece-www.colorado.edu/~mathys/ecen2250/lab01/breadboard90.png

    One thing that really helped me was going off of the schematic instead of the pictures. There are many sites thatwill teach the basics of reading circuit schematics, it is easy once you practice a bit. I hope I was able to help abit with my very limited knowledge.

    C1 should be connected to gnd and then to pin one of the hex inverter ic. Resistor r1 should be connected frompin 1 to pin 2.

    Posted at 1:04 am on May 29th, 2008 by anon

    @60Thanks so much. I totally was having a mental block about this and just couldnt get it together; your links andesp. the last comment were things that help me get over it. I now have aworking piece!!! thanks again.

    Posted at 3:07 am on May 31st, 2008 by pandabrand

    This is one of the best hackaday articles EVER

    Im going to put it is a tiny box and use it for live performances

    Posted at 10:20 pm on May 31st, 2008 by Levi Hall

    In answer to comment 12 by flump

    You can buy all these parts from Maplin electronics. Most major towns and cities in the UK have a Maplin shop

    Posted at 6:51 pm on Jun 15th, 2008 by Sparky

    Hi, I just found this post by accident while looking for some 40106 info.

    It looks and sounds really cool, and Ill definatly be trying this myself!

    thanks

    Posted at 2:56 am on Sep 18th, 2008 by squidfanny

    This works!!!!! THANK YOU SO MUCH. this was my first electronics project and it works beautifully. GreatJob on the Tutorial. THANK YOU THANK YOU THANK YOU!

    Posted at 3:55 pm on Sep 26th, 2008 by Jason

    Thanks again feller, works great!

    Ive combined the finished piece with a bent alien voice changer toy, which amplifies it very nicely

    Quick note though the final schematic doesnt correspond with the final photo. According to the photo pins 1& 2 are connected to 1meg pot (not 100k which the schematic states). I think there may have been a couplemore minor differences, but I just experimented on the breadboard until I got it to sound good.

    Page 22 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    23/32

    PEACE.

    Posted at 10:23 am on Oct 1st, 2008 by squidfanny

    Can someone suggest an amplified speaker because I dont know enough to know what I want to buy. I seethat hooking these circuits up to a the first speaker I found in a box of junk only produces a crackling when the

    clips are (dis)connecting but when I use an old ear-piece I can hear what I believe is the expected set of tones. Iwandered around a Radio Shack but didnt find anything that seemed likely.

    Posted at 1:08 pm on Oct 24th, 2008 by clweeks

    amplified speaker is one that has an amplifier built in (a volume knob etc) i shouldnt think a simple speakerwont have enuff power to be audible from this circuit (or be v. quiet) hope that helps :)

    Posted at 11:46 am on Nov 30th, 2008 by ne7

    THANK YOU very much for including convenient direct links to the partsas well as all the rest of the info,very much appreciated!

    Posted at 1:59 pm on Jan 4th, 2009 by mister newbie

    I ordered everything that you suggested, followed your directions and got it to work. Its really fun to workwith! Thanks for this resource! I would definitely use others like it in the future.

    I intend on using this and other resources I have gathered in a noise act that I am to do for my friends band.

    Posted at 8:16 am on Jan 9th, 2009 by PV

    This is great. To be honest, this is my first project, but my synth turned out fine. I also added a few push to breakswitches to chop the sound up a bit.

    Thank you very much for the tutorial.

    If anyone could point me the direction of a sine, sawtooth or triangle circuit, Id really appreciate it.

    Posted at 4:34 pm on Mar 7th, 2009 by DB

    can anybody identify the manufacturer of the breadboard for this project? i know there are hundreds of them out

    there but we are looking for this one..

    Posted at 2:21 pm on Mar 10th, 2009 by Mark

    hello im from argentine . i want to know a replacement for the mosfet transistor???????thanks and sorry for my english

    Posted at 7:22 am on Jun 4th, 2009 by gringus

    Page 23 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    24/32

    Im new to reading schematics

    At IC2P on the wire between connection 3 and the ground of the 7805T voltage regulator, the connections arelabeled 14DD (with a slash through the 4) and VSS (with a slash through the 2nd S). I realize that1,4,VDD, and VSS are all connections on the hex inverter, but I cant figure out what the slashes are for or ifDD is referring to VDD.

    Hope that wasnt too difficult to follow Any explanation?

    Posted at 12:15 am on Jun 19th, 2009 by Kyle

    awesome.

    Posted at 4:37 pm on Jul 13th, 2009 by ultimatenerd22

    Could I use a 7404 hex inverter instead of 40106?

    Posted at 10:29 am on Aug 19th, 2009 by Aro

    When ordering from Jameco,part number 690540 appears to be a 47 ohm resistor, not 47kohm resistor.

    The correct part seems to be 691260.

    If Im correct, you may want to update the parts list

    Posted at 1:01 pm on Sep 16th, 2009 by ilovegreenmonster

    is there any way i could run this to a computer,for example usb safely?

    Posted at 9:38 pm on Oct 16th, 2009 by MC MIC

    i totally made one of these today.i didnt have a breadboard, so i just went ahead and proceeded to dive right in(not recommended). but alas, ITWORKS!! im happy.. thank you for sharing you schematics

    Posted at 10:33 pm on Nov 12th, 2009 by DjFluorescent

    This is INFACT DIGITAL! it is NOT analog.. analog circuitry use Op Amps, not Inverters.. Hex Inverters aredigital. hope this clears things up

    Posted at 2:40 pm on Nov 25th, 2009 by DjFluorescent

    Is there an alternate schmitt trigger instead of the 40106 hex inverter??

    Page 24 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    25/32

    Posted at 10:07 am on Dec 5th, 2009 by Micky

    if one were to install in input jack (for the purpose of daisy chaining multiple LFO synths), where would that goon the circuit?

    Posted at 10:19 am on Dec 14th, 2009 by jamiewoody

    hi, im returning to confirm that the 47 resistor jameco link still hasnt been changed to 47K resistor. (THANKSilovegreenmonster) again, the current Jameco part# is 691260. the reason im doing this is that i thought i had a47K when i actually had a 47. this caused me much confusion when i tried to use the leftover hack-a-day partsfor a weird sound generator build. I highly recommend the music from outer space website for new synthbuilders. any suggestions for other sites with detailed walkthroughs of diy stompbox/synth builds, etc would beappreciated!

    here is a resistor code calculator to make sure you have the proper parts: http://www.hobby-hour.com/electronics/resistorcalculator.php

    Posted at 3:17 pm on Jan 5th, 2010 by mister newbie returns

    err having major problems with this in th final image, is the picture or the chematic correct?

    also, i have, i think got everything wired up, but only the 1M potentiometer does anything, and its all veryquiet

    can someone post a picture of the finished article, so that i can see what im doing wrong?

    thanks

    Posted at 11:21 am on Jan 24th, 2010 by nick

    Please help me!Im doing this for my science fair project, and it wont work properly.I dont know whats wrong with it.

    Could someone make a video on this?

    Cheers,Mike

    Posted at 8:02 pm on Jan 27th, 2010 by mike brazier

    @nick

    Do you think you could send me a video of the first assembled schematic?Seeing as youre the most active visitor on this article currently.

    its [email protected]

    Posted at 9:21 am on Jan 28th, 2010 by Mike

    Page 25 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    26/32

    I just built this schematic as a first year ee student, havnt taken a circuits class yet. Its one thing to just buildthis but I really wanted to understand what was going on, so I talked to a professor who helped me out. Hopethis helps anyone out. Ill be referring to the last schematic with an LFO.

    Basically what happens is that the 9V gets converted to 5V through the voltage regulator.

    Then the 5V charges up the capacitor (plotted on a Voltage/time looks something like this except it only goes upto 5V http://www.kpsec.freeuk.com/images/charge.gif)

    The HEX inverter has a THRESHOLD value that is somewhere inbetween 0 and 5V and when the capacitor(.1uf) has charged right above the threshold value, the output wave goes up and then comes back down when thecapacitor starts to discharge and crosses the threshold value again.

    The 100K potentiometer changes the audible frequency.As for the LFO it is produced using a MOSFET transistor. The one in this case is an N type doped. It has asource, a drain and a gate (the middle pin). The transistor works as a switch that is triggered on an off by avoltage. An N type transistor opens when it is supplied by a positive voltage.

    That is where the 1M pot, 1uf capacitor and HEX inverter come into play. They provide another output squarevoltage wave that triggers the MOSFET transistor to turn on and off. The tuning of the 1M pot gives afaster/slower square wave that determines how fast the MOSFET is triggered on/off and how quickly the two

    tones are heard. When the MOSFET transistor is turned off, the 50K potentiometer is not apart affectinganything. when the MOSFET is on the source and drain are connected and the 50k potentiometer is in effect.The pitch then alternates between two tones.

    Hope this clears up and feel free to comment if I got anything wrong.

    Posted at 1:26 am on Feb 18th, 2010 by Dennis Cao

    i can`t find the soundfiles in the flash players.wanted to hear this melody once again :-)is there another link?

    Posted at 1:06 pm on May 15th, 2010 by andy

    Like the Nintendo Wii, theres a piss-poor library for the DS

    Posted at 11:44 pm on Sep 10th, 2010 by Lilly Braunwarth

    Can someone help me, ive wired up everything according to scamatics, but im not getting anything. I couldntfind the right jack so im using a quarter inch phone jack, does that screw it up? I can only get sound if i pull theheadphone slightly out.

    Posted at 8:16 pm on Nov 26th, 2010 by Bonham79

    Hi! I think that most simple way to make Analogue LFO Frequency Modulation is to attach MOSFET (or somesimilar amplifier) to capacitor which is driving the CMOS inverter (oscillator). The almost-sine-wave/almost-triangle signal is already there:

    http://brmlab.cz/_detail/project/cmos_oscillator_capacitor_voltage.png

    http://brmlab.cz/project/circuit_bending#simplest_possible_cmosmosfet_lfo

    Page 26 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    27/32

    Posted at 6:38 am on Jan 2nd, 2011 by Harvie

    Hi! I think that most simple way to make Analogue LFO Frequency Modulation is to attach MOSFET (or somesimilar amplifier) to capacitor which is driving the CMOS inverter (oscillator). The almost-sine-wave/almost-triangle signal is already there:

    http://brmlab.cz/_detail/project/cmos_oscillator_capacitor_voltage.png

    http://brmlab.cz/project/circuit_bending#simplest_possible_cmosmosfet_lfo

    Note that MOSFET can be connected in parallel with the resistor/pot determining frequency of anotheroscillator.

    Posted at 6:40 am on Jan 2nd, 2011 by Harvie

    Hey, nice one. Im goin to try it! Unfortunately,I cant play the audioexamples, could you repost it somewhere,if they still exist?

    Posted at 5:45 am on Feb 23rd, 2011 by ango

    I built this thing and its pretty awesome. The issue Im having is I want to mount everything in a portable casewith its own speaker, but I dont know exactly what I need to do so that it doesnt need to go into poweredspeakers. This isnt going to be a large speaker by any means, it just needs to be loud enough to have fun with it.I got it working using a very small piezo driver, but its really quiet. Right now the output is putting out .266volts and I figure thats probably not enough. Anyone got any suggestions?

    @Bonham79 not sure if youve already gotten your answer, but it sounds like your issue could be using a stereomale with a mono female, or vice versa.

    Posted at 10:17 am on Mar 19th, 2011 by JustOneRobot

    yeah its actually analog using a logic gate. the signal may be digital (on/off: square wave) but the pitchcontrol is analog. if this were a truly digital synthesizer, the pitch control would be quantized giving you a finiteamount of pitches.

    Posted at 11:43 am on Mar 26th, 2011 by Phil

    Leave a Reply

    Name (required)

    Mail (will not be published) (required)

    Website

    Page 27 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    28/32

    Submit Comment

    Notify me of follow-up comments via email.

    Subscribe by email to this site

    Hack a Day serves up fresh hacks each day, every day from around the web as well as hacking related news.

    Send us your hacks

    Search

    Page 28 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    29/32

    Hacks

    android hacks (93)

    arduino hacks (492) Ask Hackaday (6)beer hacks (26)blackberry hacks (7)cellphones hacks (258)chemistry hacks (30)classic hacks (616)clock hacks (72)cnc hacks (145)cons (141)contests (83)cooking hacks (3)digital audio hacks (291)

    digital cameras hacks (260)downloads hacks (100)ds hacks (33)firefox hacks (21)g1 hacks (26)gameboy hacks (77)google hacks (42)gps hacks (80)green hacks (66)Hackaday links (50)Hackerspaces (17)HackIt (85)handhelds hacks (170)hardware (36)home entertainment hacks (431)home hacks (442)how-to (58)Interviews (1)iphone hacks (137)ipod hacks (131)Kinect hacks (29)laptops hacks (93)laser hacks (102)

    www Sunstone com/PCB-S ecialists Ads b Goo le

    Page 29 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    30/32

    led hacks (352)lifehacks (19)linux hacks (63)lockpicking hacks (8)macs hacks (111)Medical hacks (32)Microcontrollers (142)misc hacks (1371)multitouch hacks (73)musical hacks (75)netbook hacks (49)news (747)nintendo hacks (197)parts (47)pcs hacks (304)peripherals hacks (516)phone hacks (12)playstation hacks (102)podcasts (8)portable audio hacks (63)

    portable video hacks (52) pre hacks (6)psp hacks (44)radio hacks (38)rants (9)repair hacks (30)reviews (12)robots hacks (551)roundup (28)security hacks (310)Software Development (16)software hacks (12)solar hacks (22)

    tablet pcs hacks (15)teardown (13)tool hacks (341)toy hacks (139)transportation hacks (274)Uncategorized (330)video hacks (87)weapons hacks (5)wearable hacks (111)wii hacks (69)wireless hacks (246)xbox hacks (111)

    Resources

    Send us news tipsContact us

    Page 30 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    31/32

    Most commented on (30 days)

    TI adds some Linux support for Evalbot - we've got hardware coupon codes for you! (109)iPhone watching every breath you take, every move you make (86)Powering vehicles with aluminum (75)Headphones use standard-sized but proprietary rechargeable batteries (70)DoJ and FBI now issuing command to botnet malware (61)RFID drink system eliminates the need for change (60)Do your projects violate International Traffic in Arms Regulations? (53)Long-range Bluetooth wardriving rig (51)

    Alternate keyboard layouts - for geekiness and other reasons (50) Hacking Electronic Price Tags (50)

    Recent comments

    MrX:@The Cageybee That just gave meWhatnot:It's called 'the dead bugWhatnot:I hear people use DFN-10Leithoa:Vacuforming would be faster forThe Cageybee:Props. Nice build. Also, some nicealan:I say it as L.E.D.

    Hacker MastersLearn CuttingEdge TechincalAnd Legal HackingSkills - Apply Now!www.UAT.edu/ia

    PlantronicsSpeakerphonesWireless BluetoothLapel MicrophoneCalisto Pro PA50only $69.95www.TapeTel.com

    VCOs & PLLs40 MHz - 13.5

    GHz, Low PhaseNoise LinearTuning, WideTuning Rangeswww.zcomm.com

    RF GlobalnetDownload datasheets, products,drawings, articlesand morewww.rfglobalnet.com

    Page 31 of 32How-To: Make a digital synthesizer - Hack a Day

    4/26/2011http://hackaday.com/2008/05/01/how-to-make-a-digital-synthesizer/

  • 8/2/2019 How to Make a Digital Synthesize

    32/32

    MrX:@sd Wow, didn't know aboutMrX:This is a really reallyMax:@BGH: No problem, I didSmokingman:Technically, LED is an initialization

    All contents copyright 2011, Hack a Day. All Rights Reserved. Powered by WordPress.com VIP

    Page 32 of 32How-To: Make a digital synthesizer - Hack a Day