mirror of
https://gitea.osmocom.org/sim-card/pysim.git
synced 2026-03-17 02:48:34 +03:00
pySim-shell: add ADF.ISIM / ADF.USIM dynamically
currently ADF.ISIM and ADF.USIM are always added regardless if there is a matching application on the card or not. Lets check what applications are actually installed and add ADF.ISIM and ADF.USIM dynamically. Change-Id: I42ee23375f98e6322708c1c4db6d65e1425feecd Related: OS#4963
This commit is contained in:
@@ -207,6 +207,7 @@ class Card(object):
|
||||
|
||||
# Fetch all the AIDs present on UICC
|
||||
def read_aids(self):
|
||||
self._aids = []
|
||||
try:
|
||||
# Find out how many records the EF.DIR has
|
||||
# and store all the AIDs in the UICC
|
||||
@@ -218,6 +219,8 @@ class Card(object):
|
||||
self._aids.append(rec[0][8:8 + int(rec[0][6:8], 16) * 2])
|
||||
except Exception as e:
|
||||
print("Can't read AIDs from SIM -- %s" % (str(e),))
|
||||
self._aids = []
|
||||
return self._aids
|
||||
|
||||
# Select ADF.U/ISIM in the Card using its full AID
|
||||
def select_adf_by_aid(self, adf="usim"):
|
||||
|
||||
Reference in New Issue
Block a user