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)/
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
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