discuss-gnuradio
[Top][All Lists]
Advanced

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

Re: [Discuss-gnuradio] scratch space in output buffer


From: Ron Economos
Subject: Re: [Discuss-gnuradio] scratch space in output buffer
Date: Tue, 30 May 2017 13:32:34 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.1

If you call set_output_multiple() in your block constructor, it will guarantee the size of the output buffer. The scheduler won't touch it until you exit your block with:

return noutput_items;

Ron

On 05/30/2017 12:57 PM, Miklos Maroti wrote:
Hi,

I would like to use scratch space within the output buffer of a block,
but not sure if I can rely on the scheduler not altering the content
of those items in the output buffer that I have written to but have
not made it available to downstream blocks within general_work. I know
how blocks, forecast, general_work and history works, but I think my
use case is not covered.

A simple toy use case would be to implement a fir filter without the
history call (I know that in this case history is better). Once a new
sample is taken from the input you multiply that with an N-length
kernel and add it to the output buffer and output only one item and
zero out N-item ahead.

Can I rely on the scheduler not to modify unproduced items (but of
course within the limits of ninput_items)? Should I return 0 for
forecast when there is not enough space in the output buffer? Would
such a block be synchronous?

Best,
Miklos

_______________________________________________
Discuss-gnuradio mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio





reply via email to

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