Question about ZeroMQ Sub source

I’ve got a question relating to the zmq sub source.
I’ve got a flowgraph that has rtlsdr -> pub sink

In another graph, I decode FM radio using WBFM receive.
I noticed that it sounds horrible and choppy (sped up).
I looked in the code of the sub source, and saw this

        // Copy to output buffer and return
        if (msg.size() >= d_itemsize*noutput_items)
        {
            memcpy(out, (void *) msg.data(), 

d_itemsize*noutput_items);
return noutput_items;
} else
{
memcpy(out, (void *) msg.data(), msg.size());
return msg.size() / (d_itemsize);
}

Does this mean that if the message size is greater then the number of
items
requested by scheduler * item size (e.g. complex = 8), the rest of the
message is simply dropped?

This is probably the reason for the choppy audio. How can a situation
like
this be avoided?

Setting max number of output items in both graphs seems to help this.


Discuss-gnuradio mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

I tried it but it’s still very choppy.

I’m not 100% on the scheduler, but if the downstream graph requests 4096
items, and the zmq message size is 8192 items, wouldn’t this result in
choppy audio?

Regards,
Vanush

On Sun, Aug 31, 2014 at 3:56 AM, Johnathan C.
[email protected]