Fix simulation mode
This commit is contained in:
parent
48e7c7b85f
commit
3fb78f8b5a
6
run.py
6
run.py
@ -37,7 +37,7 @@ import time
|
||||
import subprocess
|
||||
|
||||
# set to false to run without real hardware for development
|
||||
real = True
|
||||
real = False
|
||||
skip_scanning = True
|
||||
|
||||
mbconn = None
|
||||
@ -542,6 +542,8 @@ def get_sensors():
|
||||
global mbconn
|
||||
global sensors
|
||||
#print("Reading sensors")
|
||||
if not real:
|
||||
return -1
|
||||
if not mbconn.is_open:
|
||||
mbconn.open()
|
||||
"""
|
||||
@ -739,7 +741,7 @@ def mainloop_server(pool, manager):
|
||||
if ring_animation is not None and real:
|
||||
ledsys.mainloop(None, ring_animation, arm_position=arm_position)
|
||||
|
||||
else:
|
||||
elif real:
|
||||
ledsys.mainloop(None, -1, arm_position=arm_position)
|
||||
|
||||
# every 1 second
|
||||
|
Loading…
x
Reference in New Issue
Block a user