All,
fft_sink_c() and fft_sink_f() in fftsink2.py scale the output by the fft size using -20 log10(fft_size) I think the intent is to make the output level independent of fft size. Currently the output is a function of fft size. See attached code (fftsink2_example.py). I think the scaling should be -10 log10(fftsize) . Please see the attached suggested patch to fftsink2.py Tim
#!/usr/bin/python
from gnuradio import gr
import wx
from gnuradio.wxgui import stdgui2, fftsink2
class test_app_block (stdgui2.std_top_block):
def __init__(self, frame, panel, vbox, argv):
stdgui2.std_top_block.__init__ (self, frame, panel, vbox, argv)
src1 = gr.noise_source_c (gr.GR_GAUSSIAN, 1)
thr1 = gr.throttle(gr.sizeof_gr_complex, 1e4)
sink1 = fftsink2.fft_sink_c (panel, title="64 point", fft_size=64,
average=True,ref_level=10)
vbox.Add (sink1.win, 1, wx.EXPAND)
sink2 = fftsink2.fft_sink_c (panel, title="4096 point", fft_size=4096,
average=True,ref_level=10)
vbox.Add (sink2.win, 1, wx.EXPAND)
self.connect(src1, thr1, sink1)
self.connect(thr1, sink2)
def main ():
app = stdgui2.stdapp (test_app_block, "Test Adjust Num Bins")
app.MainLoop ()
if __name__ == '__main__':
main ()
suggested_fftsink2_patch
Description: Binary data
_______________________________________________ Discuss-gnuradio mailing list [email protected] http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
