fix roaming

This commit is contained in:
Siwat Sirichai 2022-11-09 23:18:23 +07:00
parent ab3a4477c7
commit 15ef7493c7
2 changed files with 2 additions and 5 deletions

2
app.py
View File

@ -18,8 +18,6 @@ lcd = kuukar_lcd.lcd(motion, sensors)
environment = kuukar_environment.environment(lcd, leds, sensors)
collision = kuukar_collision.collision(mcu, lcd, leds)
motion.roam_start()
while True:
temp = sensors.get_temperature()
humid = sensors.get_humidity_pct()

View File

@ -93,6 +93,8 @@ class motion:
def roam_stop(self):
self.roaming = False
time.sleep(0.5)
self.stop()
def is_roaming(self) -> bool:
return self.roaming
@ -133,7 +135,4 @@ class motion:
else:
self.turn(-23, TURN_TIME_FS_90DEG_MS)
self.drive(30)
self.stop()
print("stopping")
time.sleep(0.5)