This is demonstration project to control servo motor movement using physical marker and normal video camera. In this project video camera capture the movements of marker and calculate rotation angle based on that. This calculated rotation angle is feed to the servo through small MCU based interfacing unit.

In this project video processing and tracking is performed using ARToolkit and controlling of servo is carried out using PIC16F628A microcontroller. RS232 interface is use to communicate between PC and microcontroller.

rovmodel.png
Interfaces in optical servo controlling system

This application detects movement of marker on Z axis (yaw) and transforms it into another numerical scale to manipulate the servo motor. Processing application is written using Visual C++ and configured to work on Windows operating system(s). The marker used for this application is needed to be a "square with some symbol" and user can train this system for any compatible marker. As per our tests, standard 3-mega pixel or higher grade web cam is sufficient for this system.

To demonstrate the exact behavior video is much more suitable but my web cam is used for this project and I don’t have spare web cam to capture the operation of this project. As per our observations servo movement is highly sensitive to the changes of marker object and the movement of the servo motor is also linear and smooth. The propagation time is little bit slow due to serial interface and this can be improved by using high speed I/O interface like USB port.

Project Related Downloads


The source code, servo driver schematic and firmware of optical servo controlling system

References


PIC16F628A - FLASH-Based 8-Bit CMOS Microcontroller
MAX232 - 5V Powered Multichannel RS-232 Drivers/Receivers
ARToolKit Homepage