How to achieve enhanced autofocus performance?

  • Leader
    November 26, 2024 11:18 PM PST
    From barcode scanning to self-service terminal interfaces and sophisticated industrial robots, autofocus cameras have become an indispensable tool in a wide range of industries. The autofocus function allows for clear focus by adjusting the lens to improve the reliability and efficiency of visual data capture, and how to improve the performance of autofocus cameras has become the focus of the moment.Get more news about Sinoseen,you can vist our website!

    What is autofocus?
    Autofocus is a camera feature that quickly adapts to changes in distance between the camera and the subject by dynamically changing the position of the lens to obtain the sharpest image possible. The autofocus system consists of a lens brake, an image signal processor (ISP), and the 3A function, which is a collective term for autofocus, auto exposure, and auto white balance, which work in tandem to ensure optimal image quality.We have seen the information about autofocus before, interested in the next article.

    Challenges of the autofocus mechanism
    Autofocus cameras are designed with a default focus range of typically 10 cm to infinity and average focus accuracy. It is still somewhat inadequate in some specific applications, for example:

    In situations where the object size is significantly smaller than the autofocus region of interest (ROI), the default autofocus accuracy may not be sufficient.
    Some applications that require a fixed working distance do not benefit from the full range focus feature. When objects cover most of the ROI, higher AF accuracy and faster stabilization times are required.
    The speed at which the autofocus system locks onto the correct focus point is important for the need for fast response times.
    How can autofocus accuracy be improved?
    The Image Signal Processor (ISP) plays a key role in the AF mechanism. And Sinoseen has a number of options for improving the focusing accuracy of AF cameras, which involve fine-tuning the ISP settings.

    1. Using Two-Pass method in ISP
    Traditional method: General Sinoseen AF cameras support single scanning for the full AF range (10cm to infinity) by default. This AF algorithm scans from infinity to the macro position, and can be customized with targeted settings in the ISP settings.The AF algorithm uses hill-climbing to find the sharpest image for each frame while moving the lens brake.The ISP calculates the average of the edges of each frame and obtains the relative sharpness for each lens position. Once the highest focus is achieved, the lens position stabilizes and the ISP returns to the AF Success state. This may lack precision.

    Two-Pass Method: Using the two-pass method increases the number of scans performed by the ISP. An initial scan is performed to determine the optimal focus position and then a second detailed scan is performed around that position, significantly improving focus accuracy.

    2. Narrowing the AF Scanning Range
    In scenarios where the working distance is determined, such as barcode scanning or vending kiosks, the AF range can be narrowed to scan only this range, improving accuracy. For example, if an object is fixed within 1m to 1.5m, by default, the AF camera focuses between 100-120. However, it is possible to remap this range to 255 steps instead of the usual 0-255 steps via the ISP settings. to improve AF accuracy.

    Generally, the scanning range is determined by the working distance, which is convenient for ISP to scan the same area with higher accuracy.

    3. Increase the scanning slot value
    The number of equidistant steps (slots) in the AF range is directly related to the focusing accuracy. Increasing the slot value allows for more detailed scanning of the focus range, resulting in finer adjustments and improved accuracy. This is particularly effective in the two-pass scanning method.