Go Down

Topic: First Due Project Quick And Dirty Synth At 44.1Khz (Read 3 times) previous topic - next topic

DuaneB

Hi,
   Borrowing a lot from the timer interrupt thread I knocked out a quick synth project for the Due. Its running at a sample rate of 44.1Khz, the same rate as a CD, its also using the DAC for output.

For the DAC Configuration I have cheated and used analogWrite(DAC0,255); to initialise the DAC, then access it directly in the ISR using dacc_write_conversion_data(DACC_INTERFACE, ulOutput);

Its quick, I can't really say that its dirty, at the high sample rate my first and only impression is that it sounds really clean and crisp.

I will use this code as a framework for a wavetable synth as can anyone else who wants to grab the code from here -

http://rcarduino.blogspot.com/2012/11/quick-and-dirty-synth-for-arduino-due.html

And as it says in the code, thanks to Sebastian Vik for the head start -
http://arduino.cc/forum/index.php?action=post;topic=130423.15;num_replies=20

Duane B

Grumpy_Mike

That looks great.

Quote
I will use this code as a framework for a wavetable synth

My SpoonDuino project uses a wave table synth generated from an iPad talking to Processing through TouchOSC. I haven't put it on line yet but you are welcome to have the code if it fits in with what you want to do.
http://vimeo.com/38466551

DuaneB

Hi,
   I plan to add wavetables as another synth option on the five dollar keyboard -

http://www.youtube.com/watch?v=ZuKoG15oObk

   I found a resource with 1,000's of 16 bit single cycle waveforms that I was planning to store on an SD Card so the user could browser and play them through the five dollar keyboard.

   Heres a link to the adventure kid website where he provides the wavetable collection for download -

http://www.adventurekid.se/akrt/waveforms/

   There is a also a collection of 8-bit Nintendo waveforms which I will have a play with on the current 5 dollar synth before I migrate it to the Due.

   Are you hand drawing your wavetables on the spoonduino ?

Duane B

rcarduino.blogspot.com

   


Grumpy_Mike

No, what makes a wave interesting is not so much it's waveform but how it's waveform changes over time. That attachment shows the iPad app that allows you to draw the envelope of each harmonic in the wave. As you do that the right hand side shows the resulting 16 wave tables. The spoonduino plays each waveform for a bit before moving on to the next. This can be looped or done as a one shot.

DuaneB

Hi,
   I have reread your post many times and think I finally get it.

   Each harmonic is given its own envelope, all envelopes are divided into sixteen common intervals, the sixteen waveforms are the result of summing the product of the harmonics and their corresponding envelopes at each of the sixteen intervals ?

   Having read a little more about wavetable synthesis, its not what I will be doing, I will aim for something less UI intensive which will most likely be as simple as providing the option to load one or more wavetables in place of the usual oscillator shapes. Its hard to beat the instant appeal and immediate simplicity of the Auduino, and its that spirit that I want to capture in the five dollar keyboard - I have a few effects to morph the sound, bit crushing being a simple and effective example.

Duane B

rcarduino.blogspot.com

Go Up