My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
Auduino  
Details of the Auduino synthesiser
auduino, arduino, Featured
Updated May 1, 2010 by cathed...@gmail.com

Introduction

The Auduino is a sound synthesiser based on the Arduino platform. It works on all Arduinos running at 16MHz - everything from the original Arduino serial to the Arduino Mega. It uses granular synthesis techniques to generate a distinctive filter-sweep sound that had much more character than boring square waves.

Have a look and a listen

Synthesis model

Sound is generated by playing the same noise ('grain') repeatedly at very high speed. This merges into a tone that is an audible hybrid of the repetition rate and the original grain. It sounds quite similar to an oscillator with two resonating bandpass filters, although the different architecture means there are lots of additional interesting noises at parameter extremes.

The grain consists of two triangular waves of adjustable frequency, and adjustable decay rate. This is based on FOF synthesis model, but using triangle waves instead of sine and using a rectangular window.

The repetition rate is set by another control.

Programming the Arduino

Download the source code from the the Tinker.it Google Code site. Load it into the Arduino environment, set up your board type and serial port, then hit the Upload button. Done. If you've never used Arduino before, you'll need to download the development software from the Arduino site.

Construction

Auduino uses 5 controls. You can use anything that generates a 0-5V analogue signal, but the prototype uses five 4.7Kohm linear potentiometers. Connect one side of each potentiometer to GND. Connect the other side to the 5V pin on Arduino. Connect the middle (wiper) pins to Analog inputs 0 to 4 on the Arduino.

The audio comes out of Digital pin 3 (or pin 11 on ATmega8 Arduinos). The prototype uses a 1/4" jack socket, with the tip connected to pin 3 (or 11 on ATmega8's) and the shield connected to GND. Plug the other end into an audio amplifier, and you're good to go.

The Arduino can drive a small piezo, speaker or headphones directly. Strictly speaking it outputs at 5V rather than the 1V line level, but most amplifiers don't seem to mind.

Auduino community

We now have a group on Google Groups. Show off your hacks, or get help with your Auduino projects.

Auduino controller hacks

The Auduino can take any analogue signal and make it audible. Add a Light Dependent Resistor, you have an instant theremin. Add a linear softpot, instant keyboard or ribbon controller. The Arduino Playground is a great place to get new ideas.

Auduino software hacks

Have a look at the loop() function. The controllers are mapped to the synthesiser parameters there. You can really customise the controllers there - adding different musical scales, vibrato, envelopes - whatever takes your fancy.

Start by playing with the pitch mapping. Three mappings are available to start with. Uncomment the one you prefer:

// Smooth frequency mapping
//syncPhaseInc = mapPhaseInc(analogRead(SYNC_CONTROL)) / 4;

// Stepped mapping to MIDI notes: C, Db, D, Eb, E, F...
//syncPhaseInc = mapMidi(analogRead(SYNC_CONTROL));

// Stepped pentatonic mapping: D, E, G, A, B
syncPhaseInc = mapPentatonic(analogRead(SYNC_CONTROL));

syncPhaseInc is proportional to frequency, so the /4 above drops the pitch to a quarter, or two octaves.

Auduino hardcore hacking

If you're really into algorithmic synthesis, have a poke around in the interrupt routine at the bottom of the source code. You'll have to be careful to keep the routine fast, but there is plenty of spare CPU to implement other synthesis techniques.

Comment by brian.de...@gmail.com, Nov 18, 2008

Just making sure, are the Pots Linear? Cheers Brian Degger

Comment by project member cathed...@gmail.com, Nov 18, 2008

Very good question. Yes they are - and I've updated the text. Thanks Brian!

Comment by 3vil.0ve...@gmail.com, Nov 18, 2008

Just attach a few buttons over some resistors instead of the pot that controls the freq and you got a keyboard ;-)

Comment by casai...@gmail.com, Nov 18, 2008

Congratulations for this project!! Looks very good :-)

Comment by jesse.fr...@gmail.com, Nov 22, 2008

Just breadboarded this and am playing around with it. With a little experimentation on the controls, it sounds awesome! Can't wait for my softpot to arrive and then I can get some keyboard action going...thanks for sharing this project!

Jesse

Comment by xnd...@gmail.com, Dec 7, 2008

Very nice project! I built one myself to demonstrate the protomodule / arduino enclosure project I've been working on: http://www.flickr.com/photos/machinecollective/sets/72157610797368431/

I think I spent almost 2 hours playing with this baby.. It's amazing! Thanks and keep up the good work!

Comment by project member cathed...@gmail.com, Dec 8, 2008

Love it xndr77! Great video, and love the enclosure. Linked up the video for all to see.

Comment by bas682...@gmail.com, Dec 9, 2008

