Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/rfid/serial/__init__.py
diff options
context:
space:
mode:
authorWalter Bender <walter.bender@gmail.com>2011-02-18 14:10:55 (GMT)
committer Walter Bender <walter.bender@gmail.com>2011-02-18 14:10:55 (GMT)
commit1ac01a1596c5c6c3b5feb80fdee47a0cfe81ca9a (patch)
tree0545ee046cc55eef17b60c9dd2b2106e31de04ef /rfid/serial/__init__.py
parent4d4dc0502119523ad4ab0eaba77bef58a0adc18f (diff)
renaming rfid device directory
Diffstat (limited to 'rfid/serial/__init__.py')
-rw-r--r--rfid/serial/__init__.py25
1 files changed, 25 insertions, 0 deletions
diff --git a/rfid/serial/__init__.py b/rfid/serial/__init__.py
new file mode 100644
index 0000000..681ad5c
--- /dev/null
+++ b/rfid/serial/__init__.py
@@ -0,0 +1,25 @@
+#!/usr/bin/env python
+#portable serial port access with python
+#this is a wrapper module for different platform implementations
+#
+# (C)2001-2002 Chris Liechti <cliechti@gmx.net>
+# this is distributed under a free software license, see license.txt
+
+VERSION = '2.4'
+
+import sys
+
+if sys.platform == 'cli':
+ from serialcli import *
+else:
+ import os
+ #chose an implementation, depending on os
+ if os.name == 'nt': #sys.platform == 'win32':
+ from serialwin32 import *
+ elif os.name == 'posix':
+ from serialposix import *
+ elif os.name == 'java':
+ from serialjava import *
+ else:
+ raise Exception("Sorry: no implementation for your platform ('%s') available" % os.name)
+