# Repeatability of delivery ratios using benchmark\_tx/rx

**URL:** <https://www.ruby-forum.com/t/repeatability-of-delivery-ratios-using-benchmark-tx-rx/236984>\
**Category:** GNU Radio\
**Created:** [October 17, 2013, 4:24am UTC](https://www.ruby-forum.com/t/repeatability-of-delivery-ratios-using-benchmark-tx-rx/236984 "2013-10-17T04:24:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![alcina](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a587f6/32.png) [@alcina](https://www.ruby-forum.com/u/alcina)\
**Post date:** [October 17, 2013, 4:24am UTC](https://www.ruby-forum.com/t/repeatability-of-delivery-ratios-using-benchmark-tx-rx/236984/1 "2013-10-17T04:24:04Z")

</div>

Hi All,

I have two USRP N210 devices connected by an attenuator cable. I set up  
the  
following experiments.

– BEGIN EXPERIMENT 1

Step 1) Use benchmark\_tx on one of the USRPs and send 100 packets. At  
the  
receiver, I simply record the incoming samples and save them into a file  
called samples1.dat. This file is static and does not change from now  
on.

Step 2) Run benchmark\_rx with the --from-file=samples1.dat option. The  
other parameters (modulation, fft-length, occupied-tones, etc) are  
identical to those I used at the transmitter in Step 1. Measure the  
packet  
delivery rate.

Step 3) Repeat Step 2 a bunch of times. Sometimes, I notice differences  
in  
the packet delivery ratios, even though all runs of the experiment use  
the  
identical ‘samples1.dat’ file and an identical set of parameters These  
differences are small (1-2 packet difference), but I don’t understand  
why  
they exist.

Is this normal behavior? If so, could someone please let me know what  
the  
probable causes are?

– END EXPERIMENT 1

The next experiment does not use either of the USRP devices.

– BEGIN EXPERIMENT 2

1. Use benchmark\_tx to generate 100 packets, and write the samples into  
a  
file (samples2.dat) using the --to-file option.

2. Use benchmark\_rx with the --from-file=samples2.dat option and check  
the  
packet delivery rate. The parameters used (fft-length, etc) are  
obviously  
identical to those used to generate the samples in Step 1. I observe  
that  
the delivery rate is never even close to 100%.

3. Change to a different parameter set and repeat steps 1 and 2. Across  
different runs, I observe that the delivery rate is anywhere between 30%  
and 85%.

This cannot be the expected behavior. Any pointers on what I’m doing  
wrong  
would be much appreciated!

– END EXPERIMENT 2

Thanks!

Aditya

---

<div class="post-metadata">

**Author:** ![hungry-fish](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/a3d4f5/32.png) [@hungry-fish](https://www.ruby-forum.com/u/hungry-fish)\
**Post date:** [October 17, 2013, 4:31am UTC](https://www.ruby-forum.com/t/repeatability-of-delivery-ratios-using-benchmark-tx-rx/236984/2 "2013-10-17T04:31:05Z")

</div>

On Wed, Oct 16, 2013 at 10:22 PM, Aditya D.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> file (samples2.dat) using the --to-file option.  
> This cannot be the expected behavior. Any pointers on what I’m  
> doing wrong would be much appreciated!
> 
> – END EXPERIMENT 2
> 
> Thanks!
> 
> Aditya

I should have made a brief mention of my environment:

GNU Radio 3.7.1 installed from source  
Ubuntu 12.04 LTS (64-bit)  
Thanks!

Aditya

---

<div class="post-metadata">

**Author:** ![hungry-fish](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/h/a3d4f5/32.png) [@hungry-fish](https://www.ruby-forum.com/u/hungry-fish)\
**Post date:** [October 22, 2013, 1:28am UTC](https://www.ruby-forum.com/t/repeatability-of-delivery-ratios-using-benchmark-tx-rx/236984/3 "2013-10-22T01:28:15Z")

</div>

On Wed, Oct 16, 2013 at 10:29 PM, Aditya D.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> > in the packet delivery ratios, even though all runs of the experiment use
> > 
> > 1. Change to a different parameter set and repeat steps 1 and 2. Across  
> > Aditya

Update:

In experiment 1, I began to notice large variations in packet delivery  
ratios across different runs of step 3. If I modified benchmark\_rx to  
just  
sleep for a few seconds between tb.start() and tb.wait(), these large  
variations disappeared. It seems like once the EOF is reached, it simply  
kills all threads that run inside the flow graph.

However, even with the sleep, there are small variations (~1-2 packets)  
in  
an experiment with a total of 1000 packets being generated. Could anyone  
please give me a little hint on why this might be the case?

Thanks.

Aditya
