aboutsummaryrefslogtreecommitdiffstats
path: root/pySim-read.py
diff options
context:
space:
mode:
Diffstat (limited to 'pySim-read.py')
-rwxr-xr-xpySim-read.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/pySim-read.py b/pySim-read.py
index 066b0df..4356453 100755
--- a/pySim-read.py
+++ b/pySim-read.py
@@ -56,6 +56,10 @@ def parse_options():
help="Which PC/SC reader number for SIM access",
default=None,
)
+ parser.add_option("--osmocon", dest="osmocon_sock", metavar="PATH",
+ help="Socket path for Calypso (e.g. Motorola C1XX) based reader (via OsmocomBB)",
+ default=None,
+ )
(options, args) = parser.parse_args()
@@ -74,6 +78,9 @@ if __name__ == '__main__':
if opts.pcsc_dev is not None:
from pySim.transport.pcsc import PcscSimLink
sl = PcscSimLink(opts.pcsc_dev)
+ elif opts.osmocon_sock is not None:
+ from pySim.transport.calypso import CalypsoSimLink
+ sl = CalypsoSimLink(sock_path=opts.osmocon_sock)
else: # Serial reader is default
from pySim.transport.serial import SerialSimLink
sl = SerialSimLink(device=opts.device, baudrate=opts.baudrate)