The thesis presents the development of the autofocus method, which is used with independent lenses that serve as an accessory for the camera. There was a demand in the company to optimize the autofocus algorithm, as the previous algorithm was unreliable. Autofocus will serve as an aid to end users so that they can focus the image at the touch of a button.
I wrote a driver to calculate the image sharpness value, a driver to move the lens using a motor and an algorithm to automatically focus the images. I used the Brenner gradient to calculate the image sharpness value, which is one of the passive autofocus modes suitable for still images. To move the lens with the motor I used a PID control algorithm and a pulse width modulation. The system consists of a graphic processing unit, a lens, a camera and a control circuit. The entire project was written in the C programming language using the Keil integrated development environment.
Through the production of the project, I achieved all the set goals. The program can be used with any lens, it focuses the image regardless of the picture color and its operation should be unaffected by any external factors such as weather conditions. The program is now in use by the DATCON company as part of their sales offering.
|