Update kuukar_motion.py
This commit is contained in:
parent
82620a98ca
commit
387bbbb215
|
@ -159,12 +159,12 @@ class motion:
|
||||||
while True:
|
while True:
|
||||||
if self.roaming:
|
if self.roaming:
|
||||||
self.__roam_handle()
|
self.__roam_handle()
|
||||||
time.sleep(0.5)
|
time.sleep(0.1)
|
||||||
|
|
||||||
def __roam_handle(self):
|
def __roam_handle(self):
|
||||||
if self.sensors.sonar_get_distance()<500:
|
if self.sensors.sonar_get_distance()<900:
|
||||||
self.turn(30,2000)
|
self.turn(32,2600)
|
||||||
self.drive(25)
|
self.drive(25)
|
||||||
time.sleep(0.5)
|
|
||||||
if not self.roaming:
|
if not self.roaming:
|
||||||
self.stop()
|
self.stop()
|
Loading…
Reference in New Issue