How Camera Module Autofocus Works 2

Jul 08, 2026

Leave a message

1. The Three Core Elements of Autofocus

Unlike manual focusing, modern autofocus is not driven by a single technology. Instead, it is the result of three systems working together:

Optical principles determine how light is focused onto the image sensor.

Mechanical actuators physically move the lens to the correct position.

Autofocus algorithms analyze image data and decide how the lens should move.

Only when these three components operate together can a camera achieve fast and accurate autofocus.

 

https://images.openai.com/static-rsc-4/boUbmOHckjBEwk8R0O8drbJvmbDhKnUNTGt11ad2hAHGot1R3rT9lNtRbFIFbJyvepLXhD5J5VbXMF86GQtuLjlJz7vIuH0w3uCtG2UyFuQO7JJkILxgeJWM2s6hfKRGtRC9osKSByN3l_B1GRClkXFtEpAKKLsgjb-Q58spUwweymNfDzOSGPtmU0iS5Qv1?purpose=fullsize

 

2. Optical Principle: Why Lens Movement Changes Focus

The foundation of autofocus is optical imaging.

A camera lens bends incoming light and projects it onto the image sensor. When the subject moves closer or farther away, the focal plane shifts. If the sensor is no longer positioned on that focal plane, the image becomes blurred.

Autofocus restores image sharpness by moving the lens until the focal plane once again aligns precisely with the sensor.

Think of it like adjusting a magnifying glass over a sheet of paper. Moving the lens slightly changes where the light converges, allowing the image to become sharp again.

Key Components

Optical lens

Image sensor

Focal plane

Typical Workflow

Estimate subject distance.

Calculate the required focal position.

Move the lens.

Verify image sharpness.

 

https://images.openai.com/static-rsc-4/FX3OxhM7DxhDy10xvDsn3Wy-QHLIhhVbO_DiozEGTWPOPnvgNBfXreu_uSYexvny05YjToFUkGhYzsuVhIg_NiLvMo8pPBlcN39QkpuwAMyx4uvQ3gg6tEcRTCquhRp95RH5PuCtVq2Z6aHIfv8FfK6dh3YVzo1xmHV2oEgt2YOmhcSO4EEpDe34mGkTAwBB?purpose=fullsize

 

 

 

3. Focus Actuators: How the Lens Actually Moves

Knowing where to focus is only half the process. The lens must also be physically moved with extremely high precision.

Modern camera modules typically use miniature actuators such as:

Voice Coil Motor (VCM)

Stepper Motor

Piezoelectric Actuator (in specialized systems)

Among them, the VCM is the most widely used solution for smartphones and compact camera modules.

A VCM can move the lens by only a few hundred micrometers while maintaining excellent positioning accuracy, enabling smooth and fast autofocus.

Typical Autofocus Process

Receive the autofocus command.

Drive the actuator.

Move the lens.

Check image sharpness.

Stop when optimal focus is reached.

https://images.openai.com/static-rsc-4/HVevfrsLNfgLYA0jc4a-4jy1WyI0aic3upjBEADCb2GeFyXC1c_ScMBx0lgPmQpoBL8qVTkUfu-JFPwZaVDy4gEwngm_5VscuBiVTnjpFauxeh-amWqcbBSE-5X8uZYJSO_SWOZeq3O9bJJZqikEyoVrg3NsUSstENStX74_LlfuXw9121C_YjIGDeHIWyEt?purpose=fullsize

 

 

 

 

4. Autofocus Algorithms: The Brain Behind the System

The actuator moves the lens, but it does not decide where to move.

That task belongs to the autofocus algorithm.

The image sensor continuously captures preview frames, while the image processor evaluates image sharpness and calculates the optimal lens position.

Today's camera modules commonly use several autofocus methods:

Contrast Detection Autofocus (CDAF)

This method evaluates image contrast.

Sharper images have higher local contrast, allowing the processor to determine whether focus should move forward or backward.

Advantages:

High focusing accuracy

Simple implementation

Limitations:

Slower focusing speed

May hunt before locking focus

Phase Detection Autofocus (PDAF)

PDAF compares phase differences in incoming light to determine both the focusing direction and the required lens movement.

Advantages:

Extremely fast

Excellent for moving subjects

Common in smartphones and digital cameras

Laser Autofocus

Some camera modules also include a laser distance sensor.

Instead of estimating focus from image data, the laser directly measures subject distance, allowing autofocus to respond more quickly under low-light conditions.

 

 

https://images.openai.com/static-rsc-4/2Jh8HIO2UMf6w_lG4nbu2hN1mi-K1JE5iH91UlxyTU1jVPqBYV1IMFgqsYIPfY7ZRBQbAzTE-AZIbDId0c8153LKDc7cWk6VFBm7pIdBBxnZvEtB0THNgsTQjMOpTf2TixYOL3xSH6LKPeykijJbTO_jLI2P1_He3XVHLSdqIwia9smxWu5AbOYxy7O1IBTW?purpose=fullsize

 

 

5. Typical Autofocus Workflow

Although autofocus technologies differ, most camera modules follow the same closed-loop control process.

Capture a preview image.

Analyze image sharpness.

Calculate the required lens adjustment.

Drive the actuator.

Capture another image.

Repeat until focus is locked.

This continuous feedback loop enables autofocus to remain accurate even when the subject is moving.

 

https://images.openai.com/static-rsc-4/sgvJU3jJNsSg5G1TroQY4FxcKGN8wcPwc360UzTYkVUnAkYE2iZkj0Cf8_wV3eVGiiBiHecTkoonWKCXSsiWceS14osl7xYVuSTXoheWWKCSFS7-J5oeve-LebKczXFc7FIxRKCJtS9iI5RMkut05BGwh5pCZgZXltQi7PE_eFtJwURPoLnkO8o8O2GZ82Tf?purpose=fullsize

 

 

 

6. Real-World Examples

Smartphones

Modern smartphones combine PDAF, CDAF, AI scene recognition, and VCM actuators to achieve autofocus speeds measured in milliseconds.

Industrial Cameras

Industrial vision systems prioritize positioning accuracy over speed. High-precision actuators allow autofocus accuracy down to the micron level, making them ideal for PCB inspection, semiconductor manufacturing, and precision measurement.

 

Send Inquiry
Contact us if have any question

You can either contact us via phone, email or online form below. Our specialist will contact you back shortly.

Contact now!