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/+/17663 ) Change subject: Move parsing of HPLMNAcT to generic Card class ...................................................................... Move parsing of HPLMNAcT to generic Card class Change-Id: I46c863c118dcbef89455c34289ed25e5a342f35b --- M pySim-read.py M pySim/cards.py 2 files changed, 9 insertions(+), 2 deletions(-) git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/63/17663/1 diff --git a/pySim-read.py b/pySim-read.py index 0da00b5..5bd20ef 100755 --- a/pySim-read.py +++ b/pySim-read.py @@ -183,9 +183,9 @@ # EF.HPLMNAcT try: - (res, sw) = scc.read_binary(EF['HPLMNAcT']) + (res, sw) = card.read_hplmn_act() if sw == '9000': - print("HPLMNAcT:\n%s" % (format_xplmn_w_act(res))) + print("HPLMNAcT:\n%s" % (res)) else: print("HPLMNAcT: Can't read, response code = %s" % (sw,)) except Exception as e: diff --git a/pySim/cards.py b/pySim/cards.py index ac9d993..b8af407 100644 --- a/pySim/cards.py +++ b/pySim/cards.py @@ -66,6 +66,13 @@ data, sw = self._scc.update_binary(EF['ACC'], lpad(acc, 4)) return sw + def read_hplmn_act(self): + (res, sw) = self._scc.read_binary(EF['HPLMNAcT']) + if sw == '9000': + return (format_xplmn_w_act(res), sw) + else: + return (None, sw) + def update_hplmn_act(self, mcc, mnc, access_tech='FFFF'): """ Update Home PLMN with access technology bit-field -- To view, visit https://gerrit.osmocom.org/c/pysim/+/17663 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: pysim Gerrit-Branch: master Gerrit-Change-Id: I46c863c118dcbef89455c34289ed25e5a342f35b Gerrit-Change-Number: 17663 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/20200330/c01025fc/attachment.htm>