Change in osmo-pcu[master]: Get rid of lots of code only used by tests

pespin gerrit-no-reply at lists.osmocom.org
Wed Jul 28 19:49:43 UTC 2021


pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-pcu/+/25093 )


Change subject: Get rid of lots of code only used by tests
......................................................................

Get rid of lots of code only used by tests

There are 2 methods "rcvd_dl_ack()" in osmo-pcu code. One is used by
osmo-pcu itself, and the other is only used in tests.
Changing the tests to use the same method as osmo-pcu allows removing
the second one, and with it, a lot of code and complexity out of
osmo-pcu.

Change-Id: I14d9312cb61534dc97fca83141b9c0cd933c9206
---
M src/decoding.cpp
M src/decoding.h
M src/encoding.cpp
M src/encoding.h
M src/tbf_dl.cpp
M src/tbf_dl.h
M tests/tbf/TbfTest.cpp
M tests/tbf/TbfTest.err
M tests/types/TypesTest.cpp
9 files changed, 120 insertions(+), 122 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-pcu refs/changes/93/25093/1

diff --git a/src/decoding.cpp b/src/decoding.cpp
index e40496d..0caa8bf 100644
--- a/src/decoding.cpp
+++ b/src/decoding.cpp
@@ -326,18 +326,6 @@
  * The index of the array is the bit position in the rbb
  * (show_rbb[63] relates to BSN ssn-1)
  */
-void Decoding::extract_rbb(const uint8_t *rbb, char *show_rbb)
-{
-	for (int i = 0; i < 64; i++) {
-		uint8_t bit;
-
-		bit = !!(rbb[i/8] & (1<<(7-i%8)));
-		show_rbb[i] = bit ? 'R' : 'I';
-	}
-
-	show_rbb[64] = '\0';
-}
-
 void Decoding::extract_rbb(const struct bitvec *rbb, char *show_rbb)
 {
 	unsigned int i;
diff --git a/src/decoding.h b/src/decoding.h
index 28af3c4..7270c3d 100644
--- a/src/decoding.h
+++ b/src/decoding.h
@@ -50,7 +50,6 @@
 		enum CodingScheme cs, const uint8_t *data, RlcData *chunks,
 		unsigned int chunks_size, uint32_t *tlli);
 
-	static void extract_rbb(const uint8_t *rbb, char *extracted_rbb);
 	static void extract_rbb(const struct bitvec *rbb, char *show_rbb);
 	static int rlc_parse_ul_data_header_egprs_type_3(
 		struct gprs_rlc_data_info *rlc,
diff --git a/src/encoding.cpp b/src/encoding.cpp
index d9f4f87..f945161 100644
--- a/src/encoding.cpp
+++ b/src/encoding.cpp
@@ -841,20 +841,12 @@
  * The index of the array show_rbb is the bit position inside the rbb
  * (show_rbb[63] relates to BSN ssn-1)
  */
-void Encoding::encode_rbb(const char *show_rbb, uint8_t *rbb)
+void Encoding::encode_rbb(const char *show_rbb, bitvec *bv)
 {
-	uint8_t rbb_byte = 0;
-
 	// RECEIVE_BLOCK_BITMAP
 	for (int i = 0; i < 64; i++) {
 		/* Set bit at the appropriate position (see 3GPP TS 44.060 9.1.8.1) */
-		if (show_rbb[i] == 'R')
-			rbb_byte |= 1<< (7-(i%8));
-
-		if ((i%8) == 7) {
-			rbb[i/8] = rbb_byte;
-			rbb_byte = 0;
-		}
+		bitvec_set_bit(bv, show_rbb[i] == 'R' ? ONE : ZERO);
 	}
 }
 
diff --git a/src/encoding.h b/src/encoding.h
index f942fd8..298a937 100644
--- a/src/encoding.h
+++ b/src/encoding.h
@@ -63,7 +63,7 @@
 			uint8_t t3142
 		);
 
-	static void encode_rbb(const char *show_rbb, uint8_t *rbb);
+	static void encode_rbb(const char *show_rbb, bitvec *rbb);
 
 	static void write_packet_uplink_ack(
 			bitvec * dest, struct gprs_rlcmac_ul_tbf *tbf, bool is_final,
diff --git a/src/tbf_dl.cpp b/src/tbf_dl.cpp
index ea7f18e..40b52e5 100644
--- a/src/tbf_dl.cpp
+++ b/src/tbf_dl.cpp
@@ -1158,68 +1158,6 @@
 	return 0;
 }
 
