summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2020-06-23 19:00:00 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2020-06-25 12:52:48 +0200
commit45fe5e0e1fc860654b47d4b9234a2f53101a75d0 (patch)
tree0d117c38f88366eb4578f10a4dd907d3403a18c5
parentb6985f906f6a5afcb3efee08c345ebee6499ff56 (diff)
bts: Introduce TC_tx_power_ramp_adm_state_change
-rw-r--r--bts/BTS_Tests.ttcn55
1 files changed, 55 insertions, 0 deletions
diff --git a/bts/BTS_Tests.ttcn b/bts/BTS_Tests.ttcn
index a60a50f..132e13e 100644
--- a/bts/BTS_Tests.ttcn
+++ b/bts/BTS_Tests.ttcn
@@ -2214,6 +2214,60 @@ testcase TC_tx_power_start_ramp_down_bcch() runs on test_CT {
Misc_Helpers.f_shutdown(__BFILE__, __LINE__);
}
+/* Verify Tx power:
+ * + ramping down during ADM state UNLOCKED->LOCKED
+ * + ramping up during ADM state LOCKED->UNLOCKED
+ */
+function f_TC_tx_power_ramp_adm_state_change(charstring id) runs on ConnHdlr {
+ var L1ctlDlMessage l1_dl;
+ var integer last_rx_lvl;
+
+ f_connhdlr_init_vty_bsc();
+
+ f_l1_tune(L1CTL);
+ RSL.clear;
+
+ /* Wait until BTS is started and at full power */
+ var integer max_rx_lvl := f_wait_ramp_up();
+ log("Reached nominal level ", max_rx_lvl, ", changing ADM state to LOCKED");
+
+ log("ADM STATE UNLOCKED->LOCKED");
+ f_vty_enter_cfg_trx(BSCVTY);
+ f_vty_transceive(BSCVTY, "rf_locked 1");
+ last_rx_lvl := max_rx_lvl;
+ f_verify_ramp_down(max_rx_lvl);
+
+ /* Let some time after we received 0dBm, then check we don't receive BCCH
+ * anymore because scheduler has stopped after ramping down */
+ f_sleep(2.0);
+ L1CTL.clear;
+ timer Tlocked := 2.0;
+ Tlocked.start;
+ alt {
+ [] L1CTL.receive(tr_L1CTL_DATA_IND(t_RslChanNr_BCCH(0), ?)) -> value l1_dl {
+ Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail,
+ log2str("Received data_ind during rf_locked: ", l1_dl));
+ }
+ [] L1CTL.receive { repeat; }
+ [] Tlocked.timeout { setverdict(pass, "Didn't receive data_ind while in rf_locked state."); }
+ }
+
+ log("ADM STATE LOCKED->UNLOCKED");
+ f_vty_transceive(BSCVTY, "rf_locked 0");
+ f_verify_ramp_up();
+ setverdict(pass);
+}
+testcase TC_tx_power_ramp_adm_state_change() runs on test_CT {
+ var ConnHdlr vc_conn;
+ var ConnHdlrPars pars;
+ f_init();
+ pars := valueof(t_Pars(t_RslChanNr_Bm(0), ts_RSL_ChanMode_SIGN));
+ vc_conn := f_start_handler(refers(f_TC_tx_power_ramp_adm_state_change), pars,
+ pcu_comp := false, trxc_comp := true);
+ vc_conn.done;
+ Misc_Helpers.f_shutdown(__BFILE__, __LINE__);
+}
+
function f_check_meas_bs_power_level(integer level) runs on ConnHdlr {
timer T := 8.0;
T.start;
@@ -6633,6 +6687,7 @@ control {
execute( TC_meas_res_sign_tchh_toa256() );
execute( TC_tx_power_start_ramp_up_bcch() );
execute( TC_tx_power_start_ramp_down_bcch() );
+ execute( TC_tx_power_ramp_adm_state_change() );
execute( TC_rsl_bs_pwr_static_ass() );
execute( TC_rsl_bs_pwr_static_power_control() );
execute( TC_rsl_ms_pwr_ctrl() );