OpenMV cam Eye Tracker

OpenMV related project discussion.
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

OpenMV cam Eye Tracker

Postby Titusblacksad » Fri Jan 06, 2017 5:57 am

Hello everyone,
I am working with a team of students in France, and we have a project to make during the year. We decided to make an eye-tracker for disabled persons that you can just plug in the computer to make it work. We decided to use the open mv cam along with a teensy, but we need help transfering eye coordinates to the teensy, to change them into screen coordinates (so that the mouse cursor moves to where you look). Can someone help us?
Best reguards
User avatar
kwagyeman
Posts: 449
Joined: Sun May 24, 2015 2:10 pm

Re: OpenMV cam Eye Tracker

Postby kwagyeman » Fri Jan 06, 2017 9:38 am

Yes, what communications bus would you like to use to send the coordinates? SPI, I2C, Serial? Serial is the easiest. I can provide some example code for the OpenMV Cam.
Nyamekye,
User avatar
kwagyeman
Posts: 449
Joined: Sun May 24, 2015 2:10 pm

Re: OpenMV cam Eye Tracker

Postby kwagyeman » Sat Jan 07, 2017 11:12 am

Here's are versions of the eye tracking scripts with serial output added.
Attachments
iris_detection_uart.py
(1.75 KiB) Downloaded 10 times
face_eye_detection_uart.py
(1.72 KiB) Downloaded 13 times
Nyamekye,
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

Re: OpenMV cam Eye Tracker

Postby Titusblacksad » Sun Jan 29, 2017 11:23 am

I took a look, but there are some things that I don't quite understand.
First of all, in the beginning of the script for the iris detection, it is written that the face is not detected, it needs the other script. But since the camera is going to be sitting close to the eye, is it necessary?
And how do we take the coordinates of the eye and use them through Serial with the Teensy?
User avatar
kwagyeman
Posts: 449
Joined: Sun May 24, 2015 2:10 pm

Re: OpenMV cam Eye Tracker

Postby kwagyeman » Sun Jan 29, 2017 12:18 pm

Hi, the second script literally zooms in on the area eye to skip the face detection part. It assumes that you have the camera mounted such that only the eyes are in the field of view.

As for the coordinates. The script sends them out through serial in pain text. What do you need help with?
Nyamekye,
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

Re: OpenMV cam Eye Tracker

Postby Titusblacksad » Sun Jan 29, 2017 12:38 pm

I would need help for the teensy code; I just understood where the coordinates are sent in the python script, but can we just use x and y in the arduino code?
User avatar
kwagyeman
Posts: 449
Joined: Sun May 24, 2015 2:10 pm

Re: OpenMV cam Eye Tracker

Postby kwagyeman » Sun Jan 29, 2017 1:20 pm

Yes, x and y define the center of the eye. So, you just parse the text string for x and y and those are your coordinates.
Nyamekye,
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

Re: OpenMV cam Eye Tracker

Postby Titusblacksad » Thu Feb 02, 2017 3:42 pm

Hello,
we recently received the camera but we are faicing an issue; when testing the script, the IDE posts an error saying: "AttributeError: 'module' object has no attribute 'set_windowing'". What are we supposed to do?
Thnak you
User avatar
kwagyeman
Posts: 449
Joined: Sun May 24, 2015 2:10 pm

Re: OpenMV cam Eye Tracker

Postby kwagyeman » Thu Feb 02, 2017 3:43 pm

Please update your OpenMV Cam's firmware. The IDE should have a note on the bottom asking you to update the firmware.
Nyamekye,
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

Re: OpenMV cam Eye Tracker

Postby Titusblacksad » Thu Feb 02, 2017 3:48 pm

I just downloaded the software on the website since I am on an other compouter, and there is no note on the bottom...
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

Re: OpenMV cam Eye Tracker

Postby Titusblacksad » Thu Feb 02, 2017 3:49 pm

I am on version 1.4.0, if it can help
User avatar
kwagyeman
Posts: 449
Joined: Sun May 24, 2015 2:10 pm

Re: OpenMV cam Eye Tracker

Postby kwagyeman » Thu Feb 02, 2017 3:52 pm

Yes, the newest firmware is version 2.1.0.

Please install the latest version of the OpenMV IDE and update your firmware.
Nyamekye,
Titusblacksad
Posts: 7
Joined: Fri Jan 06, 2017 5:44 am

Re: OpenMV cam Eye Tracker

Postby Titusblacksad » Thu Feb 02, 2017 4:07 pm

I found the note, I had to connect the camera. Sorry! Everyhting is working fine now.

Return to “Project Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest