Author |
Message |
Grumble
Joined: Nov 23, 2015 Posts: 1294 Location: Netherlands
Audio files: 30
|
Posted: Fri Jul 14, 2017 12:18 pm Post subject:
AWG Subject description: Arbitrary Waveform Generator |
|
|
With this module I'm trying to create wave forms by adding sinusoidal waves of different frequency and amplitude, chosing the odd, even or all full harmonic frequencies.
The heart of the Arbitrary Waveform Generator I have build is a 256 words of 9 bits FIFO, I choose this fifo because I have some in my box of chips and my original thoughts was write to the fifo and at the same time read the fifo and convert it to an analog signal.
This proved to be impossible, but I could fill the fifo and read the output repeatedly, creating a melodic signal.
The read part of the FIFO (an AMD AM7201) is clocked using an Analog Devices AD9833 and the digital output of the FIFO is converted using an Analog Devices AD9760 10 bits parallel DAC with the lowest bit tied to GND level.
The output of the AD9833 DDS is both used as the read clock for the AM7201 FIFO as well for the write puls of the AD9760 DAC, so by changing the frequency of the AD9833 the output signal of this module changes.
Luckely the output of the FIFO becomes valid after the leading edge of the clock signal, while the DAC samples the input at the trailing edge of the clock signal.
If one sinus fills the FIFO, I need a clock signal 256x the desired frequency but still it is possible to generate a sine-wave well above hearing frequencies
I had some troubles to fill the FIFO properly, because the FIFO first has to be reset when I want to fill it with a new digital signal of 256 words of 9 bits.
Resetting must be done by asserting the reset input LOW while Read and Write are both high, where the Read signal is coming from the (running) AD9833 DDS. So what I did was lowering (temporarily) lower the frequency of the AD9833, wait for the Read signal to go LOW, and when it goes HIGH again, LOW the Reset signal and the AM7201 resets.
After this I can fill the FIFO with new data.
This data consists of:
1- a Sine wave, with added a number of harmonics (odd, even or all) with different amplitudes.
2- 20 predefined waves, used with permission taken from the VCDO1 from Electric Druid which I converted to 9 bits signals.
HERE a short video of this module.
Description: |
|
Download |
Filename: |
SCH_Morphius.pdf |
Filesize: |
169.67 KB |
Downloaded: |
603 Time(s) |
_________________ my synth Last edited by Grumble on Sat Jul 15, 2017 10:17 am; edited 2 times in total |
|
Back to top
|
|
|
blue hell
Site Admin
Joined: Apr 03, 2004 Posts: 24079 Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320
|
Posted: Fri Jul 14, 2017 1:17 pm Post subject:
|
|
|
Sounds good - I then thought oh wow .. complicated thing .. until I realized it was four times the same schematic in the pdf. well it still is not very simple of course
Anyway interesting this can be done with just 256 steps and 9 bits .. also interesting that the readout speed is being varied to tune the thing .. thus avoiding all issues with aliasing (and turning imperfections into harmonics that just will become inaudible instead of folding back). _________________ Jan
also .. could someone please turn down the thermostat a bit.
|
|
Back to top
|
|
|
Grumble
Joined: Nov 23, 2015 Posts: 1294 Location: Netherlands
Audio files: 30
|
Posted: Fri Jul 14, 2017 2:18 pm Post subject:
|
|
|
Oops, hahaha, didn't notice the quadruple pdf drawing.
Have corrected this 😖 _________________ my synth |
|
Back to top
|
|
|
Electric Druid
Joined: Mar 13, 2012 Posts: 44 Location: UK
|
Posted: Mon Jul 17, 2017 1:48 am Post subject:
|
|
|
The nice thing about doing it like this is definitely the variable sample rate. That gives you the same quality at any frequency you can produce, more or less. Certainly you avoid the "nasty aliasing on high notes" you get with the typical naive fixed sample rate oscillator (like my VCDO).
I've sometimes wondered about doing something similar, but using the DDS as the PIC's master clock, so I could do some clever stuff in the software, but still have the genuine variable rate.
This is good work, anyway. Congratulations.
Tom _________________ Electric Druid Synth and Pedal DIY website |
|
Back to top
|
|
|
blue hell
Site Admin
Joined: Apr 03, 2004 Posts: 24079 Location: The Netherlands, Enschede
Audio files: 278
G2 patch files: 320
|
Posted: Mon Jul 17, 2017 2:42 am Post subject:
|
|
|
Processors are cheap enough to have one do dedicated sound generation with a variable clock rate I'd say ... it's something worthwhile to try IMO.
They may still be fast enough to do some basic IO as well .. but stuff like MIDI would become a nightmare. _________________ Jan
also .. could someone please turn down the thermostat a bit.
|
|
Back to top
|
|
|
Grumble
Joined: Nov 23, 2015 Posts: 1294 Location: Netherlands
Audio files: 30
|
Posted: Tue Jul 18, 2017 12:24 pm Post subject:
|
|
|
I don't think it is even remotely possible to get the same acuricy with a dedicated processor compared to the dds I use. _________________ my synth |
|
Back to top
|
|
|
|