discuss-gnuradio
[Top][All Lists]
Advanced

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

Re: [Discuss-gnuradio] Extracting intermediate data


From: Martin DvH
Subject: Re: [Discuss-gnuradio] Extracting intermediate data
Date: Wed, 21 Jan 2009 02:50:09 +0100

On Tue, 2009-01-20 at 15:33 -0500, Catalin Lacatus wrote:
> Hello,
> 
> I am working with usrp_spectrum_sense.py and I am trying to analyze the 
> intermediate data from different DSP blocks.
> 
> After I passed the input stream to a vector I tried to save this information 
> on a file like this:
> 
>  
> 
>         /s2v = gr.stream_to_vector(gr.sizeof_gr_complex, self.fft_size)
> 
>         output2=gr.file_sink(gr.sizeof_gr_complex,"file2.txt")
> 
>         self.connect(self.u, s2v, output2)/
> 
You should have written
output2=gr.file_sink(gr.sizeof_gr_complex*self.fft_size,"file2.txt")
You are now getting vectors of 128 complex values as one item.

Success,
Martin
>  
> 
> 
> 
> and I received the following error:
> 
>  
> 
> /node1-2:~/gnuradio/gnuradio-examples/python/usrp# ./usrp_spectrum_sense.py 
> -F 16 4.5M 7.5M
> 
> Using RX d'board A: Basic Rx
> 
> Traceback (most recent call last):
> 
>   File "./usrp_spectrum_sense.py", line 305, in <module>
> 
>     tb = my_top_block()
> 
>   File "./usrp_spectrum_sense.py", line 179, in __init__
> 
>     self.connect(self.u, s2v, output2)
> 
>   File "/usr/local/lib/python2.5/site-packages/gnuradio/gr/top_block.py", 
> line 70, in connect
> 
>     self._connect(points[i-1], points[i])
> 
>   File "/usr/local/lib/python2.5/site-packages/gnuradio/gr/top_block.py", 
> line 76, in _connect
> 
>     dst_block.basic_block(), dst_port)
> 
>   File 
> "/usr/local/lib/python2.5/site-packages/gnuradio/gr/gnuradio_swig_py_runtime.py",
>  line 1469, in connect
> 
>     return _gnuradio_swig_py_runtime.gr_top_block_sptr_connect(*args)
> 
> ValueError: itemsize mismatch: stream_to_vector(4):0 using 128, 
> file_sink(5):0 using 8/
> 
> / /
> 
>  
> 
> It seems to be a format mismatch.
> Please any advice how to write the output of s2v to a file.
> 
>  
> 
> Thank you,
> Catalin
> 
> 
> 
> _______________________________________________
> Discuss-gnuradio mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/discuss-gnuradio
> 





reply via email to

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