Turn your Arduino into a 4 voice wavetable synth with only a few components...

 by madshobye
Featured
Screen Shot 2012-05-02 at 20.58.41.png
Multiple synthesizer projects have been done for the Arduino, but few have been able to utilize the full power of the Arduino processor. DZL from GeekPhysical wrote a 4 voice wavetable synthesizer that is one of the more advanced software based synths for the Arduino.  It has wavetables included (sine, saw, square and triangle) and envelopes to create beats.

This instructable will show you how to make a simple sequencer that plays a little melody. You can hear how it sounds here:



It is up to you to modify the code to do many other things. Possible examples could be a midi controlled synth (sample code included), it could be a strange noise machine like this one:



Or you could detect touch and convert it into sound patterns:

 


Step 1: Parts

DSC_0658.JPG
You should use the following parts:

  • Arduino board
  • BreadBoard
  • Wires
  • 2.2k Resistor
  • 100n Capacitor
  • 100u Capacitor
  • Jack where left and right channel has one wire and one wire to ground
  • A pair of computer speakers

  • Don't worry if you don't have the exact values. It will probably work, but might be with lower sound quality. The Arduino is not powerful enough to drive a pair of headphones so you will need some kind of preamp for that - e.g. a headphone preamp like this one.

    Step 2: Add the components to your breadboard

    DSC_0656.JPG
    DSC_0656 copy.JPG
    diagram.png
    Start out with adding the components to the breadboard as the picture depicts. If you want diagram based instructions look at the third slide in this step.

    Step 5: Upload code

    arduino_logo.jpeg
    Below are the simplified steps to uploading the code to your Arduino board. If you are brand-new to Arduino, you can find a great step-by-step guide here to help you get your board connected and up and running, it's very simple and then you can continue with the below steps.

  • Download Arduino: www.arduino.cc
  • Connect the Arduino board to the computer via usb.
  • Download the code from github here: https://github.com/Illutron/ArduinoSynth
  • Upload the code to the Arduino board.

  • Congratulations - you are ready to go!
    krlos16 says: Apr 29, 2013. 12:20 AM
    hi my friend,, please might upload the code for arduino leonardo, thanks, regards from Bogota Colombia
    Neurotheist says: Oct 31, 2012. 5:57 PM
    Hey so I have everything set up, but because Im very new to this I guess I'm a bit confused on how to upload this code. Ive downloaded all the files...now what should I do?
    mcruise says: Oct 8, 2012. 6:50 AM
    Hello, i'm seriously thinking to build this project, but what code i have to choose from link?
    madshobye (author) in reply to mcruiseOct 8, 2012. 7:09 AM
    All of it, but open it with the "synthOriginal.ino" sketch.
    soggymushrooms says: Oct 7, 2012. 6:23 PM
    That is one chunky breadboard...
    blinkyblinky says: Jul 4, 2012. 9:42 AM
    Wonderful. I noticed you commented out some midi support. If I un-comment it, what pins should I use or it it not completed yet?
    rezponze says: Jul 3, 2012. 4:29 AM
    That was really inspiring. I've reproduced your tutorial and everything was smooth and clear. It worked the first attempt.

    However, I found a bit difficult to understand how External Midi works in this code and with this hardware layout.

    It would be great to know where is supposed to come in the MIDI IN signal.
    Could you possibly link to any MIDI interface compatible with your design?

    Thanks in advance for any further information or links to better understanding the MIDI interfacing.
    zcarlos says: Jun 18, 2012. 3:16 AM
    Hello.
    I have two questions:
    I've tested it and it sounds better (and louder) without caps and resistors, wiring ardu pin to jack directly. What have I done wrong?
    And, please, can you post a more hackable code? Sound is awesome but I can't imagine how to do things, p.e. read some buttons for change pitch.
    BPM: Your video demo song is slower than my attempt, Where can I change BPM?
    Thank you very much.
    energon says: May 25, 2012. 2:31 PM
    G E N I U S !!!
    largowork says: May 25, 2012. 9:55 AM
    Funny!! but I don´t know very well where can I change the parameters. Thanks!
    madshobye (author) in reply to largoworkMay 25, 2012. 10:09 AM
    That is a whole other story and quite a challenge - I dream of releasing a simplere version that is more hackable. This version shows off the potential, but uses a couple of advanced tricks. Remove the demo tracker part and just play notes yourself then you can get a feel of ways to play it.
    prphntm says: May 19, 2012. 1:12 AM
    Can you explain how to program this a bit more? I just built the circuit (2 minute build) and am trying to program this thing and am encountering lots of trouble.

    Being completely honest, I never coded in the "arduino" language and it's frightening me.
    madshobye (author) in reply to prphntmMay 20, 2012. 4:22 AM
    Great to hear that you are using it! I think there are lots of tutorials who have already explained how to program an Arduino and they do a much better job than I could. So I will just give you a couple of links:

    http://arduino.cc/en/Guide/HomePage
    http://www.youtube.com/watch?v=4HqXAmV_Ock
    http://www.ladyada.net/learn/arduino/lesson1.html

    Let me know if you succeed.
    madshobye (author) in reply to madshobyeMay 20, 2012. 4:24 AM
    The 3 things that ususally causes trouble:

    1. On windows you have to install the proper drivers (sometimes also on mac).
    2. Remember to select the right serial port in the gui.
    3. Remember to select the right board in the gui.
    Pro

    Get More Out of Instructables

    Already have an Account?

    close

    PDF Downloads
    As a Pro member, you will gain access to download any Instructable in the PDF format. You also have the ability to customize your PDF download.

    Upgrade to Pro today!