From 8367411772647ed7d10b57dee8acd706934740a0 Mon Sep 17 00:00:00 2001 From: Pau Espin Pedrol Date: Mon, 13 Sep 2021 17:35:31 +0200 Subject: [PATCH] Power Control Loop: Set P_CON_INTERVAL to 1 by default TS 45.008 section 4.7.1: """ Upon receipt of a command from an SACCH to change its power level on the corresponding uplink channel, the MS shall change to the new level at a rate of one nominal 2 dB power control step every 60 ms (13 TDMA frames), i.e. a range change of 15 steps should take about 900 ms. The change shall commence at the first TDMA frame belonging to the next reporting period (as specified in subclause 8.4). The MS shall change the power one nominal 2 dB step at a time, at a rate of one step every 60 ms following the initial change, irrespective of whether actual transmission takes place or not. """ Since the reported MS_PWR in L1 SACCH Header is, according to specs, the one used for the last block of the previous SACCH period, it becomes clear the first SACCH block after a requested MS Power Level change by the network may contain mismatches between the announced MS_PWR by the MS and the measured Rxlev/RxQual. Hence, let's better use a P_CON_INTERVAL of 1 which retriggers the MS Power Control Loop every second SACCH block. Related: SYS#5371 Change-Id: Iade5b597e0e56b07c6d78995fcec7c641e4e643f --- doc/manuals/chapters/power_control.adoc | 44 ++++++++++++++++++++----- src/osmo-bsc/bts_vty.c | 5 ++- src/osmo-bsc/gsm_data.c | 2 ++ tests/power_ctrl.vty | 10 ++++-- 4 files changed, 47 insertions(+), 14 deletions(-) diff --git a/doc/manuals/chapters/power_control.adoc b/doc/manuals/chapters/power_control.adoc index 95adbb147..54cbd5ba2 100644 --- a/doc/manuals/chapters/power_control.adoc +++ b/doc/manuals/chapters/power_control.adoc @@ -150,20 +150,46 @@ Having requested a transmit power level, the MS/BS power control loop may option be suspended for a certain number of SACCH multiframes defined by VTY parameter `ctrl-interval`. Given that SACCH is relatively slow and transmission of a data block takes 480 ms, suspension allows an observation of the effect of one power control -decision before initiating the next one. +decision before initiating the next one. This is mostly important due to the +fact that MS must change the transmit power at nominal steps of 2dB every 60ms +(TS 45.008 sec 4.7.1). As a result, if the network requests the MS to change its +transmit power by several MS Power Levels at a time, the MS will do so gradually +over the next measurement period. Hence, upon next received L1 SACCH block, the +_MS_PWR_ value announced by the MS will match only the one used to transmit the +last block, and so the related measured RxLevel/RxQual values will be +inaccurate. By skipping one or several SACCH blocks, the algorithm will always +use values which match correctly the announced _MS_PWR_ and the measured +RxLevel/RxQual (because the _MS_PWR_ will already have changed and hence will be +kept stable over that measurement period). ---- OsmoBSC(config-bs-power-ctrl)# ctrl-interval ? <0-31> P_CON_INTERVAL, in units of 2 SACCH periods (0.96 seconds) ---- -By default, the suspension interval is set to 0 for both MS/BS power control loops, -therefore the power control decision is taken every 480 ms (one SACCH block period). -Setting `ctrl-interval` to 1 increases the interval to 960 ms, so basically every -second Uplink SACCH block is skipped; value 2 corresponds to the interval of -1920 ms, so 3/4 received SACCH blocks are skipped. +The value to use for this parameter is closely related to that of VTY option +`step-size inc <2-6> red <2-4>`, which configures the maximum step (in dB) at +which the MS Power can be requested to changed when the MS Power Control Loop is +triggered. The higher the `step-size`, the more time it will need the MS to do +the necessary ramping of 2 dB steps, and hence the amount of time required for +the MS to settle on the requested MS Power Level for an entire SACCH block. Or +equally, the time the network can start using the full measurement period to +trigger the MS Power Control Loop again with reliable measurements +(`P_CON_INTERVAL`). -3GPP TS 45.008 briefly mentions this parameter in table A.1 (P_Con_INTERVAL). +By default, increment `step-size` is set to 4 dB and the decrement `step-size` +is set to 2 dB, hence the MS requiring `4 * 60 = 240` milliseconds. That's less +than 1 measurement period (480 ms), hence only the first measurement period +needs to be skipped. Therefore, the suspension interval is set to 1 for both +MS/BS power control loops, and so the power control decision is taken every 960 +ms (every second SACCH block period). + +Setting `ctrl-interval` to 0 increases the interval to 480 ms, so basically no +SACCH block is skipped and MS Power Control loop is triggered upon receival of +every UL SACCH block. Value 2 corresponds to the interval of 1920 ms, so 3/4 +received SACCH blocks are skipped. + +3GPP TS 45.008 briefly mentions this parameter in table A.1 (`P_Con_INTERVAL`). A small time graph is depicted below for better understanding of the meaning of values for this parameter, since it is not obvious at all. @@ -173,8 +199,8 @@ values for this parameter, since it is not obvious at all. |<-->| - one SACCH multi-frame period | | |----|----|----|----|----|----|----|----|----> SACCH multi-frames -a) * * * * * * * * * P_CON_INTERVAL=0 (0.48 s, default) -b) * * * * * P_CON_INTERVAL=1 (0.96 s) +a) * * * * * * * * * P_CON_INTERVAL=0 (0.48 s) +b) * * * * * P_CON_INTERVAL=1 (0.96 s, default) c) * * * P_CON_INTERVAL=2 (1.92 s) d) * * P_CON_INTERVAL=3 (2.88 s) e) * * P_CON_INTERVAL=4 (3.84 s) diff --git a/src/osmo-bsc/bts_vty.c b/src/osmo-bsc/bts_vty.c index dbfe5e46b..3774344c1 100644 --- a/src/osmo-bsc/bts_vty.c +++ b/src/osmo-bsc/bts_vty.c @@ -2978,7 +2978,7 @@ DEFUN_USRATTR(cfg_power_ctrl_ctrl_interval, X(BSC_VTY_ATTR_NEW_LCHAN), "ctrl-interval <0-31>", "Set power control interval (for dynamic mode)\n" - "P_CON_INTERVAL, in units of 2 SACCH periods (0.96 seconds)\n") + "P_CON_INTERVAL, in units of 2 SACCH periods (0.96 seconds)(default=1)\n") { struct gsm_power_ctrl_params *params = vty->index; @@ -3928,8 +3928,7 @@ static void config_write_power_ctrl(struct vty *vty, unsigned int indent, if (cp->dir == GSM_PWR_CTRL_DIR_DL) cfg_out(" bs-power dyn-max %u%s", cp->bs_power_max_db, VTY_NEWLINE); - if (cp->ctrl_interval > 0) - cfg_out(" ctrl-interval %u%s", cp->ctrl_interval, VTY_NEWLINE); + cfg_out(" ctrl-interval %u%s", cp->ctrl_interval, VTY_NEWLINE); cfg_out(" step-size inc %u red %u%s", cp->inc_step_size_db, cp->red_step_size_db, VTY_NEWLINE); diff --git a/src/osmo-bsc/gsm_data.c b/src/osmo-bsc/gsm_data.c index 02d9fd7cb..a6c54d8c3 100644 --- a/src/osmo-bsc/gsm_data.c +++ b/src/osmo-bsc/gsm_data.c @@ -1142,6 +1142,8 @@ const struct gsm_power_ctrl_params power_ctrl_params_def = { .inc_step_size_db = 4, /* 2, 4, or 6 dB */ .red_step_size_db = 2, /* 2 or 4 dB */ + .ctrl_interval = 1, /* Trigger loop every second SACCH block. TS 45.008 sec 4.7.1 */ + /* RxLev measurement parameters */ .rxlev_meas = { /* Thresholds for RxLev (see 3GPP TS 45.008, A.3.2.1) */ diff --git a/tests/power_ctrl.vty b/tests/power_ctrl.vty index 8cb695f16..af02cd412 100644 --- a/tests/power_ctrl.vty +++ b/tests/power_ctrl.vty @@ -7,6 +7,7 @@ OsmoBSC# show running-config mode static ms-power-control mode dyn-bts + ctrl-interval 1 step-size inc 4 red 2 rxlev-thresh lower 32 upper 38 rxlev-thresh-comp lower 10 12 upper 19 20 @@ -70,6 +71,7 @@ OsmoBSC(config-bs-power-ctrl)# show running-config bs-power-control mode dyn-bts bs-power dyn-max 12 + ctrl-interval 1 step-size inc 4 red 2 rxlev-thresh lower 32 upper 38 rxlev-thresh-comp lower 10 12 upper 19 20 @@ -96,9 +98,11 @@ OsmoBSC(config-bs-power-ctrl)# show running-config bs-power-control ... ctrl-interval 31 -... !ctrl-interval +... ms-power-control -... !ctrl-interval +... + ctrl-interval 1 +... OsmoBSC(config-bs-power-ctrl)# exit OsmoBSC(config-net-bts)# ms-power-control @@ -131,6 +135,7 @@ OsmoBSC(config-ms-power-ctrl)# show running-config ... ms-power-control mode dyn-bts + ctrl-interval 1 step-size inc 4 red 2 rxlev-thresh lower 32 upper 38 rxlev-thresh-comp lower 10 12 upper 19 20 @@ -283,6 +288,7 @@ OsmoBSC(config-net-bts)# show running-config mode static ms-power-control mode dyn-bts + ctrl-interval 1 step-size inc 4 red 2 rxlev-thresh lower 32 upper 38 rxlev-thresh-comp lower 10 12 upper 19 20