i love the sounds that come out of this, and would like to explore the use of this as a keyboard driven synth. i noticed that one person talked about buttons over resistors to make it a keyboard...

i have seen another arduino keyboard before, but, the sounds that come out of the auduino are much more pleasing to my ear... i also thought about the use of a softpot... are you able to set the pitches to a range of resistances in the software? thanks!

Comment by project member cathed...@gmail.com, Dec 11, 2008

@bas682009: One thing to watch with a keyboard - it controls two things - the pitch of the note, and also if a note is playing. Auduino right now allows pitch control, but not note gating. Of course, you've got the complete source code so there's nothing stopping you implementing that. You might want to consider ADSR. As for mapping pitches to resistance: you need to map the keyboard to voltage. I'd look at using a potential divider for that, as a chain of same value resistors. Depending on how you organise the chain, you may need to modify the ADC reading to pitch mapping in the loop() routine. Have a look at the source code.

Comment by p00...@gmail.com, Dec 12, 2008

Awesome project! I have been playing with this code and hooked it up so it is controlled from windows through serial rather than the pots. Not as usable as physical pots but it was just something to play with.

once again, great work!

@bas682009: I have changed it so that the values that are used to generate the sound are stored in variables and those variable are updated via software through serial, so yea it can handle the storing the values. I dont even notice any delay when it plays back even though it is monitoring the serial and doing some basic logic from it.

Comment by project member cathed...@gmail.com, Dec 13, 2008

@p00b0x: Glad you're having fun.

This comments section is getting a bit long, so I've created a Google Group

That should make things easier when sharing source code, diagrams and such.

Comment by lifeisno...@gmail.com, Feb 7, 2009

Very cool project, I just got mine working. My kid loves it too. http://noiseislife.tumblr.com/

Comment by goatboyr...@gmail.com, Mar 14, 2009

"although any Arduino running at 16MHz will work fine" Does this mean that you can't operate Auduino if your using an Arduino mini pro that operates at 3.3v/8MHz? A newby getting to grips with the Arduino Universe!!! Brilliant project by the way!!, Robbie

Comment by project member cathed...@gmail.com, Mar 14, 2009

@goatboyrobbie: It could work with 8MHz devices, but... It would run an octave lower. Also, the PWM would run at half the rate, so the 'whistle' of PWM would be much more obvious. Try it - it will work as is - but I think you'll prefer running it on a 16MHz device.

Comment by goatboyr...@gmail.com, Apr 10, 2009

Thanks Cathedrow! I have a couple of mini pro's running at 5v now so it won't matter but on another issue I can't seem to get any real decent sound out of this Auduino! I've checked the wiring and everything's loaded perfectly but it seems very tricky adjusting the pots to hold on to the melody and certainly can't get anything close to that fantastic video demo!! I just wonder where I'm going wrong? Any body else finding that tricky or is it just me? Appreciate any advice, Goatboy

Comment by goatboyr...@gmail.com, Apr 11, 2009

All sorted!! Finally got a grip on this little baby!! Between the pentatonic scales and the filter sweeps it'll put you right up there with the old Mongolian polyphonics!!!

Comment by dsi...@gmail.com, May 11, 2009

Thanks Peter K. for your help at openhacklondon. We rushed managed to assemble your circuit, in the end because it was "passive" we had to add some more resistors but got a working prototype in time. Cheers The pedal steel guitar tone control hackers

Comment by baddspe...@gmail.com, Aug 15, 2009

dude where can i find the code for "Synthesis model" i searched the site and nothing :S

some one pease link me ? / email me @ baadspella (@) gmail.com

Comment by jesse.j...@gmail.com, Aug 18, 2009

I made one too!

Here's a video of the build: http://www.youtube.com/watch?v=IwV-SKpQAak

Next step is trying to build and add a ribbon controller.

Comment by marcelij...@gmail.com, Aug 24, 2009

Great that you share this, easy to understand. Thanks

Comment by deadastr...@yahoo.co.uk, Nov 10, 2009

could this have a guitar input!....from a pot or something!..to drive the sound?

Comment by project member cathed...@gmail.com, Nov 10, 2009

@deadastronaut Sounds like you'd better get building. Post it up once you've got it working!

Comment by jwhagenb...@gmail.com, Nov 23, 2009

can i hang it on a baby10 sequencer? i am a little afraid to put an extra 5V to the arduino. so i mean an external cv to control the unit...

Comment by farmergl...@gmail.com, Dec 11, 2009

Absolutly excellent sounding device - just finished mine - would love to know where to start if I want to add some effect routines (distortion maybe) to the code - perhaps change one of the knobs to overload the sound - any ideas ?

Comment by farmergl...@gmail.com, Dec 15, 2009

Having just banged together a simple contact mic - replacing a couple of POTS with these might be worth a simple hack !!

Comment by sonom...@gmail.com, Dec 18, 2009