-int gprs_rlcmac_dl_tbf::update_window(const uint8_t ssn, const uint8_t *rbb)
-{
-	int16_t dist; /* must be signed */
-	uint16_t lost = 0, received = 0;
-	char show_rbb[65];
-	char show_v_b[RLC_MAX_SNS + 1];
-	int error_rate;
-	struct ana_result ana_res;
-
-	Decoding::extract_rbb(rbb, show_rbb);
-	/* show received array in debug (bit 64..1) */
-	LOGPTBFDL(this, LOGL_DEBUG,
-		  "ack:  (BSN=%d)\"%s\"(BSN=%d)  R=ACK I=NACK\n",
-		  m_window.mod_sns(ssn - 64), show_rbb, m_window.mod_sns(ssn - 1));
-
-	/* apply received array to receive state (SSN-64..SSN-1) */
-	/* calculate distance of ssn from V(S) */
-	dist = m_window.mod_sns(m_window.v_s() - ssn);
-	/* check if distance is less than distance V(A)..V(S) */
-	if (dist >= m_window.distance()) {
-		/* this might happpen, if the downlink assignment
-		 * was not received by ms and the ack refers
-		 * to previous TBF
-		 * FIXME: we should implement polling for
-		 * control ack!*/
-		LOGPTBFDL(this, LOGL_NOTICE, "ack range is out of V(A)..V(S) range - Free TBF!\n");
-		return 1; /* indicate to free TBF */
-	}
-
-	error_rate = analyse_errors(show_rbb, ssn, &ana_res);
-
-	if (the_pcu->vty.cs_adj_enabled && ms())
-		ms_update_error_rate(ms(), this, error_rate);
-
-	m_window.update(bts, show_rbb, ssn,
-			&lost, &received);
-	rate_ctr_add(rate_ctr_group_get_ctr(m_ctrs, TBF_CTR_RLC_NACKED), lost);
-
-	/* report lost and received packets */
-	gprs_rlcmac_received_lost(this, received, lost);
-
-	/* Used to measure the leak rate */
-	gprs_bssgp_update_bytes_received(ana_res.received_bytes,
-		ana_res.received_packets + ana_res.lost_packets);
-
-	/* raise V(A), if possible */
-	m_window.raise(m_window.move_window());
-
-	/* show receive state array in debug (V(A)..V(S)-1) */
-	m_window.show_state(show_v_b);
-	LOGPTBFDL(this, LOGL_DEBUG,
-		  "V(B): (V(A)=%d)\"%s\"(V(S)-1=%d)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid\n",
-		  m_window.v_a(), show_v_b, m_window.v_s_mod(-1));
-
-	if (state_is(TBF_ST_FINISHED) && m_window.window_empty()) {
-		LOGPTBFDL(this, LOGL_NOTICE,
-			  "Received acknowledge of all blocks, but without final ack inidcation (don't worry)\n");
-	}
-	return 0;
-}
-
-
 int gprs_rlcmac_dl_tbf::rcvd_dl_final_ack()
 {
 	osmo_fsm_inst_dispatch(this->state_fsm.fi, TBF_EV_FINAL_ACK_RECVD, NULL);
@@ -1275,17 +1213,6 @@
 	return rc;
 }
 
