Thanks, that worked. :)

Am 17.01.2018 um 23:20 schrieb Sakthivel Velumani:
> Hi Markus,
> 
> A better way is to specify the amount of data you need for the
> processing in the forecast function. By doing so, the GNU Radio
> scheduler will guarantee the sufficient amount of input data and hence
> you can remove the return 0 from the work function.
> 
> Best,
> Sakthivel
> 
> On Wed, Jan 17, 2018 at 3:20 PM, Markus Wirsing
> <markus.wirs...@uni-ulm.de <mailto:markus.wirs...@uni-ulm.de>> wrote:
> 
>     Hello,
> 
>     I have the following problem:
> 
>     I wrote a block that does some processing and needs to look ahead in the
>     data for a certain amount.
>     Therefore the work function of the sync_block will return 0 if the
>     current amount of data is insufficient.
> 
>     This works fine if the program is running infinitely.
>     However, when using a head block and running to completion,
>     it can occur that there is no more data available, which leads to the
>     scheduler infinitely trying again to call the work function, which then
>     returns 0.
>     Can this be detected by the block, so that the block can empty the input
>     buffer and the program can complete?
> 
>     Or is there another good way to solve this problem?
>     I feel like this should be a common problem, but I haven't found a good
>     solution.
> 
>     Thank you in advance for any hints on how to solve this.
> 
>     _______________________________________________
>     Discuss-gnuradio mailing list
>     Discuss-gnuradio@gnu.org <mailto:Discuss-gnuradio@gnu.org>
>     https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>     <https://lists.gnu.org/mailman/listinfo/discuss-gnuradio>
> 
> 

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

Reply via email to