discuss-gnuradio
[Top][All Lists]
Advanced

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

[Discuss-gnuradio] Increase min output buffer size (python block)


From: wunsch
Subject: [Discuss-gnuradio] Increase min output buffer size (python block)
Date: Mon, 8 Apr 2013 21:51:14 +0200
User-agent: SquirrelMail/1.4.19

Hi all,

I am currently working on my DRM receiver and have written a python block
that returns either 0 or 3200 samples. Everything works fine as long as I
do not connect its output to another custom python block that consumes
only 1280 samples
per call to general_work(). Both blocks are general blocks. Now I get this
error message:

File "/usr/local/lib/python2.7/dist-packages/drmrx/freq_sync_py.py", line
120, in general_work
    out[:self.nfft] = self.correct_freq_offset(in0[:self.nfft])
ValueError: operands could not be broadcast together with shapes (1791)
(3200)
thread[thread-per-block[10]: <gr_block freq_sync_py (23)>]: caught
unrecognized exception

If I understand that correctly, the output buffer of the first block is
too small and therefore cannot take all the samples I'd like to return. I
tried to call top_block.drmrx_freq_sync_py_0.set_min_output_buffer(3200)
in the python file generated by GRC but it gave me another error:

tb.drmrx_freq_sync_py_0.set_min_output_buffer(3200)
AttributeError: 'freq_sync_py' object has no attribute
'set_min_output_buffer'

Is there a possibility to solve this problem or do I have to find an
alternative solution, e. g. creating an internal buffer?

Best regards
Felix Wunsch






reply via email to

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