 # Sense spectrum by usrp_spectrum_sense.py

Hi All,

I am using usrp_spectrum_sense.py 1400M 2000M -F 512 -d 16 --tune-delay
1e-3
–dwell-delay 10e-3 to sense the spectrum.

In main_loop(tb), I print m.center_freq and m.data.
freq_step = 0.75 * usrp_rate=0.75*(64M/16)=3M. So
m.center_freq=1401.5M,
m.data~m.data are 512 bins corresponding to m.center_freq;
m.center_freq=1404.5M, m.data~m.data are 2nd 512 bins
corresponding to m.center_freq, and so on.

There are some comment lines say:
# m.data are the mag_squared of the fft output (they are in the
# standard order. I.e., bin 0 == DC.)
# You’ll probably want to do the equivalent of “fftshift” on
them
# m.raw_data is a string that contains the binary floats.
# You could write this as binary to a file.

So actually, for each 512 bins, (m.data) to (m.data) are
mag_squared
values for (m.center) to (m.center +freq_step/2), and
(m.data) to
(m.data) are mag_squared values for (m.center-freq_step/2) to
(m.center). Am I right? How to use fftshift here? Dose
fftshift(m.data)
give me regular order? Are fftshift(m.data) mag_squared values
corresponding
to [(m.center-freq_step/2):(m.center+freq_step/2)]?

If I plot all m.data or fftshift(m.data) versus all the m.center_freq
from
1400M to 2000M, I should get the whole spectrum from 1400M upto 2000M.
Did I
do right here? Can I get time domain signal if I do ifft(m.data)? I
suppose
not. Because m.data are mag_squared rather than mag. If not, how can I
get
the time-domain signal before fft, from 1400M to 2000M?

Thanks,
Brook

View this message in context:
http://www.nabble.com/Sense-spectrum-by-usrp_spectrum_sense.py-tp16261178p16261178.html
Sent from the GnuRadio mailing list archive at Nabble.com.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs