I m using USRP2,I have configured usrp2 and tested
uhd_usrp_probe,uhd_siggen_gui and uhd_fft all works fine.
Now i want to make my own program like uhd_fft but there is a problem
that
the terminal prompt returns right after i execute the program with
notification
root@aqs-desktop:/home/aqs/Desktop# python my_uhd_fft.py
linux; GNU C++ version 4.4.3; Boost_104000;
UHD_003.004.003-224-gc2e197c0
root@aqs-desktop:/home/aqs/Desktop#
my_uhd_fft.py program is:
from gnuradio import uhd
from gnuradio import gr
from gnuradio.wxgui import stdgui2,fftsink2
import wx
class top_block(stdgui2.std_top_block):
def __init__(self):
self.addr=uhd.device_addr()
self.u = uhd.usrp_source(self.addr,\
uhd.io_type.COMPLEX_FLOAT32, 1)
self.u.set_samp_rate(40000000)
self.scope = fftsink2.fft_sink_c (panel, \
512, 40000000)
self.connect(self.u, self.scope)
if __name__ == '__main__()':
app = stdgui2.stdapp(top_block,"FFT",nstatus=1)
app.MainLoop()
Regards
Bilal Abbasi
Student
COMSATS Institute of information technology Pakistan.
--
View this message in context:
http://gnuradio.4.n7.nabble.com/USRP2-Reception-Pr...
Sent from the GnuRadio mailing list archive at Nabble.com.
on 2012-09-26 07:53
on 2012-09-26 20:52
On 09/26/2012 01:52 AM, Bilal wrote: > > self.u = uhd.usrp_source(self.addr,\ > uhd.io_type.COMPLEX_FLOAT32, 1) > self.u.set_samp_rate(40000000) > self.scope = fftsink2.fft_sink_c (panel, \ > 512, 40000000) > self.connect(self.u, self.scope) > if __name__ == '__main__()': > app = stdgui2.stdapp(top_block,"FFT",nstatus=1) > app.MainLoop() > I'm not 100% positive that the flow graph is actually started in this case. I highly recommend that you put a similar application together in GRC with USRP source and WX scope sink block. You will get nicely generated code too! -josh
Please log in before posting. Registration is free and takes only a minute.
Existing account
(Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
Log in with Google account | Log in with Yahoo account
No account? Register here.