normalize phasor after each step

okay, i never had run robot36 for a long time so never had any issues
with it. but when letting it run for a few hours, the magnitude of that
phasor has drifted too far.
master
Ahmet Inan 2014-11-26 13:06:29 +01:00
rodzic d8eeba3aed
commit b0ad979240
1 zmienionych plików z 1 dodań i 1 usunięć

2
ddc.c
Wyświetl plik

@ -28,7 +28,7 @@ void do_ddc(struct ddc *ddc, float *input, complex float *output)
output[k] = ddc->osc * sum;
ddc->osc *= ddc->d;
// ddc->osc /= cabsf(ddc->osc); // not really needed
ddc->osc /= cabsf(ddc->osc);
}
}
struct ddc *alloc_ddc(int L, int M, float carrier, float bw, float rate, int taps, float (*window)(float, float, float), float a)