speed up
This commit is contained in:
parent
b811351aba
commit
bbb2b3ff17
5
run.py
5
run.py
@ -461,7 +461,8 @@ def get_sensors():
|
||||
global mbconn
|
||||
global sensors
|
||||
#print("Reading sensors")
|
||||
mbconn.open()
|
||||
if not mbconn.is_open:
|
||||
mbconn.open()
|
||||
"""
|
||||
port 1: 256
|
||||
port 2: 272
|
||||
@ -488,7 +489,7 @@ def get_sensors():
|
||||
out = [0, 0, 0, 0]
|
||||
|
||||
#fprint("Values: " + str(sensors))
|
||||
mbconn.close()
|
||||
#mbconn.close()
|
||||
for x in range(len(sensors)):
|
||||
if sensors[x] >= 180: # 3 sec
|
||||
# cable newly detected on tray
|
||||
|
Loading…
x
Reference in New Issue
Block a user