Skip to content

Commit ef91f79

Browse files
committed
Upping the ls_get_status() timeout for digital sensors; should fix Issue 35.
1 parent 1038a43 commit ef91f79

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

nxt/sensor/digital.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# nxt.sensor module -- Classes to read LEGO Mindstorms NXT sensors
22
# Copyright (C) 2006,2007 Douglas P Lau
33
# Copyright (C) 2009 Marcus Wanner, Paulo Vieira, rhn
4-
# Copyright (C) 2010,2011 Marcus Wanner
4+
# Copyright (C) 2010,2011,2012 Marcus Wanner
55
#
66
# This program is free software: you can redistribute it and/or modify
77
# it under the terms of the GNU General Public License as published by
@@ -81,7 +81,7 @@ def __init__(self, brick, port, check_compatible=True):
8181
suppressed by passing "check_compatible=False" when creating the sensor object.""")
8282

8383
def _ls_get_status(self, n_bytes):
84-
for n in range(10):
84+
for n in range(30): #https://code.google.com/p/nxt-python/issues/detail?id=35
8585
try:
8686
b = self.brick.ls_get_status(self.port)
8787
if b >= n_bytes:

0 commit comments

Comments
 (0)