try to init modem one by one
This commit is contained in:
@@ -13,3 +13,10 @@ class SerialModem():
|
||||
def __init__(self, modem: GsmModem, ccid: str = None):
|
||||
self.modem = modem
|
||||
self.ccid = ccid
|
||||
|
||||
def get_ccid(self):
|
||||
cmd = "AT+CCID\r"
|
||||
self.modem.connect()
|
||||
response = self.modem.write(cmd, True)
|
||||
self.ccid = response[0].split(" ")[1].replace("\"", "")
|
||||
print("The SIM card ccid is:" + self.ccid)
|
||||
|
||||
Reference in New Issue
Block a user