|
IntroductionThe 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 modelSound 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 ArduinoDownload 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 communityWe now have a group on Google Groups. Show off your hacks, or get help with your Auduino projects. Auduino controller hacksThe 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 hacksHave 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 hackingIf 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. |
Just making sure, are the Pots Linear? Cheers Brian Degger
Very good question. Yes they are - and I've updated the text. Thanks Brian!
Just attach a few buttons over some resistors instead of the pot that controls the freq and you got a keyboard ;-)
Congratulations for this project!! Looks very good :-)
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
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!
Love it xndr77! Great video, and love the enclosure. Linked up the video for all to see.
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!
@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.
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.
@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.
Very cool project, I just got mine working. My kid loves it too. http://noiseislife.tumblr.com/
"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
@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.
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
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!!!
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
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
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.
Great that you share this, easy to understand. Thanks
could this have a guitar input!....from a pot or something!..to drive the sound?
@deadastronaut Sounds like you'd better get building. Post it up once you've got it working!
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...
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 ?
Having just banged together a simple contact mic - replacing a couple of POTS with these might be worth a simple hack !!
Here's mine little auduino makin glitchy soundz))
http://soundcloud.com/kuyanov/dds-test1
thanx!
hey sonomute really nice glitches how did you made them????
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 !!
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.
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/
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..
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.
@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.
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!
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!
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!
Hey guys check mine @ http://www.youtube.com/watch?v=DY-8CUbNmio
Tks for the project
WE NEED VOLUME CONTROL!!
The only output coming from it is from Analog pin 4, witch makes the pitch high or low. Help please!
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!!!!
Hi, I added 2 LDR parallel to pot, funny!.
http://midisurfing.blogspot.com/
Hello, great project.
Please see my demo video of it;
http://www.youtube.com/watch?v=6-NODXBWIBc
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
Sensors are transforming the way engineers think about position sensing
<a href="http://www.spectrasymbol.com">Distance Sensor</a>