Tiny wavetable synth!
Leon
Posts: 7,620
This PIC32 application is very impressive:
http://dangerousprototypes.com/forum/viewtopic.php?f=56&t=3472
With that type of crude construction it can be possible to get something smaller than by using a PCB, primarily because the wires can cross one another.
http://dangerousprototypes.com/forum/viewtopic.php?f=56&t=3472
With that type of crude construction it can be possible to get something smaller than by using a PCB, primarily because the wires can cross one another.
Comments
I'm not involved much with the PIC32, but would you know offhand how much RAM the wavetable takes up when compiled?
-- Gordon
Anyway, that one wouldn't have used wavetables, which is what makes this PIC32 synth sound so nice. In other words, the PIC32 version started with actual sounds from a music box, that were then cropped down and stripped into very short "blips." Those were then encoded as wavetables, and (though I didn't look real close at the code so I'm not sure) additively mixed with other completely synthesized elements.
For a synth with only a couple of instruments, it might be possible to create wavetables small enough to fit into the Prop's memory.
-- Gordon
Look at 8-bit Atari Softsynth. And my (working) alpha of PC Softsynth.
http://sourceforge.net/projects/pc-softsynth/files/
This I want to convert to Propeller as soon as I can write fluent in spin. It is not far future from now You need one period of wave. Atari 8bit uses 256 bytes for it, my PC implementation uses 2048 bytes. Then you need something like ADSR. It uses 64 bytes (or rather nibbles) on 8-bit Atari and 256 bytes in my PC implementation. Having available something about 20 waveforms and 20 ADSR forms, then variable timings, you can create hundreds of instruments from this.
To write music for it you use Basic-like language called Masic.
All of these features are 100% available with Propeller. I only need to write it
I'd be a little surprised Spin would be fast enough for this task, but if it can be done, that would be great. I have a feeling, though, you'll need to do at least some of the work in PASM, assuming reasonable bit depths and sample rates. 16-bit and 40 kHz or higher sampling would be best.
-- Gordon
Would be super simple to do on the Propeller. The biggest problems is of course the lack of a multiplication intruction on the Prop; Otherwise 64 vioces in a single cog at a decent sample rate would have been quite realistic for such a simple implementation.
-- Gordon
http://forums.parallax.com/showthread.php?109498-Rainbow-synthesizer-polyphonic-multitimbral-wavetable-synthesis
http://www.youtube.com/watch?v=Xm5vQm9-JQ4
The same Masic source code interpreted by PC Softsynth (16bit/44kHz):
http://eksperymenty.webh.pl/images/opswiata1.mp3
Masic source code: 2kB
Uses 12 samples - 24 kB on PC, 3 kB on Atari
Uses 8 ADSRs - 2 kB on PC, 512 bytes on Atari
And yet another Jakub Husak's 8-bit Atari masterpiece written in 1988 interpreted by PC: (search for Jakub Husak in Google to find what he did with Atari Softsynth... )
http://eksperymenty.webh.pl/images/wodo.mp3
I think it can be done with Propeller... I did it with PC, so I think I can do it. I need to write (1) masic interpreter - in Spin (2) synthesizer - in PASM.
http://elm-chan.org/works/mxb/report.html
which explains the technique in detail.
Samples can be stored in eeprom and read on demand while playing, when a new instrument is set.
The result can be quite "interesting", but the lack of modulation makes it a little bit dull compared to synthesis with filter, PWM, FM, Ring modulation... etc.
Pure sample playback based on a phase accumulator was found in the Amiga and the result was excellent for the time.
There was no limitation on what sounds that could be "generated" because ANY sound could be sampled and played back at arbitrary rate and volume.
While it sounded extremely good and made people jealous of Amiga owners, it was technically much simpler than the SID for instance.
Sample playback is about the simplest thing that you can do on any CPU with some kind of DAC connected. The real challenge lies in generating sounds on the fly of course...
Synth, the sound just got born it have never been heard before.
and you could change from sinewave to triangle in real-time in small steps etc.
With sampled sound, someone had to first create this sound using synth.
-Phil
Anyway, regardless of the technique used for the PIC32 project, it sounds great, he's provided full source and steps, and it's easily reproducible. I want to thank Leon for bringing it to our attention.
-- Gordon
Now Phil is right about it being more complicated than a sample and an envelope. Some sampled sounds I use *eg BIG grand piano* have MANY LAYERS of samples. The "BIG grand" patch has a sample GROUP for every octave: except for the first octave and the last. These have 3 notes per sample span. There is also 3 LAYERS of samples for each sample GROUP. The layer that is played is determined by the notes velocity. The samples are also about 2.5 seconds long. This patch weighs in @ 7.2 MB which is very large but it sounds BEAUTIFUL.
While this is interesting, it leaves quite a bit to be desired. I think the Propeller will make a much nicer wavetable synth when coupled with a couple srams and a couple 16bit DACs.
Here's the schematic. I've dispensed with a regulator, it should run for a long time on a couple of AA cells.