-int gprs_rlcmac_dl_tbf::rcvd_dl_ack(bool final_ack, uint8_t ssn, uint8_t *rbb)
-{
-	LOGPTBFDL(this, LOGL_DEBUG, "downlink acknowledge\n");
-
-	if (!final_ack)
-		return update_window(ssn, rbb);
-
-	LOGPTBFDL(this, LOGL_DEBUG, "Final ACK received.\n");
-	return rcvd_dl_final_ack();
-}
-
 bool gprs_rlcmac_dl_tbf::dl_window_stalled() const
 {
 	return m_window.window_stalled();
diff --git a/src/tbf_dl.h b/src/tbf_dl.h
index b8fecde..67c05ad 100644
--- a/src/tbf_dl.h
+++ b/src/tbf_dl.h
@@ -48,7 +48,6 @@
 	int append_data(uint16_t pdu_delay_csec,
 			const uint8_t *data, uint16_t len);
 
-	int rcvd_dl_ack(bool final, uint8_t ssn, uint8_t *rbb);
 	int rcvd_dl_ack(bool final_ack, unsigned first_bsn, struct bitvec *rbb);
 	struct msgb *create_dl_acked_block(uint32_t fn, uint8_t ts, enum mcs_kind req_mcs_kind = EGPRS);
 	void trigger_ass(struct gprs_rlcmac_tbf *old_tbf);
@@ -107,7 +106,6 @@
 	int create_new_bsn(const uint32_t fn, enum CodingScheme cs);
 	struct msgb *create_dl_acked_block(const uint32_t fn, const uint8_t ts,
 					int index, int index2 = -1);
-	int update_window(const uint8_t ssn, const uint8_t *rbb);
 	int update_window(unsigned first_bsn, const struct bitvec *rbb);
 	int rcvd_dl_final_ack();
 	bool dl_window_stalled() const;
diff --git a/tests/tbf/TbfTest.cpp b/tests/tbf/TbfTest.cpp
index 9ba1753..c6ea701 100644
--- a/tests/tbf/TbfTest.cpp
+++ b/tests/tbf/TbfTest.cpp
@@ -259,6 +259,28 @@
 	TEST_MODE_REVERSE_FREE
 };
 
+/* Receive an ACK */
+#define RCV_ACK(fin, tbf, rbb) do { \
+		gprs_rlc_dl_window *w = static_cast<gprs_rlc_dl_window *>(tbf->window());	\
+		uint8_t bits_data[RLC_GPRS_WS/8]; \
+		bitvec bits; \
+		Ack_Nack_Description_t ack_nack; \
+		int bsn_begin, bsn_end; \
+		uint8_t ssn = w->v_s(); \
+		bits.data = bits_data; \
+		bits.data_len = sizeof(bits_data); \
+		bits.cur_bit = 0; \
+		ack_nack.FINAL_ACK_INDICATION = fin; \
+		ack_nack.STARTING_SEQUENCE_NUMBER = ssn; \
+		memcpy(ack_nack.RECEIVED_BLOCK_BITMAP, rbb, RLC_GPRS_WS/8); \
+		Decoding::decode_gprs_acknack_bits( \
+			&ack_nack, &bits, \
+			&bsn_begin, &bsn_end, w); \
+		tbf->rcvd_dl_ack(fin, bsn_begin, &bits); \
+		if (!fin) \
+			OSMO_ASSERT(w->window_empty());	\
+	} while(0)
+
 static void test_tbf_final_ack(enum test_tbf_final_ack_mode test_mode)
 {
 	the_pcu = prepare_pcu();
@@ -305,7 +327,7 @@
 	/* Queue a final ACK */
 	memset(rbb, 0, sizeof(rbb));
 	/* Receive a final ACK */
-	dl_tbf->rcvd_dl_ack(true, 1, rbb);
+	RCV_ACK(true, dl_tbf, rbb);
 
 	/* Clean up and ensure tbfs are in the correct state */
 	OSMO_ASSERT(dl_tbf->state_is(TBF_ST_WAIT_RELEASE));
@@ -335,14 +357,6 @@
 	fprintf(stderr, "=== end %s ===\n", __func__);
 }
 
