Compare commits

...

1 Commits
lite ... main

Author SHA1 Message Date
Siwat Sirichai 52a5f3d8a8 implement kuukar_cv 2022-12-11 11:18:06 +07:00
2 changed files with 5 additions and 0 deletions

View File

@ -5,6 +5,7 @@ import kuukar.kuukar_motion as kuukar_motion
import kuukar.kuukar_lcd as kuukar_lcd
import kuukar.kuukar_sensors as kuukar_sensors
import kuukar.kuukar_environment as kuukar_environment
import kuukar.kuukar_cv as kuukar_cv
from kuukar.kuukar_config import SERIAL_MCU, SERIAL_DRV
@ -23,3 +24,4 @@ class kuukar:
self.lcd, self.leds, self.sensors)
self.collision = kuukar_collision.collision(
self.mcu, self.lcd, self.leds)
self.cv = kuukar_cv.cv(self.lcd, self.leds)

View File

@ -18,10 +18,13 @@ class cv:
img = self.capture_image()
stop_sign = self.detect_sign(img)
def get_road_curve(self, frame):
pass
def capture_image(self):
ret, frame = self.camera.read()
return frame
def detect_sign(self, frame):
stopsign_cascade = cv2.CascadeClassifier('./stopsign_good.xml')
image = frame.array