Harrison374
Posts: 1
Joined: Sat Nov 03, 2018 5:33 am

Have you looked at rtl_power?

Tue Feb 12, 2019 10:23 am

Spectrogram, have you looked at rtl_power?

Code: Select all

rtl_power, a simple FFT logger for RTL2832 based DVB-T receivers

Use:    rtl_power -f freq_range [-options] [filename]
        -f lower:upper:bin_size [Hz]
         (bin size is a maximum, smaller more convenient bins
          will be used.  valid range 1Hz - 2.8MHz)
        [-i integration_interval (default: 10 seconds)]
         (buggy if a full sweep takes longer than the interval)
        [-1 enables single-shot mode (default: off)]
        [-e exit_timer (default: off/0)]
        [-d device_index (default: 0)]
        [-g tuner_gain (default: automatic)]
        [-p ppm_error (default: 0)]
        [-T enable bias-T on GPIO PIN 0 (works for rtl-sdr.com v3 dongles)]
        filename (a '-' dumps samples to stdout)
         (omitting the filename also uses stdout)Experimental options:
        [-w window (default: rectangle)]
         (hamming, blackman, blackman-harris, hann-poisson, bartlett, youssef)
        [-c crop_percent (default: 0%, recommended: 20%-50%)]
         (discards data at the edges, 100% discards everything)
         (has no effect for bins larger than 1MHz)
        [-F fir_size (default: disabled)]
         (enables low-leakage downsample filter,
          fir_size can be 0 or 9.  0 has bad roll off,
          try with '-c 50%')
        [-P enables peak hold (default: off)]
        [-D enable direct sampling (default: off)]
        [-O enable offset tuning (default: off)]

CSV FFT output columns:
        date, time, Hz low, Hz high, Hz step, samples, dbm, dbm, ...

         Examples:
        rtl_power -f 88M:108M:125k fm_stations.csv
         (creates 160 bins across the FM band,
          individual stations should be visible)
        rtl_power -f 100M:1G:1M -i 5m -1 survey.csv
         (a five minute low res scan of nearly everything)
        rtl_power -f ... -i 15m -1 log.csv
         (integrate for 15 minutes and exit afterwards)
        rtl_power -f ... -e 1h | gzip > log.csv.gz
         (collect data for one hour and compress it on the fly)

Convert CSV to a waterfall graphic with:
         http://kmkeen.com/tmp/heatmap.py.txt 
I don't really like the heatmap.py that comes with it so I created my own. This is done from the csv file that rtl_power outputs. I pirated the font from an old giflib. The palette converting signal intensity to color came from one of Learmonth's gifs http://www.bom.gov.au/metadata/catalogu ... 0483.shtml.mcdvoice But same technique as writing to a framebuffer, I was just using jpjeglib to make jpeg files intead. I had to reduce the size or the RPI board said it was too big. You can see my dongle being flaky at the top above about 1200 MHz. This is from 2016.

hi5blast1
Posts: 1
Joined: Mon Mar 04, 2019 4:59 am

Re: Have you looked at rtl_power?

Mon Mar 04, 2019 5:04 am

Harrison374 wrote:
Tue Feb 12, 2019 10:23 am
Spectrogram, have you looked at rtl_power?

Code: Select all

rtl_power, a simple FFT logger for RTL2832 based DVB-T receivers

Use:    rtl_power -f freq_range [-options] [filename]
        -f lower:upper:bin_size [Hz]
         (bin size is a maximum, smaller more convenient bins
          will be used.  valid range 1Hz - 2.8MHz)
        [-i integration_interval (default: 10 seconds)]
         (buggy if a full sweep takes longer than the interval)
        [-1 enables single-shot mode (default: off)]
        [-e exit_timer (default: off/0)]
        [-d device_index (default: 0)]
        [-g tuner_gain (default: automatic)]
        [-p ppm_error (default: 0)]
        [-T enable bias-T on GPIO PIN 0 (works for rtl-sdr.com v3 dongles)]
        filename (a '-' dumps samples to stdout)
         (omitting the filename also uses stdout)Experimental options:
        [-w window (default: rectangle)]
         (hamming, blackman, blackman-harris, hann-poisson, bartlett, youssef)
        [-c crop_percent (default: 0%, recommended: 20%-50%)]
         (discards data at the edges, 100% discards everything)
         (has no effect for bins larger than 1MHz)
        [-F fir_size (default: disabled)]
         (enables low-leakage downsample filter,
          fir_size can be 0 or 9.  0 has bad roll off,
          try with '-c 50%')
        [-P enables peak hold (default: off)]
        [-D enable direct sampling (default: off)]
        [-O enable offset tuning (default: off)]

CSV FFT output columns:
        date, time, Hz low, Hz high, Hz step, samples, dbm, dbm, ...

         Examples:
        rtl_power -f 88M:108M:125k fm_stations.csv
         (creates 160 bins across the FM band,
          individual stations should be visible)
        rtl_power -f 100M:1G:1M -i 5m -1 survey.csv
         (a five minute low res scan of nearly everything)
        rtl_power -f ... -i 15m -1 log.csv
         (integrate for 15 minutes and exit afterwards)
        rtl_power -f ... -e 1h | gzip > log.csv.gz
         (collect data for one hour and compress it on the fly)