-/* Receive an ACK */
-#define RCV_ACK(fin, tbf, rbb) do { \
-		gprs_rlc_dl_window *w = static_cast<gprs_rlc_dl_window *>(tbf->window());	\
-		tbf->rcvd_dl_ack(fin, w->v_s(), rbb);	\
-		if (!fin)						\
-			OSMO_ASSERT(w->window_empty());	\
-	} while(0)
-
 static void test_tbf_delayed_release()
 {
 	the_pcu = prepare_pcu();
diff --git a/tests/tbf/TbfTest.err b/tests/tbf/TbfTest.err
index ce1aa3c..98c9d49 100644
--- a/tests/tbf/TbfTest.err
+++ b/tests/tbf/TbfTest.err
@@ -109,6 +109,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) Copying data unit 0 (BSN 1)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) msg block (BSN 1, CS-1): 07 00 03 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f 20 21 22 23 24 25 26 27 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack:  (BSN=0)"RR"(BSN=1)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) DL analysis, range=0:2, lost=0, recv=2, skipped=0, bsn=0, info='RR..............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) V(B): (V(A)=2)""(V(S)-1=1)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -221,6 +224,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) Copying data unit 0 (BSN 1)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) msg block (BSN 1, CS-1): 07 00 03 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f 20 21 22 23 24 25 26 27 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack:  (BSN=0)"RR"(BSN=1)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) DL analysis, range=0:2, lost=0, recv=2, skipped=0, bsn=0, info='RR..............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) V(B): (V(A)=2)""(V(S)-1=1)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -494,12 +500,13 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) Scheduled Ack/Nack polling on FN=104, TS=4
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) msg block (BSN 20, CS-1): 0f 00 28 09 c6 c7 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) downlink acknowledge
-TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack:  (BSN=85)"RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRR"(BSN=20)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack:  (BSN=0)"RRRRRRRRRRRRRRRRRRRRR"(BSN=20)  R=ACK I=NACK
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) DL analysis, range=0:21, lost=0, recv=21, skipped=0, bsn=0, info='RRRRRRRRRRRRRRRRRRRRR...........................................'
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) V(B): (V(A)=21)""(V(S)-1=20)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) downlink acknowledge
-TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack:  (BSN=85)"RRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRR"(BSN=20)  R=ACK I=NACK
-TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack range is out of V(A)..V(S) range - Free TBF!
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) ack:  (BSN=21)""(BSN=20)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) DL analysis, range=21:21, lost=0, recv=0, skipped=0, bsn=0, info='................................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) V(B): (V(A)=21)""(V(S)-1=20)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 PDCH(bts=0,trx=0,ts=4) FN=203 Scheduling data message at RTS for DL TFI=0 prio=4 mcs_mode_restrict=EGPRS
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) downlink (V(A)==21 .. V(S)==21) mcs_mode_restrict=EGPRS
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW) Sending new dummy block at BSN 21, CS=CS-1
@@ -519,6 +526,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) Scheduled Ack/Nack polling on FN=216, TS=4
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) msg block (BSN 21, CS-1): 0f 01 2a 4d 43 c0 01 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 2b 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) ack:  (BSN=21)"R"(BSN=21)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) DL analysis, range=21:22, lost=0, recv=1, skipped=0, bsn=21, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) V(B): (V(A)=22)""(V(S)-1=21)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FINISHED) Final ACK received.
 TBF(DL-TFI_0){FINISHED}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FINISHED}: state_chg to WAIT_RELEASE
