rotary speaker effect

Algorithm development and general DSP issues

Moderator: frank

Post Reply
Cyriakus
Posts: 1
Joined: Thu May 26, 2011 3:15 am

rotary speaker effect

Post by Cyriakus »

Hi everybody,

I'm new in this forum and just started to learn how to program the fv-1.
I need some expert help by programming a kind of rotary speaker effect.
I did a tremolo and now I want to combine it with a chourus effekt driven by the same sin_lfo to get the "doppler-effect". My problem is that separate chourus and tremolo are working perfect, but as soon as I combine them (or particulary if I combine the cho rda and cho rdal instruction) strange pitch things happen. I would be glad if someone could help me. Here is my code:

mem del1 1025

equ input REG1
equ dry REG2
equ poti REG3
equ poti_inv REG4
equ sinus0 REG5
equ chout REG6
equ cho_mix REG7

skp run, start
wlds SIN0, 10, 2048
wlds SIN1, 5, 512

start:
;---------------------------------------------------------------
;setup SIN generators and controll sin0_rate with pot0
;---------------------------------------------------------------
rdax pot0, 1
mulx pot0
sof 0.6, 0
wrax SIN0_RATE, 0
;----------------------------------------------------------------
; read SIN0 for tremolo
;----------------------------------------------------------------
clr
cho rdal, SIN0 ;load sin value in acc..... ;; if I don't compile this line chourus works perfect otherwise strange pitch things happen
sof 1.99,0.2
sof 1.2,0
wrax sinus0, 0 ;....and store value in reg

;----------------------------------------------------------------
;invert pot1 value for dry/wet mix
;----------------------------------------------------------------
rdax POT1, 1
mulx POT1
wrax poti, 1
sof 1,-1
absa
wrax poti_inv, 0

;---------------------------------------------------------------
;setup pot2 to add cho signal at output
;---------------------------------------------------------------
rdax pot2, 1
mulx pot2
wrax cho_mix, 0

;---------------------------------------------------------------
;chourus
;---------------------------------------------------------------
rdax ADCL, 0.25
rdax ADCR, 0.25
wra del1, 0
;cho rda,sin0,sin|compc,del1+200 ;If I don't compile these lines tremolo works
;cho rda,sin0,sin,del1+201
;cho rda,sin0,sin|compc,del1^
;cho rda,sin0,sin,del1^+1
mulx cho_mix
wrax chout, 0


;----------------------------------------------------------------
;left output channel
;----------------------------------------------------------------
;dry signal
rdax ADCL, 0.5
wrax input, 1
mulx poti
wrax dry, 0

;wet signal
rdax input, 1
mulx sinus0 ; if I don't compile this line chourus works perfect otherwise strange pitch things happen
mulx poti_inv
rdax dry, 1
rdax chout, 1
wrax DACL, 0


;---------------------------------------------------------------
;right output channel
;---------------------------------------------------------------
;dry signal
rdax ADCR, 0.5
wrax input, 1
mulx poti
wrax dry, 0

;wet signal
rdax input, 1
mulx sinus0 ; if I don't compile this line chourus works perfect otherwise strange pitch things happen
mulx poti_inv
rdax dry, 1
rdax chout, 1
wrax DACR, 0
frank
Posts: 1244
Joined: Wed Oct 19, 2005 12:26 pm
Contact:

Post by frank »

Rotary speakers are very difficult to emulate properly but one tip I can give you is use SIN for one output (like what you are doing) and COS for the other output to make it sound like the speaker is moving from one speaker to the other in a stereo output.
Frank Thomson
Experimental Noize
Post Reply