Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/TurtleArt
diff options
context:
space:
mode:
authorWalter Bender <walter.bender@gmail.com>2011-08-18 15:32:18 (GMT)
committer Walter Bender <walter.bender@gmail.com>2011-08-18 15:32:18 (GMT)
commita41c5e3423e4aa587a2cb965b96ce7a285feea07 (patch)
treedf526c8e992478a0f9d62c5fc8a5b79b734b5dbc /TurtleArt
parent2855820ab9b273dd756b7ff9c7d04564af6c8a96 (diff)
fixed bug in xo 1.75 detection
Diffstat (limited to 'TurtleArt')
-rw-r--r--TurtleArt/tautils.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/TurtleArt/tautils.py b/TurtleArt/tautils.py
index ed14784..f4b6bdc 100644
--- a/TurtleArt/tautils.py
+++ b/TurtleArt/tautils.py
@@ -42,7 +42,7 @@ except (ImportError, AttributeError):
from StringIO import StringIO
from taconstants import HIDE_LAYER, COLLAPSIBLE, BLOCK_LAYER, HIT_HIDE, \
- HIT_SHOW, XO1, XO15, UNKNOWN
+ HIT_SHOW, XO1, XO15, XO175, UNKNOWN
import logging
_logger = logging.getLogger('turtleart-activity')
@@ -803,7 +803,9 @@ def get_hardware():
""" Determine whether we are using XO 1.0, 1.5, or "unknown" hardware """
product = _get_dmi('product_name')
if product is None:
- if os.path.exists('/etc/olpc-release') or \
+ if os.path.exists('/sys/devices/platform/lis3lv02d/position'):
+ return XO175 # FIXME: temporary check for XO 1.75
+ elif os.path.exists('/etc/olpc-release') or \
os.path.exists('/sys/power/olpc-pm'):
return XO1
else:
@@ -816,7 +818,7 @@ def get_hardware():
elif version == '1.5':
return XO15
else:
- return UNKNOWN
+ return XO175
def _get_dmi(node):