Analog echo

Algorithm development and general DSP issues

Moderator: frank

Post Reply
Alex MAK
Posts: 89
Joined: Fri Nov 05, 2010 1:00 pm

Analog echo

Post by Alex MAK »

Greetings to you! I want to create a "ANALOG Delay" based on the FV-1. Something like MEMORY MAN. I have 2 questions now. How can you get rid of the noise while the change of the delay? How can I make to become "ANALOG" ones. For example, I took the code. Many thanks for the ideas and advice! Alex

Code: Select all

;GA_DEMO	Echo with repeats

;Pot0 = Feedback
;Pot1 = Delay
;pot2 = Echo level

;memory declarations:

mem	edel	32767


;register equates:
equ	potfil	reg1	;adjusts pitch
equ	mono	reg0
equ	dout	reg5
equ	dx	reg6
equ	efil	reg7

;declare constants:

equ	fbk	0.95

;clear registers and initialize LFOs:

skp	run,endclr
wrax	efil,0
endclr:

;sum inputs to mono:

rdax	adcl,0.5
rdax	adcr,0.5
wrax	mono,0	

rdax	dout,fbk
mulx    pot0
rdax	mono,1
wra	edel,0

;now get delay output, controlled by pot1:

rdax	pot1,1
and	%01111110_00000000_00000000	 ;10mS increments
sof	61/64,3/64 	;range 50mS to 1000mS
rdfx 	potfil,	0.1			; Smooth the result to avoid jumping
wrax 	potfil,	1.0
wrax	addr_ptr,0	;write address pointer


rmpa	1		;read pointer
rdfx	efil,0.3
wrlx	efil,-1
wrax	dout,1
mulx	pot2		;adjust level with pot2
mulx	pot2		;square  function
wrax	dx,1		;write level adjusted delay out
rdax	mono,1		;pass input
sof	1,0.02
wrax	dacl,0
sof	1,-0.04
wrax	dacr,0

frank
Posts: 1244
Joined: Wed Oct 19, 2005 12:26 pm
Contact:

Post by frank »

If you mean the noise when you change POT1 then you may want to try adjusting the coefficient in the line:

rdfx potfil, 0.1 ; Smooth the result to avoid jumping

Try making the 0.1 smaller like 0.05

Please explain what you mean by :
How can I make to become "ANALOG" ones.

That is a very general question, need to understand what you really mean.
Frank Thomson
Experimental Noize
Alex MAK
Posts: 89
Joined: Fri Nov 05, 2010 1:00 pm

Post by Alex MAK »

Thank you! I really mean POT1 in question. On the second issue. In analog delay after each repetition "deteriorating sound quality." How to specify a filter (or something else) to get the repetition like MEMORY MAN?
frank
Posts: 1244
Joined: Wed Oct 19, 2005 12:26 pm
Contact:

Post by frank »

If you are still hearing noise even after changing the coefficient it could be due to the 10mS quantization, to get rid of that delete the line:

and %01111110_00000000_00000000 ;10mS increments

Try using a low pass filter in the feedback to create a lowering sound quality. There is good info in the knowledge base on basic single pole filters.
Frank Thomson
Experimental Noize
Alex MAK
Posts: 89
Joined: Fri Nov 05, 2010 1:00 pm

Post by Alex MAK »

Thank you, Frank! I'll try it today!
Alex MAK
Posts: 89
Joined: Fri Nov 05, 2010 1:00 pm

Post by Alex MAK »

I came back with the results. That is what I got I was quite satisfied, but it is not ideal. I would be happy ideas for improving the code :). Alex

Code: Select all

Echo


;Pot0 = Feedback
;Pot1 = Delay
;pot2 = Echo level

;memory declarations:

mem	edel	32767


;register equates:
equ	potfil	reg1	;adjusts pitch
equ	mono	reg0
equ	dout	reg5
equ	dx	reg6
equ	efil	reg7

;declare constants:

equ	fbk	0.95

;clear registers and initialize LFOs:

skp	run,endclr
wrax	efil,0
endclr:

;sum inputs to mono:

rdax	adcl,0.5
rdax	adcr,0.5
wrax	mono,0	

rdax	dout,fbk
mulx    pot0
rdax	mono,1
wra	edel,0

;now get delay output, controlled by pot1:

rdax	pot1,1
;and	%01111110_00000000_00000000	 ;10mS increments
sof	61/64,3/64 	;range 50mS to 1000mS
rdfx 	potfil,	0.03; Smooth the result to avoid jumping
wrax 	potfil,	1.0
wrax	addr_ptr,0	;write address pointer


rmpa	1		;read pointer
rdfx	efil,0.6
wrlx	efil,-1
wrax	dout,1
mulx	pot2		;adjust level with pot2
mulx	pot2		;square  function
wrax	dx,1		;write level adjusted delay out
rdax	mono,1		;pass input
sof	1,0.02
wrax	dacl,0
sof	1,-0.04
wrax	dacr,0

Sweetalk
Posts: 141
Joined: Thu Oct 15, 2009 5:13 am

