How to get the signal-to-noise ratio of a desired frequency?

Hi everyone.

I’m new at this and reading a lot currently on how to get S/N ratio of a
range of frequencies and other basic questions.

I’ve been trying to use “usrp_spectrum_sense.py” to sense the spectrum
for
802.11 (2.402–2.4735 GHz) in the US and get the Signal-to-Noise Ratio of
their center frequencies.

I’d like to achieve a table like the following:

http://old.nabble.com/file/p27714003/Signal-to-Noise%2BRatio.png

When applying the following command:
sudo ./usrp_spectrum_sense.py 2.402G 2.4725G

Got the following console log:
http://old.nabble.com/file/p27714003/Console%2BLog%2BOriginal.txt
Console+Log+Original.txt

Changing line 152 of usrp_spectrum_sense.py
From:
usrp_rate = adc_rate / usrp_decim
To:
usrp_rate = 5000000

And also changing line 176 of usrp_spectrum_sense.py
From:
self.freq_step = 0.75 * usrp_rate
To:
self.freq_step = usrp_rate

I was able to get only the desired center frequencies I need for the
802.11
wireless spectrum.
Also had to set range to 2.4095-2.4625 GHz instead of 2.402–2.4735 GHz.

Issuing the following command after modifying the file:
sudo ./usrp_spectrum_sense.py 2.4095G 2.4625G

I got the following console output of this modified file is:
http://old.nabble.com/file/p27714003/Console%2BLog%2BModified.txt
Console+Log+Modified.txt

I wonder if making the above changes will not let me get adequate
results
since it would not discard the bins on both ends of the spectrum?

I’m also not understanding how to get the data to a file. I have read
some
threads that they say they use m.data file to see the data. I’m not sure
how
to do this. Can anyone tell me how to save/overwrite this file so I can
access its data and do something useful with it? Maybe it’s already
saved
and located in another folder? Or changes in code needed?

I was able to get this data to be displayed on the console by adding
“print
m.data” after “print m.center_freq” on main_loop function.

Maybe the correct question would be, how to save a spectrum cycle onto a
file?

Also, from my understanding, the print m.data contains the FFT value for
the
specified frequency correct?

How would I be able to find the S/N ratio from that? Where do I get the
noise from? I’m really confused :confused:

Original usrp_spectrum_sense.py:
http://old.nabble.com/file/p27714003/usrp_spectrum_sense.py
usrp_spectrum_sense.py

Modified usrp_spectrum_sense.py:
http://old.nabble.com/file/p27714003/usrp_spectrum_sense_modified.py
usrp_spectrum_sense_modified.py

Any suggestions and enlightenments would be the great!

Thanks a lot everyone!!


David Cabrejos

View this message in context:
http://old.nabble.com/How-to-get-the-signal-to-noise-ratio-of-a-desired-frequency--tp27714003p27714003.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