@@ -4278,6 +4288,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) poll timeout for FN=104, TS=4 (curr FN 112)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 2 => 3 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRRRRRRRRRRRRRRRRRR"(BSN=24)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:25, lost=0, recv=25, skipped=0, bsn=0, info='RRRRRRRRRRRRRRRRRRRRRRRRR.......................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=25)""(V(S)-1=24)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -4534,6 +4547,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRRRRRRRRRRRRR"(BSN=19)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:20, lost=0, recv=20, skipped=0, bsn=0, info='RRRRRRRRRRRRRRRRRRRR............................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=20)""(V(S)-1=19)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -4750,6 +4766,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRRRRRRRR"(BSN=14)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:15, lost=0, recv=15, skipped=0, bsn=0, info='RRRRRRRRRRRRRRR.................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=15)""(V(S)-1=14)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -4950,6 +4969,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRRRRRR"(BSN=12)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:13, lost=0, recv=13, skipped=0, bsn=0, info='RRRRRRRRRRRRR...................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=13)""(V(S)-1=12)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5134,6 +5156,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRRRR"(BSN=10)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:11, lost=0, recv=11, skipped=0, bsn=0, info='RRRRRRRRRRR.....................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=11)""(V(S)-1=10)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5294,6 +5319,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRR"(BSN=7)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:8, lost=0, recv=8, skipped=0, bsn=0, info='RRRRRRRR........................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=8)""(V(S)-1=7)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5463,6 +5491,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRRRR"(BSN=10)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:11, lost=0, recv=10, skipped=1, bsn=0, info='xRRRRRRRRRR.....................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=11)""(V(S)-1=10)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5623,6 +5654,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRRR"(BSN=8)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:9, lost=0, recv=9, skipped=0, bsn=0, info='RRRRRRRRR.......................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=9)""(V(S)-1=8)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5772,6 +5806,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 1 => 2 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RRRRRRRR"(BSN=7)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:8, lost=0, recv=8, skipped=0, bsn=0, info='RRRRRRRR........................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=8)""(V(S)-1=7)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5844,6 +5881,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-6): 07 00 00 12 40 80 c0 00 41 81 c1 01 42 82 c2 02 43 83 c3 03 44 84 c4 04 45 85 c5 05 46 86 c6 06 47 87 c7 07 48 88 c8 08 49 89 c9 09 4a 8a ca 0a 4b 8b cb 0b 4c 8c cc 0c 4d 8d cd 0d 4e 8e ce 0e 4f 8f cf 0f 50 90 d0 10 51 91 d1 11 52 12 
 Detected FN jump! 2654167 -> 58
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5913,6 +5953,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Copying data unit 0 (BSN 0)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-1): 07 00 00 98 00 02 04 06 08 0a 0c 0e 10 12 14 16 18 1a 1c 1e 20 22 24 26 28 2a 00 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -5982,6 +6025,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Copying data unit 0 (BSN 0)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-2): 07 00 00 94 00 02 04 06 08 0a 0c 0e 10 12 14 16 18 1a 1c 1e 20 22 24 26 28 2a 2c 2e 30 32 34 36 00 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6074,6 +6120,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 0 => 1 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RR"(BSN=1)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:2, lost=0, recv=2, skipped=0, bsn=0, info='RR..............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=2)""(V(S)-1=1)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6165,6 +6214,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 0 => 1 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RR"(BSN=1)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:2, lost=0, recv=2, skipped=0, bsn=0, info='RR..............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=2)""(V(S)-1=1)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6256,6 +6308,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 0 => 1 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RR"(BSN=1)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:2, lost=0, recv=2, skipped=0, bsn=0, info='RR..............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=2)""(V(S)-1=1)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6347,6 +6402,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Timeout for polling PACKET DOWNLINK ACK: |Assignment was on PACCH|No downlink ACK received yet|
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) N3105 0 => 1 (< MAX 8)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"RR"(BSN=1)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:2, lost=0, recv=2, skipped=0, bsn=0, info='RR..............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=2)""(V(S)-1=1)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6425,6 +6483,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Copying data unit 0 (BSN 0)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-3): 07 00 00 e6 4a 4c 4e 50 52 54 56 58 5a 5c 5e 60 62 64 66 68 6a 6c 6e 70 72 74 76 78 7a 7c 7e 80 82 84 86 88 8a 8c 8e 90 92 00 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6501,6 +6562,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Copying data unit 0 (BSN 0)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-2): 07 00 00 f2 38 3a 3c 3e 40 42 44 46 48 4a 4c 4e 50 52 54 56 58 5a 5c 5e 60 62 64 66 68 6a 6c 6e 00 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6577,6 +6641,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Copying data unit 0 (BSN 0)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-1): 07 00 00 f6 2c 2e 30 32 34 36 38 3a 3c 3e 40 42 44 46 48 4a 4c 4e 50 52 54 56 00 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
@@ -6660,6 +6727,9 @@
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Copying data unit 0 (BSN 0)
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) msg block (BSN 0, MCS-6): 07 00 00 10 40 80 c0 00 41 81 c1 01 42 82 c2 02 43 83 c3 03 44 84 c4 04 45 85 c5 05 46 86 c6 06 47 87 c7 07 48 88 c8 08 49 89 c9 09 4a 8a ca 0a 4b 8b cb 0b 4c 8c cc 0c 4d 8d cd 0d 4e 8e ce 0e 4f 8f cf 0f 50 90 d0 10 51 91 d1 11 52 12 
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) downlink acknowledge
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) ack:  (BSN=0)"R"(BSN=0)  R=ACK I=NACK
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) DL analysis, range=0:1, lost=0, recv=1, skipped=0, bsn=0, info='R...............................................................'
+TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) V(B): (V(A)=1)""(V(S)-1=0)  A=Acked N=Nacked U=Unacked X=Resend-Unacked I=Invalid
 TBF(TFI=0 TLLI=0xffeeddcc DIR=DL STATE=FLOW EGPRS) Final ACK received.
 TBF(DL-TFI_0){FLOW}: Received Event FINAL_ACK_RECVD
 TBF(DL-TFI_0){FLOW}: state_chg to WAIT_RELEASE