Post by Sweetalk »

frank wrote:If you mean the noise when you change POT1 then you may want to try adjusting the coefficient in the line:

rdfx potfil, 0.1 ; Smooth the result to avoid jumping

Try making the 0.1 smaller like 0.05

Please explain what you mean by :
How can I make to become "ANALOG" ones.

That is a very general question, need to understand what you really mean.
I think he's refering to the pitch bending noises that the analog delays made when you move the delay pot.
Alex MAK
Posts: 89
Joined: Fri Nov 05, 2010 1:00 pm

Post by Alex MAK »

The term "analog" I consider the "deterioration" of each successive repeat. As is done in analog devices delay.
peterv
Posts: 17
Joined: Fri Nov 20, 2009 3:43 am
Location: Netherlands
Contact:

Post by peterv »

Alex MAK wrote:The term "analog" I consider the "deterioration" of each successive repeat. As is done in analog devices delay.
The idea is to feed the feedback through a shelving filter so the center frequency gets each time slightly amplified in the region of 1-2dB this initial curve should be as your tape curve at 15IPS. This would bring the deterioration based on tape throughput. The BH curve can be simulated by extracting a square wave form the initial signal and inject that at zero crossing.

The tape noise is also added only in the feedback loop if signal is present as this would keep the unit silence when not used. On my site are some write-ups on this.

Piet
PlanB
Posts: 1
Joined: Mon Dec 24, 2012 11:25 am

Re: Analog echo

Post by PlanB »

I have a question regarding code listed above, namely this section which controls the delay times:

;now get delay output, controlled by pot1:

rdax pot1,1
and %01111110_00000000_00000000 ;10mS increments
sof 61/64,3/64 ;range 50mS to 1000mS
rdfx potfil, 0.1 ; Smooth the result to avoid jumping
wrax potfil, 1.0
wrax addr_ptr,0 ;write address pointer


Currently this will give you a long delay with full voltage on the pot, and short delay with the pot at ground.

I am trying to make it operate the other way around.so that the pot fully ccw give you long delay and full cw gives you short delay. I initialy tried simply entering a negative number in the rdax line above:

rdax pot1, -1.90

It worked... but only as an offset - making the long delay at about the 10 o'clock position and then converted the pot operation to a bilpolar control. moving ccw from that longest delay point increases, as does moving the pot cw from the longest point. So it worked, but not well enough.

any suggestions? thanks in advance
frank
Posts: 1244
Joined: Wed Oct 19, 2005 12:26 pm
Contact:

Post by frank »

You want to first multiply the pot value by -1.0 then add 1 to inverse the taper of a pot.
Frank Thomson
Experimental Noize
Mcfly
Posts: 46
Joined: Fri Mar 08, 2013 2:38 pm
Location: Argentina

Post by Mcfly »

Hi! Regarding this idea, i didn't get how to implement the filtered feedback into code. If i just filter the echo feedback with a LP how can i get the repetitions become darker?
peterv wrote:
Alex MAK wrote:The term "analog" I consider the "deterioration" of each successive repeat. As is done in analog devices delay.
The idea is to feed the feedback through a shelving filter so the center frequency gets each time slightly amplified in the region of 1-2dB this initial curve should be as your tape curve at 15IPS. This would bring the deterioration based on tape throughput. The BH curve can be simulated by extracting a square wave form the initial signal and inject that at zero crossing.

The tape noise is also added only in the feedback loop if signal is present as this would keep the unit silence when not used. On my site are some write-ups on this.

Piet
frank
Posts: 1244
Joined: Wed Oct 19, 2005 12:26 pm
Contact:

Post by frank »

With a filter in the feedback loop then every time a repeat goes through the feedback path the high frequencies will be attenuated a little more and as a result cause each repeat to be a little darker.
Frank Thomson
Experimental Noize
Mcfly
Posts: 46
Joined: Fri Mar 08, 2013 2:38 pm
Location: Argentina

ANALOG ECHO

Post by Mcfly »

Hi, i would like to know how can i reach lower delay times in this example. If i lower the minimun time with SOF 0.997,0.03 (1s to 30ms) i does not work well. Thanks.

Code: Select all

;Obtener adress pointer del pot1: 
clr
rdax	pot2,1
and   %01111111_00000000_00000000   ;Bajar resolucion
sof	0.9,0.1	;100 ms a 1 s
wrax	pote1,0 

; Suavizar Pote1: 
clr            ; Limpiar Acc 
or    length*256      ; Put delay length into ACC alligned to ACC[22:8] 
mulx    pote1         ; 
rdfx    del_read, smooth      ; Suavizar: (target - current) * C + current 
wrax    del_read, 0      ; Salvar
rdax   del_read, 1.0      ; Leer el delay tap 
wrax	addr_ptr,0 
frank
Posts: 1244
Joined: Wed Oct 19, 2005 12:26 pm
Contact:

Post by frank »

Comment out the "and" line above the sof line and see if that gives you what you are looking for.
Frank Thomson
Experimental Noize
Post Reply