Pages: [1] 2   Go Down
Author Topic: Great big shield! (arduino synth)  (Read 5275 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I just got my new boards in!

I guess it could be called a shield, it has an arduino attached smiley



This is a single board version of this mess. which will be mounted on a modular synth panel.

[media]http://www.youtube.com/watch?v=Io1Aiy74nnw[/media]

The arduino is a 4 oscillator phase accumulator, and does a few other things.

each oscillator has a separate DAC which are mixed in the analog realm (controlling an 8 bit DAC level with another 8 bit signal gives a lot better resolution than changing its level digitally)

The levels of the DACs are controlled VIA PWM > 4 pole filter > Vref. and then the DAC output is level converted to +- rather then +

Each pair of DACs has another 4 pole filter on the output to eliminate any aliasing.

And yet another 4 pole filter on an aux envelope out.

There are 2 Multiplexers (completely copied from the mux shield) which get the values for 32 potentiometers which control various modulation and wavetable selection etc.

There are no voltage controlled filters on board, but it can output envelopes and triggers for modular synth filters/analog envelope generators

And 2 inputs for external control voltages through a special ADA4091-2 op amp which can take +_25v over the rail input, and being powered by the arduino power, it automagically protects the inputs from the higher voltages existing in a modular synth (+- 15v)

I am planning to make a cut down version which would fit on a proper shield, but i still need to experiment a bit (especially trying to make a nice sounding 5 volt voltage controlled filter!) but it will still have to be a mega.

I will continue posting as it is built and tested along the way.
so far i attached the arduino and made sure the signals and power are going to all the proper places.


« Last Edit: April 28, 2010, 11:25:01 pm by DeFex » Logged

Milano Italy
Offline Offline
Jr. Member
**
Karma: 0
Posts: 61
Arduino <3
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

AWESOME!  :o
Logged

Mesa, Arizona
Offline Offline
Newbie
*
Karma: 0
Posts: 26
Arduino FTW
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Very impressive!

Help me out though:  What is meant by "phase accumulator"?  What exactly is the Arduino doing in this application?

Nice work!

Andy
Logged

I make it all up as I go along.

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

the phase accumulator is clocked by a fixed frequency master clock (an ISR) and with each cycle increments the phase angle by an amount which determines the frequency (pitch)

In this case when a MIDI note arrives there is a lookup table which tells it the basic amount to add each cycle. that is modified by things like detuning and pitch glide etc.

the phase accumulator is a long int, and it is bit reduced to 8 bits to determine what address of the ROM wavetable is selected. that automagically does the required rounding without any additional work.

(there is a version with internal wavetables as well, but i decided to use an external ROM because it takes too long to download all the tables everytime i change the sketch (and i have 1024 waves instead of 16)

each wave has 256 values which are only all used once  at exactly one particular note (F2 if i remember right)
at higher frequencies some of the samples will be missed out to get it to play fast enough, and at lower frequencies some of them can get played twice.

the accumulator (naively in arduino) rolls over when it gets past the highest possible value, so it is like a "free running" oscillator.

I hope some of that made a bit of sense.  smiley-razz
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 88
Who doesn't like blinking LEDs
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm impressed. Entirely. How long/how much money did it take you to do this? What did you design the PCB in? How did you manufacture it--Fab house? Well put together video by the way.
Logged

Mesa, Arizona
Offline Offline
Newbie
*
Karma: 0
Posts: 26
Arduino FTW
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh, ok, I think I understand completely.  So each voice can be running through the same wavetable at independent indexes and rates, right?

How did you extrapolate the source wavetable data in the first place?
Logged

I make it all up as I go along.

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

k2pek2:

I have been working on this bit by bit over quite a while on breadboards, and with a few home made toner transfer boards.

Then i decided to build a modular synthesizer for my studio with some bought and some DIY modules (there will be a couple more arduino ones as well). and decided to use this as an oscillator, as well as a more traditional analog.

I have bought a few ICs, and other components for it but none of them are very rare or expensive.

This board was made with ExpressPCB. I had 4 of them made, and each one also has 4 header boards (they go between the MUX and the potentiometer boards) and an extra tiny 4 pole filter board which i put there because my friend wants a subwoofer crossover.

The little boards have to be cut off, but i rigged my lathe with a small slitting saw to make accurate cuts.(the one in the pic already has that part removed)

andylama:
That is correct except with modulation, each voice can be playing a different wavetable depending on velocity, envelope, accent, randome, notenumber, Midi clock, and whetever else i can think of.

It is not 4 voice polyphonic (it could be with a different sketch) this version is "4 oscillator monophonic, with 303 type linear glide". it is designed to be a bass voice with a lot of expression available.

The wavetables are arranged in 64 sets of 16 evolving sets, in a simple non modulated voice it could scan from the first wave to the last one in a set as time progresses after a note is played. because there are only 16 waves per set, it can do a bit of semi random (lookup table actually) granular mixing to make the transition smoother and longer. (or deliberately not!)

The wavetables themselves came from various sources. some are home made, some came from PPG wave, avrx, waldorf and wiard, and various other places i could find any smiley
Logged

Mesa, Arizona
Offline Offline
Newbie
*
Karma: 0
Posts: 26
Arduino FTW
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

RE: 4 oscillator monophonic:  That would explain why it sounds so rich and fat.  Wonderful!

By any chance, do you have any affiliation with Analogue Haven?

I am so gratified to see someone doing more sophisticated musical applications with the Arduino.  Please keep us posted as this thing develops!

I myself just finished an unconventional synth application with a Mega (nicely polished, but admittedly nowhere near as deeply technical as what you're doing) and will introduce it here as soon as I can get some halfway decent audio/video demos made up, probably next week.

Rock on!
Logged

I make it all up as I go along.

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks for the positive responses everyone! i wonder if the anti arduino folks at hack a day will say this is "a waste of a microcontroller"

andylama
I think analogue haven would tar and feather me for making this and putting it in a modular synth smiley

for anyone who is interested the original code i based the phase accumulator on it is here.

http://adrianfreed.com/content/arduino-sketch-high-frequency-precision-sine-wave-tone-sound-synthesis

a slightly old version of the synth code is here

http://codeviewer.org/view/code:d6d (a few changes since then this was current around the time the youtube video was made.) and its not called "aciduino" its called "scarab"

I have set up the opto isolator MIDI input now, it is working,
i just edited the sketch to serial.print any MIDI it recieves, so I could test it without the rest of the circuit there.

I will just add sections bit by bit and test them. thats one of the reasons why using an arduino is so good, i can modify the code for testing the circuitry.

The next stage to build will be the "pwm envelope filter" which takes PWM outputs to send to the DACs vref, which works as a voltage controlled amplifier. this filter is important to give the sound the right character, too low a frequency and the attack of the notes will be sluggish, too high and there will be a click as the level is suddenly increased.

If you look at "pwm envelope filter" section on the first pic you can see a lot of extra holes, that is because previously i was just using a 1 pole resistor/capacitor filter and some of the pwm noise would escape in to the DACs vref and cause a little noise. If i made the filter too low then the response was sluggish, (1 pole filter just does not cut it!) thats why i went with a proper 4 pole active filter. (this filter is Salen-key Bessel filter in case anyone cares)

I can put some headers on there so i can experiment with different filter frequencies, theoretically the design i did (on Ti filter designer) should give me a fast enough envelope time but i left it open for tweaking. once i am happy i just solder the proper value in next to the header.
« Last Edit: April 30, 2010, 07:47:30 pm by DeFex » Logged

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

some construction







Now i am waiting for a part i stupidly forgot to order for the power supply, which i need to test the filter.  smiley-razz

Logged

California. USA
Offline Offline
Full Member
***
Karma: 0
Posts: 130
my guitar wants to kill your mama
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

epic.
Logged

Mesa, Arizona
Offline Offline
Newbie
*
Karma: 0
Posts: 26
Arduino FTW
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Man, that is some serious fab work going on there!

Can hardly wait to see/hear the finished product!
Logged

I make it all up as I go along.

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Here is something.



I found these wood frame things someone threw out. dovetailed solid oak!

It so happens that the height is just right for 2 modular units as well.

this will stand up when it is finished, its a good size for me to test things with just a few other modules. I put the aluminum bar across, and those bolts will be to hold the modules in place without using wood screws.
« Last Edit: May 14, 2010, 05:42:26 pm by DeFex » Logged

0
Offline Offline
Full Member
***
Karma: 0
Posts: 107
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

[media]http://www.youtube.com/watch?v=2BHwqN3VnFw[/media]

did some testing smiley
I have built everything except the control voltage input, which i cant really test until i get more modules anyways.

And I have to make a nice panel and cut the pot shafts a bit to fit the knobs on (not looking forward to that but)
« Last Edit: May 21, 2010, 05:14:29 pm by DeFex » Logged

Mesa, Arizona
Offline Offline
Newbie
*
Karma: 0
Posts: 26
Arduino FTW
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Eeeeeexcellent!  Super nice video work too!
Logged

I make it all up as I go along.

Pages: [1] 2   Go Up
Jump to: