commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r10354 - gnuradio/trunk/gr-utils/src/python


From: matt
Subject: [Commit-gnuradio] r10354 - gnuradio/trunk/gr-utils/src/python
Date: Sat, 31 Jan 2009 16:23:31 -0700 (MST)

Author: matt
Date: 2009-01-31 16:23:27 -0700 (Sat, 31 Jan 2009)
New Revision: 10354

Modified:
   gnuradio/trunk/gr-utils/src/python/usrp2_fft.py
Log:
set fft-size from command line, default to 12 divs vertical


Modified: gnuradio/trunk/gr-utils/src/python/usrp2_fft.py
===================================================================
--- gnuradio/trunk/gr-utils/src/python/usrp2_fft.py     2009-01-31 23:22:20 UTC 
(rev 10353)
+++ gnuradio/trunk/gr-utils/src/python/usrp2_fft.py     2009-01-31 23:23:27 UTC 
(rev 10354)
@@ -58,6 +58,8 @@
                          help="Set fftsink averaging factor, 
default=[%default]")
        parser.add_option("", "--ref-scale", type="eng_float", default=1.0,
                          help="Set dBFS=0dB input value, default=[%default]")
+        parser.add_option("--fft-size", type="int", default=1024,
+                          help="Set number of FFT bins [default=%default]")
         (options, args) = parser.parse_args()
         if len(args) != 0:
             parser.print_help()
@@ -76,8 +78,12 @@
         elif options.oscilloscope:
             self.scope = scopesink2.scope_sink_c(panel, sample_rate=input_rate)
         else:
-            self.scope = fftsink2.fft_sink_c (panel, fft_size=1024, 
sample_rate=input_rate, 
-                                             ref_scale=options.ref_scale, 
ref_level=0.0, y_divs = 10,
+            self.scope = fftsink2.fft_sink_c (panel,
+                                              fft_size=options.fft_size,
+                                              sample_rate=input_rate, 
+                                             ref_scale=options.ref_scale,
+                                              ref_level=20.0,
+                                              y_divs = 12,
                                              avg_alpha=options.avg_alpha)
 
         self.connect(self.u, self.scope)





reply via email to

[Prev in Thread] Current Thread [Next in Thread]