discuss-gnuradio
[Top][All Lists]
Advanced

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

[Discuss-gnuradio] scope too slow?


From: Ramakrishnan Muthukrishnan
Subject: [Discuss-gnuradio] scope too slow?
Date: Tue, 22 Feb 2005 23:39:59 +0530
User-agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (gnu/linux)

I ran the following code and it just crawls my Athlon64 2Ghz to halt.
'top' shows that the memory usage goes on increasing and increasing.
Anyone else experiencing the same problem? Is there anything wrong
I am doing here? The code is given below.

-- 
    Ramakrishnan                   http://www.hackGNU.org/
    Use Free Software -- Help stamp out Software Hoarding!


#!/usr/bin/python
# copyright (c) 2005, FSF under the GNU GPL v2 or later
# Author: Ramakrishnan Muthukrishnan <address@hidden>
#

from gnuradio import gr
from gnuradio import audio
from gnuradio.wxgui import stdgui, fftsink, scopesink
import sys
import os
import wx

class app_flow_graph (stdgui.gui_flow_graph):
    def __init__(self, frame, panel, vbox, argv):
        stdgui.gui_flow_graph.__init__ (self, frame, panel, vbox, argv)

        sampling_freq = 8000

        # create a probe
        #block, fft_win = fftsink.make_fft_sink_f (self, panel, "Spectrum", 
2048, sampling_freq)
        block, scope_win = scopesink.make_scope_sink_f (self, panel, 
"time_domain", sampling_freq)

        src = gr.sig_source_f (sampling_freq,gr.GR_SIN_WAVE,2100,1.0,0) 

        n_taps = 201
        hilbert = gr.hilbert_fc (n_taps)

        real = gr.complex_to_real()
        imag = gr.complex_to_imag()        

        self.connect (src, hilbert)
        self.connect (hilbert, real)
        self.connect (hilbert, imag)

        self.connect (real, (block,0))
        self.connect (imag, (block,1))        
        vbox.Add (scope_win, 1, wx.EXPAND)

if __name__ == '__main__':
    app = stdgui.stdapp (app_flow_graph, "Spectrum")
    app.MainLoop ()




reply via email to

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