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/.
herlesupreeth gerrit-no-reply at lists.osmocom.orgherlesupreeth has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/18071 ) Change subject: Extract PLMN digits from IMSI in non-batch programming scenario ...................................................................... Extract PLMN digits from IMSI in non-batch programming scenario With the help of mnclen argument we extract the MNC and MCC from the provided IMSI and not rely on -x and -y arguments which are solely used in batch programming of cards. Change-Id: I48bf7cf94d23960db944f39b84f0c3f057d89659 --- M pySim-prog.py 1 file changed, 5 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/71/18071/1 diff --git a/pySim-prog.py b/pySim-prog.py index c709959..ed0de2e 100755 --- a/pySim-prog.py +++ b/pySim-prog.py @@ -272,6 +272,11 @@ mcc = opts.mcc mnc = opts.mnc + # Extract MCC and MNC in case of non-batch programming case + if not opts.batch_mode and (opts.imsi is not None) and _isnum(opts.imsi): + mcc = int(opts.imsi[0:3]) + mnc = int(opts.imsi[3:3+opts.mnclen]) + if not ((0 < mcc < 999) and (0 < mnc < 999)): raise ValueError('mcc & mnc must be between 0 and 999') -- To view, visit https://gerrit.osmocom.org/c/pysim/+/18071 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I48bf7cf94d23960db944f39b84f0c3f057d89659 Gerrit-Change-Number: 18071 Gerrit-PatchSet: 1 Gerrit-Owner: herlesupreeth <herlesupreeth at gmail.com> Gerrit-MessageType: newchange -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200506/ac9d9bd0/attachment.htm>