Get values from face detection program

asked 2014-05-23 02:40:50 -0500

Hi , I am trying to run this face detection program , and I want to know how to get values of the detected faces and send them to arduino so that my arduino program (which contains codes for my servo motors to move to face track) can make use of that values to drive the motors? This is my code.


print __doc__

import time
from SimpleCV import *
cam = Camera(1)

haarcascade = HaarCascade("face.xml")

while display.isNotDone():
    image = cam.getImage().flipHorizontal().scale(1)
    faces = image.findHaarFeatures(haarcascade)
    if faces:
        face = faces[-1]
        face.draw(Color.RED, 1)

I have heard of the pySerial method , but I'm not sure how to use it either . Many thanks in advance !

edit retag flag offensive close merge delete