Change in osmo-ttcn3-hacks[master]: bts: Add TC_sacch_chan_act_ho_async + TC_sacch_chan_act_ho_sync

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

Harald Welte gerrit-no-reply at lists.osmocom.org
Mon May 20 19:40:51 UTC 2019


Harald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/14094 )

Change subject: bts: Add TC_sacch_chan_act_ho_async + TC_sacch_chan_act_ho_sync
......................................................................

bts: Add TC_sacch_chan_act_ho_async + TC_sacch_chan_act_ho_sync

Those two new tests test the subtle rules related to how the presence
of certain IEs in the RSL CHAN ACT influence when exactly DL SACCH
transmission should start during hand-over related channel activation.

Change-Id: Ia88f3ab160891cdbbb8fa6e765f137edd04c6e81
Related: OS#3570
Related: OS#4008
Related: OS#4009
---
M bts/BTS_Tests.ttcn
1 file changed, 152 insertions(+), 4 deletions(-)

Approvals:
  Jenkins Builder: Verified
  Harald Welte: Looks good to me, approved



diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 0ee3cd4..076476f 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -497,9 +497,9 @@
 	var RSL_Message rx := f_rsl_transceive_ret(tx, exp_rx, id, ignore_other);
 }
 
-function f_rsl_chan_act(RSL_IE_ChannelMode mode, boolean encr_enable := false, RSL_IE_List more_ies := {})
-runs on ConnHdlr {
-	var RSL_Message ch_act := valueof(ts_RSL_CHAN_ACT(g_chan_nr, mode));
+function f_rsl_chan_act(RSL_IE_ChannelMode mode, boolean encr_enable := false, RSL_IE_List more_ies := {},
+			RSL_IE_ActivationType act_type := t_RSL_IE_ActType_IA) runs on ConnHdlr {
+	var RSL_Message ch_act := valueof(ts_RSL_CHAN_ACT(g_chan_nr, mode, act_type));
 	if (encr_enable) {
 		/* append encryption related IEs, if requested */
 		var RSL_IE_EncryptionInfo encr_info;
@@ -1007,7 +1007,153 @@
 	Misc_Helpers.f_shutdown(__BFILE__, __LINE__);
 }
 
-/* TODO: Test for SACCH transmission rules in the context of special CHAN ACT (HO) */
+/* verify that SACCH DL transmission is started only if MS power IE present
+ * see section 4.1.3 of 3GPP TS 48.058 */
+private function f_TC_sacch_chan_act_ho_async(charstring id) runs on ConnHdlr {
+	var octetstring si5 := f_rnd_octstring(19);
+
+	f_l1_tune(L1CTL);
+	RSL.clear;
+
+	/* Step 1: Activate ASYNC HO channel without MS power IE */
+
+	/* Activate channel on BTS side */
+	f_rsl_chan_act(g_pars.chan_mode, act_type := t_RSL_IE_ActType_HO_ASYNC);
+	/* don't perform immediate assignment here, as we're testing non-IA case */
+	/* enable dedicated mode */
+	f_L1CTL_DM_EST_REQ(L1CTL, {false, mp_trx0_arfcn }, g_pars.chan_nr, 7);
+
+	/* Verify that no DL SACCH is being received */
+	f_sacch_missing(?);
+
+	f_rsl_chan_deact();
+	f_L1CTL_DM_REL_REQ(L1CTL, g_chan_nr);
+
+
+	/* Step 2: Activate ASYNC HO channel with MS power IE */
+
+	/* Activate channel on BTS side */
+	var RSL_IE_List addl_ies := {
+		valueof(t_RSL_IE(RSL_IE_MS_POWER, RSL_IE_Body:{ms_power := ts_RSL_IE_MS_Power(0)}))
+		};
+	f_rsl_chan_act(g_pars.chan_mode, more_ies := addl_ies, act_type := t_RSL_IE_ActType_HO_ASYNC);
+	/* don't perform immediate assignment here, as we're testing non-IA case */
+	/* enable dedicated mode */
+	f_L1CTL_DM_EST_REQ(L1CTL, {false, mp_trx0_arfcn }, g_pars.chan_nr, 7);
+
+	/* Verify that DL SACCH is being received */
+	f_sacch_present(si5);
+
+	f_rsl_chan_deact();
+	f_L1CTL_DM_REL_REQ(L1CTL, g_chan_nr);
+}
+testcase TC_sacch_chan_act_ho_async() runs on test_CT {
+	var ConnHdlr vc_conn;
+	var ConnHdlrPars pars;
+	f_init();
+
+	for (var integer i := 0; i < sizeof(g_AllChannels); i := i+1) {
+		pars := valueof(t_Pars(g_AllChannels[i], ts_RSL_ChanMode_SIGN));
+		log(testcasename(), ": Starting for ", g_AllChannels[i]);
+		vc_conn := f_start_handler(refers(f_TC_sacch_chan_act_ho_async), pars);
+		vc_conn.done;
+	}
+	/* TODO: do the above in parallel, rather than sequentially? */
+	Misc_Helpers.f_shutdown(__BFILE__, __LINE__);
+}
+
+/* verify that SACCH DL transmission is started only if TA + MS power IEs present,
+ * see section 4.1.4 of 3GPP TS 48.058 */
+private function f_TC_sacch_chan_act_ho_sync(charstring id) runs on ConnHdlr {
+	var octetstring si5 := f_rnd_octstring(19);
+	var RSL_IE_List addl_ies;
+
+	f_l1_tune(L1CTL);
+	RSL.clear;
+
+	/* Step 1: Activate SYNC HO channel without MS power IE */
+
+	/* Activate channel on BTS side */
+	f_rsl_chan_act(g_pars.chan_mode, act_type := t_RSL_IE_ActType_HO_SYNC);
+	/* don't perform immediate assignment here, as we're testing non-IA case */
+	/* enable dedicated mode */
+	f_L1CTL_DM_EST_REQ(L1CTL, {false, mp_trx0_arfcn }, g_pars.chan_nr, 7);
+
+	/* Verify that no DL SACCH is being received */
+	f_sacch_missing(?);
+
+	f_rsl_chan_deact();
+	f_L1CTL_DM_REL_REQ(L1CTL, g_chan_nr);
+
+
+	/* Step 2a: Activate SYNC HO channel with only MS power IE */
+
+	/* Activate channel on BTS side */
+	addl_ies := {
+		valueof(t_RSL_IE(RSL_IE_MS_POWER, RSL_IE_Body:{ms_power := ts_RSL_IE_MS_Power(0)}))
+		};
+	f_rsl_chan_act(g_pars.chan_mode, more_ies := addl_ies, act_type := t_RSL_IE_ActType_HO_SYNC);
+	/* don't perform immediate assignment here, as we're testing non-IA case */
+	/* enable dedicated mode */
+	f_L1CTL_DM_EST_REQ(L1CTL, {false, mp_trx0_arfcn }, g_pars.chan_nr, 7);
+
+	/* Verify that no DL SACCH is being received */
+	f_sacch_missing(?);
+
+	f_rsl_chan_deact();
+	f_L1CTL_DM_REL_REQ(L1CTL, g_chan_nr);
+
+
+	/* Step 2b: Activate SYNC HO channel with TA IE */
+
+	/* Activate channel on BTS side */
+	addl_ies := {
+		valueof(t_RSL_IE(RSL_IE_TIMING_ADVANCE, RSL_IE_Body:{timing_adv := 0}))
+		};
+	f_rsl_chan_act(g_pars.chan_mode, more_ies := addl_ies, act_type := t_RSL_IE_ActType_HO_SYNC);
+	/* don't perform immediate assignment here, as we're testing non-IA case */
+	/* enable dedicated mode */
+	f_L1CTL_DM_EST_REQ(L1CTL, {false, mp_trx0_arfcn }, g_pars.chan_nr, 7);
+
+	/* Verify that no DL SACCH is being received */
+	f_sacch_missing(?);
+
+	f_rsl_chan_deact();
+	f_L1CTL_DM_REL_REQ(L1CTL, g_chan_nr);
+
+
+	/* Step 3: Activate SYNC HO channel with MS power IE and TA IE */
+
+	/* Activate channel on BTS side */
+	addl_ies := {
+		valueof(t_RSL_IE(RSL_IE_TIMING_ADVANCE, RSL_IE_Body:{timing_adv := 0})),
+		valueof(t_RSL_IE(RSL_IE_MS_POWER, RSL_IE_Body:{ms_power := ts_RSL_IE_MS_Power(0)}))
+		};
+	f_rsl_chan_act(g_pars.chan_mode, more_ies := addl_ies, act_type := t_RSL_IE_ActType_HO_SYNC);
+	/* don't perform immediate assignment here, as we're testing non-IA case */
+	/* enable dedicated mode */
+	f_L1CTL_DM_EST_REQ(L1CTL, {false, mp_trx0_arfcn }, g_pars.chan_nr, 7);
+
+	/* Verify that DL SACCH is being received */
+	f_sacch_present(si5);
+
+	f_rsl_chan_deact();
+	f_L1CTL_DM_REL_REQ(L1CTL, g_chan_nr);
+}
+testcase TC_sacch_chan_act_ho_sync() runs on test_CT {
+	var ConnHdlr vc_conn;
+	var ConnHdlrPars pars;
+	f_init();
+
+	for (var integer i := 0; i < sizeof(g_AllChannels); i := i+1) {
+		pars := valueof(t_Pars(g_AllChannels[i], ts_RSL_ChanMode_SIGN));
+		log(testcasename(), ": Starting for ", g_AllChannels[i]);
+		vc_conn := f_start_handler(refers(f_TC_sacch_chan_act_ho_sync), pars);
+		vc_conn.done;
+	}
+	/* TODO: do the above in parallel, rather than sequentially? */
+	Misc_Helpers.f_shutdown(__BFILE__, __LINE__);
+}
 
 
 /***********************************************************************
@@ -4465,6 +4611,8 @@
 	execute( TC_sacch_multi() );
 	execute( TC_sacch_multi_chg() );
 	execute( TC_sacch_chan_act() );
+	execute( TC_sacch_chan_act_ho_async() );
+	execute( TC_sacch_chan_act_ho_sync() );
 	execute( TC_rach_content() );
 	execute( TC_rach_count() );
 	execute( TC_rach_max_ta() );

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

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ia88f3ab160891cdbbb8fa6e765f137edd04c6e81
Gerrit-Change-Number: 14094
Gerrit-PatchSet: 1
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190520/f7120e33/attachment.htm>


More information about the gerrit-log mailing list