aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Tools/HardwareInfo.py
diff options
context:
space:
mode:
authorStefan Pluecken <stefan.pluecken@multimedia-labs.de>2008-07-03 13:02:41 +0000
committerStefan Pluecken <stefan.pluecken@multimedia-labs.de>2008-07-03 13:02:41 +0000
commit89cd5ceb75dd5b59ff58a549402541a983d42ccd (patch)
tree7d2fa0d7df9f85610921af045ae472b75f3553b7 /lib/python/Tools/HardwareInfo.py
parent6e68543591be09859bbaa4c19e0065e65d8acfe3 (diff)
downloadenigma2-89cd5ceb75dd5b59ff58a549402541a983d42ccd.tar.gz
enigma2-89cd5ceb75dd5b59ff58a549402541a983d42ccd.zip
the class HardwareInfo is used to determine the dreambox model (taken
from /proc/stb/info/model) (needs new driver info.ko)
Diffstat (limited to 'lib/python/Tools/HardwareInfo.py')
-rw-r--r--lib/python/Tools/HardwareInfo.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/python/Tools/HardwareInfo.py b/lib/python/Tools/HardwareInfo.py
new file mode 100644
index 00000000..38cccb57
--- /dev/null
+++ b/lib/python/Tools/HardwareInfo.py
@@ -0,0 +1,10 @@
+class HardwareInfo:
+ def __init__(self):
+ self.device = "unknown"
+ file = open("/proc/stb/info/model", "r")
+ self.device = file.readline().strip()
+
+ def get_device_name(self):
+ return self.device
+
+ device_name = property(get_device_name) \ No newline at end of file