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/.
neels gerrit-no-reply at lists.osmocom.orgneels has submitted this change. ( https://gerrit.osmocom.org/c/osmo-bsc/+/24380 ) Change subject: VTY: add 'vamos-subslot' to activate a secondary lchan ...................................................................... VTY: add 'vamos-subslot' to activate a secondary lchan Related: SYS#5315 OS#4940 Change-Id: If44b6bdb78046502eb0b66529ae190a955d9978c --- M src/osmo-bsc/bsc_vty.c M tests/osmo-bsc.vty 2 files changed, 27 insertions(+), 10 deletions(-) Approvals: Jenkins Builder: Verified neels: Looks good to me, approved dexter: Looks good to me, but someone else must approve pespin: Looks good to me, but someone else must approve diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c index 3eedffb..71a0f0b 100644 --- a/src/osmo-bsc/bsc_vty.c +++ b/src/osmo-bsc/bsc_vty.c @@ -6297,8 +6297,10 @@ * manually in a given mode/codec. This is useful for receiver * performance testing (FER/RBER/...) */ DEFUN(lchan_act, lchan_act_cmd, - "bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> (activate|activate-vamos|deactivate) (hr|fr|efr|amr|sig) [<0-7>]", - BTS_NR_TRX_TS_SS_STR2 + "bts <0-255> trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> (activate|activate-vamos|deactivate) (hr|fr|efr|amr|sig) [<0-7>]", + BTS_NR_TRX_TS_STR2 + "Primary sub-slot\n" "VAMOS secondary shadow subslot, range <0-1>, only valid for TCH type timeslots\n" + SS_NR_STR "Manual Channel Activation (e.g. for BER test)\n" "Manual Channel Activation, in VAMOS mode\n" "Manual Channel Deactivation (e.g. for BER test)\n" @@ -6306,19 +6308,33 @@ { struct gsm_bts_trx_ts *ts; struct gsm_lchan *lchan; - int ss_nr = atoi(argv[3]); - const char *act_str = argv[4]; - const char *codec_str = argv[5]; + bool vamos = (strcmp(argv[3], "vamos-sub-slot") == 0); + int ss_nr = atoi(argv[4]); + const char *act_str = argv[5]; + const char *codec_str = argv[6]; int activate; int amr_mode = -1; - if (argc > 6) - amr_mode = atoi(argv[6]); + if (argc > 7) + amr_mode = atoi(argv[7]); ts = vty_get_ts(vty, argv[0], argv[1], argv[2]); if (!ts) return CMD_WARNING; + if (ss_nr >= ts->max_primary_lchans) { + vty_out(vty, "Invalid sub-slot number for this timeslot type%s", VTY_NEWLINE); + return CMD_WARNING; + } + + if (vamos && !osmo_bts_has_feature(&ts->trx->bts->features, BTS_FEAT_VAMOS)) { + vty_out(vty, "BTS does not support VAMOS%s", VTY_NEWLINE); + return CMD_WARNING; + } + + if (vamos) + ss_nr += ts->max_primary_lchans; + lchan = &ts->lchan[ss_nr]; if (!strcmp(act_str, "activate")) diff --git a/tests/osmo-bsc.vty b/tests/osmo-bsc.vty index c7e9e6d..cbd4985 100644 --- a/tests/osmo-bsc.vty +++ b/tests/osmo-bsc.vty @@ -33,7 +33,7 @@ OsmoBSC# list ... - bts <0-255> trx <0-255> timeslot <0-7> sub-slot <0-7> (activate|activate-vamos|deactivate) (hr|fr|efr|amr|sig) [<0-7>] + bts <0-255> trx <0-255> timeslot <0-7> (sub-slot|vamos-sub-slot) <0-7> (activate|activate-vamos|deactivate) (hr|fr|efr|amr|sig) [<0-7>] ... OsmoBSC# bts? @@ -59,8 +59,9 @@ <0-7> Timeslot Number OsmoBSC# bts 0 trx 0 timeslot 0 ? - pdch Packet Data Channel - sub-slot Sub-slot for manual command + pdch Packet Data Channel + sub-slot Primary sub-slot + vamos-sub-slot VAMOS secondary shadow subslot, range <0-1>, only valid for TCH type timeslots OsmoBSC# bts 0 trx 0 timeslot 0 sub-slot ? <0-7> Sub-slot Number -- To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/24380 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bsc Gerrit-Branch: master Gerrit-Change-Id: If44b6bdb78046502eb0b66529ae190a955d9978c Gerrit-Change-Number: 24380 Gerrit-PatchSet: 26 Gerrit-Owner: neels <nhofmeyr at sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: dexter <pmaier at sysmocom.de> Gerrit-Reviewer: neels <nhofmeyr at sysmocom.de> Gerrit-Reviewer: pespin <pespin at sysmocom.de> Gerrit-CC: laforge <laforge at osmocom.org> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210610/6566cdac/attachment.htm>