Open main menu
Home
Random
Log in
Settings
About Sugar Labs
Disclaimers
Sugar Labs
Search
Changes
← Older edit
Newer edit →
Activities/Turtle Art/Programmable Brick
(view source)
Revision as of 21:16, 26 August 2011
4 bytes added
,
21:16, 26 August 2011
→Device I/O
Line 177:
Line 177:
# The light sensor is only available on the XO 1.75
# The light sensor is only available on the XO 1.75
device = '/sys/devices/platform/olpc-ols.0/power_state'
device = '/sys/devices/platform/olpc-ols.0/power_state'
−
+
if os.path.exists(device):
if os.path.exists(device):
fh = open(device)
fh = open(device)
Tonyforster
2,486
edits