[MERGED] osmo-trx[master]: sigProcLib: Fix number of tail bits in random Normal Bursts ...

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Tom Tsou gerrit-no-reply at lists.osmocom.org
Tue May 30 19:14:25 UTC 2017


Tom Tsou has submitted this change and it was merged.

Change subject: sigProcLib: Fix number of tail bits in random Normal Bursts and zero Stealing Bits.
......................................................................


sigProcLib: Fix number of tail bits in random Normal Bursts and zero Stealing Bits.

This bug only affects generation of normal bursts filled with random bits which
are used in test mode. It doesn't affect operation of osmo-trx during normal
operation. That's why it has stayed unnoticed for so long.

Each Normal Burst has 3 tail bits, not 4.
Also it's better to set stealing bits to 0 for maximum compatibility. We may want to
introduce a selector for each bit whether to set it to 0, to 1 or to a random number.

Change-Id: I0377029556c8b681b3ba3b635bf19572b34546ea
---
M Transceiver52M/sigProcLib.cpp
1 file changed, 9 insertions(+), 3 deletions(-)

Approvals:
  Tom Tsou: Looks good to me, approved
  Harald Welte: Looks good to me, but someone else must approve
  Jenkins Builder: Verified



diff --git a/Transceiver52M/sigProcLib.cpp b/Transceiver52M/sigProcLib.cpp
index c51d094..9a8c824 100644
--- a/Transceiver52M/sigProcLib.cpp
+++ b/Transceiver52M/sigProcLib.cpp
@@ -927,19 +927,25 @@
   signalVector *burst;
 
   /* Tail bits */
-  for (; i < 4; i++)
+  for (; i < 3; i++)
     (*bits)[i] = 0;
 
   /* Random bits */
-  for (; i < 61; i++)
+  for (; i < 60; i++)
     (*bits)[i] = rand() % 2;
+
+  /* Stealing bit */
+  (*bits)[i++] = 0;
 
   /* Training sequence */
   for (int n = 0; i < 87; i++, n++)
     (*bits)[i] = gTrainingSequence[tsc][n];
 
+  /* Stealing bit */
+  (*bits)[i++] = 0;
+
   /* Random bits */
-  for (; i < 144; i++)
+  for (; i < 145; i++)
     (*bits)[i] = rand() % 2;
 
   /* Tail bits */

-- 
To view, visit https://gerrit.osmocom.org/2762
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I0377029556c8b681b3ba3b635bf19572b34546ea
Gerrit-PatchSet: 2
Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-Owner: Alexander Chemeris <Alexander.Chemeris at gmail.com>
Gerrit-Reviewer: Alexander Chemeris <Alexander.Chemeris at gmail.com>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Tom Tsou <tom at tsou.cc>



More information about the gerrit-log mailing list