Flowgraph stop execution when changing sample rate of uhd_single_usrp_source

Greetings,

Yesterday I updated my gnuradio/next and UHD installations to:
UHD_0001.20101204162446.a51fb2e
v3.3.1git-322-ge92f2cb6

I noticed that when changing USRP sample rates using
uhd_single_usrp_source the flowgraph will suspend execution and CPU
load drops to 0.
The flowgraph is still alive in the sense that it is responsive to UI
commands and sometimes even resumes execution for 5-10 seconds then
stops again. No error message appears in the terminal.

The previous versions I have installed don’t have this problem:
UHD_0001.20101124180824.2568efd
v3.3.1git-227-gb245c628

I also tried the combination UHD_0001.20101124180824.2568efd +
v3.3.1git-322-ge92f2cb6 and it also has this problem which lead me to
suspect gr-uhd rather than uhd.

I am using USRP1 and this happens with both WBX and RFX2400.
My application is written in Python and Qt, though I don’t think that
makes any difference because I can reproduce it even with the simplest
GRC flowgraph (attached). The major difference is that my application
uses gr.top_block.lock() and unlock() when changing sample rate and
doing some other reconfiguration, and this is probably why the
flowgraph sometimes resumes execution for a few seconds.

Let me know if any other info or testing is needed.

Alex

On 12/05/2010 08:17 AM, Alexandru C. wrote:

commands and sometimes even resumes execution for 5-10 seconds then
stops again. No error message appears in the terminal.

The previous versions I have installed don’t have this problem:
UHD_0001.20101124180824.2568efd
v3.3.1git-227-gb245c628

I also tried the combination UHD_0001.20101124180824.2568efd +
v3.3.1git-322-ge92f2cb6 and it also has this problem which lead me to
suspect gr-uhd rather than uhd.

There was a change to the uhd single usrp source to support the tags. It
might be getting into a condition that gets stuck in the work function.

size_t total_samps = 0;
while(total_samps + 362 < (size_t)noutput_items) {
size_t num_samps = _dev->get_device()->recv(
output_items, noutput_items, metadata,
//_type, uhd::device::RECV_MODE_FULL_BUFF
_type, uhd::device::RECV_MODE_ONE_PACKET
);

This code looks really wrong. It will loop and the output_items pointer
doesnt increase. There is also some magic constant in there. Tom?

-Josh

On Sun, Dec 5, 2010 at 12:22 PM, Josh B. [email protected] wrote:

uhd_single_usrp_source the flowgraph will suspend execution and CPU
v3.3.1git-322-ge92f2cb6 and it also has this problem which lead me to
//_type, uhd::device::RECV_MODE_FULL_BUFF
_type, uhd::device::RECV_MODE_ONE_PACKET
);

This code looks really wrong. It will loop and the output_items pointer
doesnt increase. There is also some magic constant in there. Tom?

-Josh

Yeah, there is something wrong there. We threw this together WAY too
quickly the other week. I’ll look into this tomorrow. My N210 isn’t
responding to network updates of the new images and I can’t spend any
more time on this tonight.

Tom