You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I want to filter out image frequencies ( positive and negative image frequencies) after downconversion to zero IF and need a band pass filter to pass frequencies between -50khz and 50 Khz. I have found fir filter in the library but it requires only one cutoff frequency. I want to implement dual channel receiver so I downconvert using nco and using following for filtering images but not achieving thr desires results as not knowing how to filter negative frequencies.
#define SAMPLERATE 1024000.0f
#define CUTOFF_HZ 50000.0f
#define NUM_SAMPLES 1024
float fc = CUTOFF_HZ/SAMPLERATE; // cutoff frequency
unsigned int h_len = 64; // filter length
float As = 70.0f; // stop-band attenuation
float complex r[NUM_SAMPLES]; // zero if signal nco output
float complex rf[NUM_SAMPLES]; // filtered signal
// design filter from prototype and scale to bandwidth
firfilt_crcf q = firfilt_crcf_create_kaiser(h_len, fc, As, 0.0f);
firfilt_crcf_set_scale(q, 2.0f*fc);
while (1) {
ReadzeroIFsamples(r, NUM_SAMPLES); //
for (int i=0; i<NUM_SAMPLES; i++)
firfilt_crcf_push(q, r[i]);
firfilt_crcf_execute(q, &rf[i]);
}
The text was updated successfully, but these errors were encountered:
Hi,
I want to filter out image frequencies ( positive and negative image frequencies) after downconversion to zero IF and need a band pass filter to pass frequencies between -50khz and 50 Khz. I have found fir filter in the library but it requires only one cutoff frequency. I want to implement dual channel receiver so I downconvert using nco and using following for filtering images but not achieving thr desires results as not knowing how to filter negative frequencies.
The text was updated successfully, but these errors were encountered: