fix parameter naming mistake: rolloff -> transition_bw

This commit is contained in:
ha7ilm 2014-12-13 23:46:41 +01:00
parent a671a43898
commit 9e5ce0cc3b
3 changed files with 4 additions and 4 deletions

View file

@ -47,7 +47,7 @@ Usage by example
- We want to listen to one radio station, but input signal contains multiple stations, and its bandwidth is too large for sending it directly to the FM demodulator.
- We shift the signal to the center frequency of the station we want to receive: `-0.085*2400000 = -204000`, so basically we will listen to the radio station centered at 89504000 Hz.
- We decimate the signal by a factor of 10. The rolloff for the FIR filter used for decimation will be 10% of total bandwidth (as of parameter 0.05 is 10% of 0.5). Hamming window will be used for windowed FIR filter design.
- We decimate the signal by a factor of 10. The transition bandwidth of the FIR filter used for decimation will be 10% of total bandwidth (as of parameter 0.05 is 10% of 0.5). Hamming window will be used for windowed FIR filter design.
Sample rates look like this:

View file

@ -165,9 +165,9 @@ void firdes_bandpass_c(complexf *output, int length, float lowcut, float highcut
}
}
int firdes_filter_len(float rolloff)
int firdes_filter_len(float transition_bw)
{
int result=4.0/rolloff;
int result=4.0/transition_bw;
if (result%2==0) result++; //number of symmetric FIR filter taps should be odd
return result;
}

View file

@ -86,7 +86,7 @@ float firdes_wkernel_hamming(float input);
float firdes_wkernel_boxcar(float input);
window_t firdes_get_window_from_string(char* input);
char* firdes_get_string_from_window(window_t window);
int firdes_filter_len(float rolloff);
int firdes_filter_len(float transition_bw);
//demodulators
complexf fmdemod_quadri_cf(complexf* input, float* output, int input_size, float *temp, complexf last_sample);