Here's mine little auduino makin glitchy soundz))

http://soundcloud.com/kuyanov/dds-test1

thanx!

Comment by animazon...@gmail.com, Dec 30, 2009

hey sonomute really nice glitches how did you made them????

Comment by farmergl...@gmail.com, Jan 24, 2010

Working on syncing a Baby10 to control all/none of the pots - and maybe have a LDR hooked in also - this project has thrown up many ideas - thanks !!

Comment by ryan.p.c...@gmail.com, Feb 1, 2010

I had a question about the potentiometers. Do I have to use 4.7k ohm pots or could I use 10k or even 100k pots? I priced out some 4.7k ohm pots and they were much more expensive than 100k pots.

Comment by mark.kiz...@gmail.com, Mar 6, 2010

Hi All! I just finished building my Auduino. It was a great experience! Check out my project: http://turtlethink.com/2010/03/auduino-diy-arduino-synthesizer/

Comment by joseph.p...@gmail.com, May 9, 2010

THis is a ton of fun. Is there a way to change the key it plays? Or can you tell me how to come up with the equation for cminor? This is a wonderful thing for arduino, and people should realize the power you have unlocked..

Comment by opensource@till.name, Aug 23, 2010

The value in the array for a tone with freq should be something like: 65536 / ((62500/freq)/2)

62500 comes from the PWM frequency, i.e. it is the frequency with which the PWM_INTERRUPT is called and 65536 is the amount of values for syncPhaseInc. The Arduino Physical Computing book by Manuel Odendahl, Julian Finn & Alex Wenger helped me to understand this. But it does not really explain this.

You can also use the values from the midi table, a mapping from the midi note number to the actual note is available here:

E.g. the 69th value (c' in midi) in the table is 923. But I did not yet fully understand the code. It might be, that the values are actually off by an octave.

Comment by project member cathed...@gmail.com, Aug 26, 2010

@michael.burzycki Arduino is basically C with some extra libraries. (There is a little C++ in there too, but Auduino doesn't use that). #include, >> and -= are all standard C constructs. I urge you to get a copy of "The C Programming Language" by Kenighan and Ritchie. It's a slim book that not only teaches C - it effectively defines it. With that by your side things should make a lot more sense.

Comment by kog...@gmail.com, Nov 30, 2010

hey @cathedrow,

i'm building something like this for my electronics class, i was thinking of substituting the potentiometers (or some of them) with force sensors or piezo elements. my idea is to make an enclosure with the sensors on the walls, and when you squeeze the enclosure wherever the sensors are taped, cool noises are made. the only problem is that force sensors are a little more expensive. so i wanted to know if you think this could work? thanks so much for your help! i look forward to a response!

Comment by brett...@gmail.com, Dec 10, 2010

Has anyone gotten this to work successfully on a MEGA 2560? I followed everything exactly and get no output at all. I verified all components to be good as well as the MEGA 2560 and all associated ports. Thanks in advance!

Comment by matstev...@gmail.com, Dec 16, 2010

I'm having the same issue as brett... The LED blinks twice but no output. And I've double checked everything.. twice. Any ideas? Thanks!

Comment by bruno.s....@gmail.com, Jan 11, 2011

Hey guys check mine @ http://www.youtube.com/watch?v=DY-8CUbNmio

Tks for the project

Comment by OrrinFra...@gmail.com, Jan 19, 2011

WE NEED VOLUME CONTROL!!

Comment by TannerTe...@gmail.com, Feb 20, 2011

The only output coming from it is from Analog pin 4, witch makes the pitch high or low. Help please!

Comment by parafern...@gmail.com, Jun 8, 2011

Hi!!!thank you to share it!!! I built the syntesyzer, but now i would like to connect the potentiometer to the mouse, to interact with my screen, any idea????? thank you!!!!

Comment by lemorle...@gmail.com, Oct 3, 2011

Hi, I added 2 LDR parallel to pot, funny!.

http://midisurfing.blogspot.com/

Comment by msowa2...@gmail.com, Oct 11, 2011

Hello, great project.

Please see my demo video of it;

http://www.youtube.com/watch?v=6-NODXBWIBc

Comment by juanpa...@gmail.com, Nov 12, 2011

in the construction of any side is, how to connect the SoftPot?? Membrane Potentiometer - 100m? as would be the connection

http://www.sparkfun.com/products/8607

http://www.youtube.com/watch?v=q9tmbrG7D-o&list=FL8zXRt0tGap8EAVUai6qY4A&index=16&feature=plpp_video

Comment by jepZy...@gmail.com, Jan 18, 2012

Sensors are transforming the way engineers think about position sensing

<a href="http://www.spectrasymbol.com">Distance Sensor</a>


Sign in to add a comment
Powered by Google Project Hosting