diff --git a/tests/types/TypesTest.cpp b/tests/types/TypesTest.cpp
index 681ea4e..a975761 100644
--- a/tests/types/TypesTest.cpp
+++ b/tests/types/TypesTest.cpp
@@ -205,8 +205,12 @@
 		int count;
 		const char *rbb;
 		char win_rbb[65];
-		uint8_t bin_rbb[8];
+		uint8_t bin_rbb[RLC_GPRS_WS/8];
+		bitvec bits;
 		win_rbb[64] = '\0';
+		bits.data = bin_rbb;
+		bits.data_len = sizeof(bin_rbb);
+		bits.cur_bit = 0;
 
 		ul_win.m_v_n.reset();
 
@@ -220,9 +224,11 @@
 		OSMO_ASSERT(ul_win.ssn() == 0);
 		ul_win.update_rbb(win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
-		Encoding::encode_rbb(win_rbb, bin_rbb);
+		bits.cur_bit = 0;
+		Encoding::encode_rbb(win_rbb, &bits);
 		printf("rbb: %s\n", osmo_hexdump(bin_rbb, sizeof(bin_rbb)));
-		Decoding::extract_rbb(bin_rbb, win_rbb);
+		Decoding::extract_rbb(&bits, win_rbb);
+		//printf("win_rbb: %s\n", win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
 
 		/* simulate to have received 0, 1 and 5 */
@@ -238,9 +244,10 @@
 		OSMO_ASSERT(ul_win.ssn() == 1);
 		ul_win.update_rbb(win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
-		Encoding::encode_rbb(win_rbb, bin_rbb);
+		bits.cur_bit = 0;
+		Encoding::encode_rbb(win_rbb, &bits);
 		printf("rbb: %s\n", osmo_hexdump(bin_rbb, sizeof(bin_rbb)));
-		Decoding::extract_rbb(bin_rbb, win_rbb);
+		Decoding::extract_rbb(&bits, win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
 
 		OSMO_ASSERT(ul_win.is_in_window(1));
@@ -255,9 +262,10 @@
 		OSMO_ASSERT(ul_win.ssn() == 2);
 		ul_win.update_rbb(win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
-		Encoding::encode_rbb(win_rbb, bin_rbb);
+		bits.cur_bit = 0;
+		Encoding::encode_rbb(win_rbb, &bits);
 		printf("rbb: %s\n", osmo_hexdump(bin_rbb, sizeof(bin_rbb)));
-		Decoding::extract_rbb(bin_rbb, win_rbb);
+		Decoding::extract_rbb(&bits, win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
 
 		OSMO_ASSERT(ul_win.is_in_window(5));
@@ -272,9 +280,10 @@
 		OSMO_ASSERT(ul_win.ssn() == 6);
 		ul_win.update_rbb(win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
-		Encoding::encode_rbb(win_rbb, bin_rbb);
+		bits.cur_bit = 0;
+		Encoding::encode_rbb(win_rbb, &bits);
 		printf("rbb: %s\n", osmo_hexdump(bin_rbb, sizeof(bin_rbb)));
-		Decoding::extract_rbb(bin_rbb, win_rbb);
+		Decoding::extract_rbb(&bits, win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
 
 		OSMO_ASSERT(ul_win.is_in_window(65));
@@ -291,9 +300,10 @@
 		OSMO_ASSERT(ul_win.ssn() == 66);
 		ul_win.update_rbb(win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
-		Encoding::encode_rbb(win_rbb, bin_rbb);
+		bits.cur_bit = 0;
+		Encoding::encode_rbb(win_rbb, &bits);
 		printf("rbb: %s\n", osmo_hexdump(bin_rbb, sizeof(bin_rbb)));
-		Decoding::extract_rbb(bin_rbb, win_rbb);
+		Decoding::extract_rbb(&bits, win_rbb);
 		OSMO_ASSERT_STR_EQ(win_rbb, rbb);
 
 		OSMO_ASSERT(ul_win.is_in_window(2));

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

Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: I14d9312cb61534dc97fca83141b9c0cd933c9206
Gerrit-Change-Number: 25093
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210728/d9a93be8/attachment.htm>


More information about the gerrit-log mailing list