Convert CSV to a waterfall graphic with:
         http://kmkeen.com/tmp/heatmap.py.txt 
I don't really like the heatmap.py that comes with it so I created my own. This is done from the csv file that rtl_power outputs. I pirated the font from an old giflib. The palette converting signal intensity to color came from one of Learmonth's gifs http://www.bom.gov.au/metadata/catalogu ... 0483.shtml.AT&T But same technique as writing to a framebuffer, I was just using jpjeglib to make jpeg files intead. I had to reduce the size or the RPI board said it was too big. You can see my dongle being flaky at the top above about 1200 MHz. This is from 2016.
Can you Explain the issue again?

User avatar
ab1jx
Posts: 868
Joined: Thu Sep 26, 2013 1:54 pm
Location: Heath, MA USA
Contact: Website

Re: Have you looked at rtl_power?

Tue May 07, 2019 12:05 am

Take a look at https://sourceforge.net/p/fmplot/ I just wrote it for plotting the US FM broadcast band to find nrsc5 (AKA HD FM) stations. They're about twice as wide as traditional analog FM stations so they're fairly visible. It uses rtl_power to scan, formats the output and feeds ti to Gnuplot to make a .png file. Takes about 15 seconds.

It could be changed for other frequency ranges, change the

Code: Select all

char cmd[] = "rtl_power -f 88M:108M:5k -1 -";
line in live(). It's start (colon) end (colon) step after the -f. This web software really freaked out when I used :, gave me huge text.

Then, because rtl_power deals with Hertz and Gnuplot's plotting MHz, you need to change Gnuplot's xtics in the line

Code: Select all

  fprintf(gpf,"set xtics 88.0,0.1,108\n");
 
in run_gnuplot(). Frequencies are divided by 1,000,000 before feeding to Gnuplot but the label is hard-coded. Here it's start, step, end instead. I guess I could have that more automatic.

You need to change the frequency values in the
set xrange [88.000000:108.000000]
nrsc5.png
nrsc5.png (108.31 KiB) Viewed 653 times
I'm working on a newer version where you can specify start and end frequencies on the command line, and a couple other enhancements.

xromix
Posts: 1
Joined: Tue Nov 05, 2019 8:29 am
Contact: Website

Re: Have you looked at rtl_power?

Tue Nov 05, 2019 8:37 am

rtl_power, a simple FFT logger for RTL2832 based DVB-T receivers

Use: rtl_power -f freq_range [-options] [filename]
-f lower:upper:bin_size [Hz]
(bin size is a maximum, smaller more convenient bins
will be used. valid range 1Hz - 2.8MHz)
[-i integration_interval (default: 10 seconds)]
(buggy if a full sweep takes longer than the interval)
[-1 enables single-shot mode (default: off)]
[-e exit_timer (default: off/0)]
[-d device_index (default: 0)]
[-g tuner_gain (default: automatic)]
[-p ppm_error (default: 0)]
[-T enable bias-T on GPIO PIN 0 (works for rtl-sdr.com v3 dongles)]
filename (a '-' dumps samples to stdout)
(omitting the filename also uses stdout)Experimental options:
[-w window (default: rectangle)]
(hamming, blackman, blackman-harris, hann-poisson, bartlett, youssef)
[-c crop_percent (default: 0%, recommended: 20%-50%)]
(discards data at the edges, 100% discards everything)
(has no effect for bins larger than 1MHz)
[-F fir_size (default: disabled)]
(enables low-leakage downsample filter,
fir_size can be 0 or 9. 0 has bad roll off,
try with '-c 50%')
[-P enables peak hold (default: off)]
[-D enable direct sampling (default: off)]
[-O enable offset tuning (default: off)]

CSV FFT output columns:
date, time, Hz low, Hz high, Hz step, samples, dbm, dbm, ...

Examples:
rtl_power -f 88M:108M:125k fm_stations.csv
(creates 160 bins across the FM band,
individual stations should be visible)
rtl_power -f 100M:1G:1M -i 5m -1 survey.csv
(a five minute low res scan of nearly everything)
rtl_power -f ... -i 15m -1 log.csv
(integrate for 15 minutes and exit afterwards)
rtl_power -f ... -e 1h | gzip > log.csv.gz
(collect data for one hour and compress it on the fly)

Convert CSV to a waterfall graphic with:
http://kmkeen.com/tmp/heatmap.py.txt
हमारे ब्लॉग pradhanmantri-yogana.in/ पर आपका स्वागत है| यह ब्लॉग आपकोhttps://pradhanmantri-yogana.in/ Pradhan Mantri Yojana के बारे में जानकारी प्रदान करता है| इस ब्लॉग से आपको pradhan mantri Jan Dhan Yojana

Return to “Troubleshooting”