Change in libosmocore[master]: tests/coding: add 11-bit Access Burst samples from a real phone

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/.

fixeria gerrit-no-reply at lists.osmocom.org
Tue Mar 31 17:56:51 UTC 2020


fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/17692 )


Change subject: tests/coding: add 11-bit Access Burst samples from a real phone
......................................................................

tests/coding: add 11-bit Access Burst samples from a real phone

This change adds several soft-bit (-127 .. 127) sequences containing
EGPRS Packet Channel Request message (11-bit, payload only) sent by
an EGPRS capable phone, and captured on the BTS/PCU side using a
tool from the TRX Toolkit - trx_sniff.py.

As can be seen from the test output, none of decoded RA11 values
looks like a valid EGPRS Packet Channel Request message (see
table 11.2.5a.2 of 3GPP TS 44.060). All test sequences contain
the same message with several random bits:

  < EGPRS Packet channel request message content > ::=
      < Signalling : 110011  < RandomBits : bit (5) > >;

since the phone was trying to perform Attach Request. It seems
the bit order of decoded messages is somehow wrong.

Change-Id: Id80e471d252b9416217b56f4c8c0a8f5f1289fee
Related: OS#1548
---
M tests/coding/coding_test.c
M tests/coding/coding_test.ok
2 files changed, 60 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/92/17692/1

diff --git a/tests/coding/coding_test.c b/tests/coding/coding_test.c
index 2ae95f8..17ddfaa 100644
--- a/tests/coding/coding_test.c
+++ b/tests/coding/coding_test.c
@@ -185,6 +185,22 @@
 	printd("\n");
 }
 
+static void test_rach_11bit_sample(uint8_t bsic, const sbit_t *payload)
+{
+	int n_errors, n_bits_total;
+	uint16_t ra11;
+	int rc;
+
+	/* Decode, correcting errors */
+	rc = gsm0503_rach_ext_decode_ber(&ra11, payload, bsic, &n_errors, &n_bits_total);
+	if (rc) {
+		printf("%s(): decoding failed (rc=%d)\n", __func__, rc);
+		return;
+	}
+
+	printf("Decoded RA11: 0x%03x\n", ra11);
+}
+
 static void test_sch(uint8_t *info)
 {
 	uint8_t result[4];
@@ -376,6 +392,39 @@
 	0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17 },
 };
 
+/* 11-bit Access Burst soft-bits (payload only) from an EGPRS capable phone (BSIC 63) */
+static const sbit_t test_rach_11bit[6][36] = {
+	{  103,  109, -108, -110,  107,  108, -106, -120, -121,
+	  -120, -105,  122, -104, -109,  108,  109, -109, -111,
+	   107,  111, -105, -119, -121, -104,  122, -120,  121,
+	   -99, -121, -120, -122, -106,  109,  109, -108, -111  },
+
+	{  103,  109, -109, -109,  106,  107, -106, -121, -121,
+	  -120, -106,  121, -120,  117, -122,  101,  109, -122,
+	   120, -120,  101,  118,  120,  102, -125,  101,  110,
+	  -120,  121, -101, -121, -118, -121, -106,  108,  121  },
+
+	{ -121, -122, -104,  123, -104, -108,  122, -104, -121,
+	  -121, -102,  124, -105, -110,  107,  109, -108, -109,
+	   121, -122,  101,  107, -121,  105,  108, -110, -107,
+	   124, -104, -109,  120, -122,  100,  122,  104, -123  },
+
+	{ -122, -123, -103,  123, -105, -109,  122, -105, -121,
+	  -120, -104,  122, -120,  121, -101, -122, -120, -120,
+	  -119, -105,  120, -106, -108,  123, -104, -113,  105,
+	   122,  101, -122,  119, -122,  117, -121,  119, -122  },
+
+	{  105,  110, -109, -109,  107,  108, -108, -120, -120,
+	  -121, -106,  121, -104, -107,  106,  108, -108, -108,
+	   108,  107, -105, -120, -122, -104,  122, -119,  121,
+	  -103, -122, -118, -120, -106,  108,  108, -110, -111  },
+
+	{  120, -103, -123, -104,  119, -121,  100,  123,  106,
+	  -109, -107,  121, -122,  118, -121,  103,  108, -122,
+	   120, -119,  121, -103, -121, -119, -121, -103,  124,
+	  -106, -108,  122, -103, -106,  121, -120,  119, -121  },
+};
+
 uint8_t test_speech_fr[33];
 uint8_t test_speech_efr[31];
 uint8_t test_speech_hr[15];
@@ -402,6 +451,10 @@
 		test_rach_ext(0x1a, i);
 	}
 
+	for (i = 0; i < ARRAY_SIZE(test_rach_11bit); i++)
+		test_rach_11bit_sample(0x3f, test_rach_11bit[i]);
+	printf("\n");
+
 	for (i = 0; i < len_l2; i++)
 		test_sch(test_l2[i]);
 
diff --git a/tests/coding/coding_test.ok b/tests/coding/coding_test.ok
index 2005f6e..496ce89 100644
--- a/tests/coding/coding_test.ok
+++ b/tests/coding/coding_test.ok
@@ -40,6 +40,13 @@
 Decoded: 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f 10 11 12 13 14 15 16 17 
 xcch_decode: n_errors=60 n_bits_total=456 ber=0.13
 
+Decoded RA11: 0x7cc
+Decoded RA11: 0x6cc
+Decoded RA11: 0x7cd
+Decoded RA11: 0x4cd
+Decoded RA11: 0x7cc
+Decoded RA11: 0x6ce
+
 Encoding: 03 03 01 00 
 U-Bits: 111001110011000011100111001100001101001111000000000011010000011010110111111100
 S-Bits: 81 81 81 7f 7f 81 81 81 7f 7f 81 81 7f 7f 7f 7f 81 81 81 7f 7f 81 81 81 7f 7f 81 81 7f 7f 7f 7f 81 81 7f 81 7f 7f 81 81 81 81 7f 7f 7f 7f 7f 7f 7f 7f 7f 7f 81 81 7f 81 7f 7f 7f 7f 7f 81 81 7f 81 7f 81 81 7f 81 81 81 81 81 81 81 7f 7f 

-- 
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/17692
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: Id80e471d252b9416217b56f4c8c0a8f5f1289fee
Gerrit-Change-Number: 17692
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <axilirator at gmail.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200331/08db6505/attachment.htm>


More information about the gerrit-log mailing list