|
From: | Marcus Müller |
Subject: | Re: [Discuss-gnuradio] block without work function won't stop |
Date: | Tue, 26 May 2015 14:29:50 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 |
Hi Nemanja, the point is that with message passing, it's not clear that your block is ever finished. Hence in block.cc, we have a mechanism to retrieve the "finishedness" of a pure-message-block. bool block::finished() { if((detail()->ninputs() != 0) || (detail()->noutputs() != 0)) return false; else return d_finished; } So, you'll have to set the d_finished variable of your block; sadly, that's a private one by design (I think there are thread-safety reasons this is not directly exposed, but I'm not sure -- I'd have to as T[io]m about that). The proper way to do so is to send your block a message to its pmt::mp("system") port, containing pmt::mp("done"). Best regards, Marcus On 05/26/2015 02:10 PM, Nemanja Savic
wrote:
|
[Prev in Thread] | Current Thread | [Next in Thread] |