USRP Software Radio

cancel
Showing results for 
Search instead for 
Did you mean: 

USRP-2943 overflow issue

Hi, everyone

    I use both USRP-2943 as the Tx and Rx and I face an overflow problem with the Rx recently. My solution is to use abort.vi and start.vi to restart a session when overflow occurs. But I found a problem with that the order the Rx fetches is wrong since old data the Rx has fetched is drop out. In a word, I mean can I have any method to manage the internal buffer in Rx to avoid the overflow issue? Very appreciate! 

 

-- Shung

0 Kudos
Message 1 of 6
(2,870 Views)

@皓翔_student wrote:

, I mean can I have any method to manage the internal buffer in Rx to avoid the overflow issue? Very appreciate! 


As long as you read as fast as the USRP writes you should be alright.

 

To do so, you need try to read faster. If you expect 1000 samples per ms, you should be ready to read before the next ms... A 1 ms wait will not work, as 1ms on the PC is not 1 ms on the USRP. If the same loop also processes the data, this should be completed in that 1 ms. To make it more robust, you can decouple the read, processing and write, but every step must still fit the 1 ms cycle.

 

Another problem could be the throughput. Reducing the bandwidth might be needed...

 

If you post some code, we might be able to find the problem... 

0 Kudos
Message 2 of 6
(2,813 Views)

Hi, wiebe

     Thanks for your respond. I do not understand that if the Rx reads faster, the internal buffer could be overflow  more probable. If I am wrong, please correct my concept. I have tried decreasing my IQ rate but the performance of synchronous is affected and the bit error rate of data is higher than the original IQ rate and the overflow occurs even when I decease the IQ rate. I set my samples as 90,240 and the IQ rate as 3.84M. 

What I confuse is that even I just read 1000 samples and overflow even occurs. I think the capability and speed of my Rx program are not well that the new arrival data reaches and old data is not dealt yet. Or  Tx is pretty much faster than Rx. 

Sorry I could just post the image of program. 

Overflow ignore.jpg

Front_Panel.jpg

0 Kudos
Message 3 of 6
(2,807 Views)

That's not your program, that's just 1 VI and some error handling...

 

You'll get an overflow if:

  • You don't read a buffer fast enough.
  • You write a buffer too fast.

 

Without seeing what you're doing it's going to be hard to advice.

 


@皓翔_student wrote:

What I confuse is that even I just read 1000 samples and overflow even occurs.


Usually reading more samples is more efficient.

 

Reading 1000 samples gives less latency, but more overhead (as each read has overhead, and you have more reads). You I'd increase it if you can afford the latency.

0 Kudos
Message 4 of 6
(2,787 Views)

Hi, weibe

    Sorry, indeed, it is hard to understand without the program. Since the limit, I offer the shot of a part of my program. Thanks for your attention on my question. Please specify the wrong in my program. Very appreciate. Image Part 1 is the initial session part of RX. Image Part 2 is the setting of RX. 

Download All
0 Kudos
Message 5 of 6
(2,772 Views)

That is still not the program, but a part of it.

 

It looks from this part that you're reading, processing, writing in a sequence. That means the read is delayed by the processing and the write.

 

You will have better results if you de-sequence the execution. If you put the read data in a shift register, you can process it in the next iteration. Put the processed data in a shift register, and it can be send the next cycle.

 

Or, make 3 loops, and put the read data on a queue, process it in a 2nd loop. Put that on a different queue, write it in a 3rd loop.

0 Kudos
Message 6 of 6
(2,730 Views)