[sdiy] 1 bit serial stream delay approaches..

Richie Burnett rburnett at richieburnett.co.uk
Wed Sep 19 18:41:59 CEST 2012


> If so, a PIC should do the job for you.  with 8K bytes of RAM, you have 
> 65536 bits.  You could
> shift the input gate through as many bits/bytes as you need.  A little 
> arithmetic says you
> should get good resolution even if you use only one bit per byte (0.00061 
> seconds per delay
> sample).  Use all the bits (more complex program) and get 8 times the 
> resolution.  A PIC with
> and ADC can read a pot to set the delay time.

This is the route I would take also, merely because of its simplicity.  Even 
a low end-micro with just 256bytes of RAM would give you more than 5 seconds 
of delay with 2.5ms timing resolution.

I'd just add one implementation issue which surely goes without saying for 
the seasoned programmers, but might be overlooked by someone new to embedded 
programming...

You don't actually shift the signal through all of the bits in the memory, 
as it would be incredibly time consuming to have to repeatedly move each bit 
of data to the next memory address for the entire memory space.  Instead you 
think of the memory space as a circular buffer with a read pointer and write 
pointer.  The write pointer makes its way repeatedly through all of the 
available memory, and the read pointer runs along behind the write pointer. 
How much it is behind determines the amount of delay.  Setting up two memory 
address pointers for circular addressing is much less hassle than 
continuously shuffling data through memory.  You can also easily implement a 
multi-tap delay by using a number of different read pointers with different 
offsets behind the write pointer.

-Richie,




More information about the Synth-diy mailing list