[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [Discuss-gnuradio] help on xlating frequency
From: |
Paul Mathews |
Subject: |
RE: [Discuss-gnuradio] help on xlating frequency |
Date: |
Mon, 23 Mar 2009 09:54:16 -0700 |
See 'usrp_am_mw_rcv.py' for an example. Look for the code relating to these
lines in particular:
if self.use_IF:
# Turn If to baseband and filter.
self.chan_filt = gr.freq_xlating_fir_filter_ccf (chanfilt_decim,
chan_filt_coeffs, self.IF_freq, usrp_rate)
Paul Mathews
-----Original Message-----
From: feldmaus [mailto:address@hidden
Sent: Monday, March 23, 2009 6:36 AM
To: address@hidden
Subject: [Discuss-gnuradio] help on xlating frequency
Hi All,
i tried out to delete some antialiasing and the middle signal of the
FFT-Plot. Therefor i use this filter:
### VARIABLE ###
#At adc_rate=64MS/s and decim=64 we get an usrp_rate of 1 MS/s self.decim=64
self.usrp_rate=1e6
### FILTER ###
self.firdes_filt_coeffs = gr.firdes.low_pass(1,
self.usrp_rate,
self.usrp_rate*0.5,
self.usrp_rate*0.001,
gr.firdes.WIN_RECTANGULAR) self.chan_filt =
gr.freq_xlating_fir_filter_ccf (self.chanfilt_decim,
self.firdes_filt_coeffs,
self.usrp_freq,
self.usrp_rate)
### SOURCE ###
As source i use:
self.usrp_source = usrp.source_c(which=0, decim_rate=self.decim)
### SINNK ###
And as sink i use an FFT-sink-Plot:
self.wxgui_fftsink2 = fftsink2.fft_sink_c(
self.GetWin(),
baseband_freq = self.usrp_freq,
y_per_div = 10,
y_divs = 8,
ref_level = 0,
sample_rate = self.usrp_rate,
fft_size = 512*2,
fft_rate = 30,
ref_scale=11885000.0,# 11885000.0 oder 32768.0 ?
average = True,
avg_alpha = None,
title = "FFT Plot",
size=(1024, 600),
peak_hold = False,
)
### CONNECT ###
Then i connect this all together: self.connect((self.usrp_source, 0),
(self.chan_filt, 0)) self.connect((self.chan_filt, 0), (self.wxgui_fftsink2,
0))
But the antialiasing still exist and the middle signal of the FFT-Plot too.
There comes the next problem, that my spectrum in the FFT-Plot will be
shifted.
Can i use the usrp_rate in the source as well as for the xlating element ?
Or do i have to use another decimation value ? Which rate must i use for the
FFT-Plot ? Why is the low cut off frequency limited to usrp_rate/2 ?