fixeria has uploaded this change for review. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/28880 )


Change subject: BTS_Tests: separate f_send_meas_rep() from 
f_transceive_meas_rep()
......................................................................

BTS_Tests: separate f_send_meas_rep() from f_transceive_meas_rep()

The key difference is that f_send_meas_rep() simply sends an RR
Measurement Report and does not wait until it's received on the RSL.

Change-Id: Ia5d0315e053702df5fa8dad8c6c66c11c9f3edcb
---
M bts/BTS_Tests.ttcn
1 file changed, 22 insertions(+), 6 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks 
refs/changes/80/28880/1

diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index 223e55b..5cf1900 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -778,12 +778,31 @@
        var RSL_Message rx := f_rsl_transceive_ret(tx, exp_rx, id, 
ignore_other);
 }

+/* Send the given measurement results to the IUT over the Um interface */
+friend function f_send_meas_rep(template (value) MeasurementResults meas_res)
+runs on ConnHdlr {
+       var template (value) SacchL1Header l1h;
+       var octetstring l2;
+
+       /* RR Measurement Report to be sent */
+       var GsmRrL3Message meas_rep := {
+               header := valueof(t_RrL3Header(MEASUREMENT_REPORT)),
+               payload := { meas_rep := { meas_res := valueof(meas_res) } }
+       };
+
+       /* TITAN has weird (and often unusable) padding model, so we pad here 
manaully */
+       l2 := f_pad_oct(enc_LapdmFrameAB(valueof(ts_LAPDm_AB(0, meas_rep))), 
21, '00'O);
+       l1h := ts_SacchL1Header(g_pars.l1_pars.ms_power_level, 
g_pars.l1_pars.ms_actual_ta);
+
+       /* Send RR Measurement Report over the Um interface */
+       L1CTL.send(ts_L1CTL_DATA_REQ_SACCH(g_chan_nr, ts_RslLinkID_SACCH(0), 
l1h, l2));
+}
+
 /* Send the given measurement results to the IUT over the Um interface,
  * wait for the IUT to receive then and forward over the A-bis/RSL interface. 
*/
 friend function f_transceive_meas_rep(template (value) MeasurementResults 
meas_res)
 runs on ConnHdlr {
-       var template (value) SacchL1Header l1h;
-       var octetstring l2, l3;
+       var octetstring l3;
        timer T;

        /* RR Measurement Report to be sent */
@@ -794,11 +813,8 @@

        /* TITAN has weird (and often unusable) padding model, so we pad here 
manaully */
        l3 := f_pad_oct(enc_GsmRrL3Message(meas_rep), 18, '00'O);
-       l2 := f_pad_oct(enc_LapdmFrameAB(valueof(ts_LAPDm_AB(0, meas_rep))), 
21, '00'O);
-       l1h := ts_SacchL1Header(g_pars.l1_pars.ms_power_level, 
g_pars.l1_pars.ms_actual_ta);

-       /* Send RR Measurement Report over the Um interface */
-       L1CTL.send(ts_L1CTL_DATA_REQ_SACCH(g_chan_nr, ts_RslLinkID_SACCH(0), 
l1h, l2));
+       f_send_meas_rep(meas_res);

        /* Expect MEASurement RESult on the A-bis/RSL interface */
        T.start(2.0);

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

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ia5d0315e053702df5fa8dad8c6c66c11c9f3edcb
Gerrit-Change-Number: 28880
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <[email protected]>
Gerrit-MessageType: newchange

Reply via email to