Parts arriving at different heights can exceed a fixed-focus system’s usable depth of field. Electrically controlled liquid lenses offer another way to refocus, but the optical element alone does not decide where focus belongs or when exposure should begin. For inspection-system designers, the practical choice is between calibrated distance-based commands and image-based focus search. Start with your distance range, timing budget and measurement tolerance, then evaluate the complete optical assembly rather than an isolated focusing component.
What a liquid lens changes
A liquid lens changes optical power by reshaping a liquid interface. In a common electrowetting design, two immiscible liquids have different refractive indices. An electrical drive changes the interface’s curvature, changing how strongly it converges or diverges light.
The liquid interface moves, although the assembly need not translate a conventional focusing group. That distinction does not make every assembly immune to vibration, orientation changes or temperature effects. Those behaviors require verification for the selected design.
The focusing element usually works within a larger optical system. Its clear aperture, position and power range interact with the surrounding lenses. You cannot assume that placing a liquid lens in front of an existing lens will preserve image quality or cover the required sensor.
For an ideal equivalent thin lens:
Here, P is optical power in diopters when focal length f, object distance u and image distance v are expressed in meters. These distances are measured from the relevant principal planes, not necessarily the front housing.
Changing optical power moves the best-focus object plane. It does not automatically increase depth of field: several object heights within one exposure can still require different focus settings.
For the broader distinction between focusing mechanisms and camera movement, see autofocus and image stabilization explained.
Choose the control method from the information available
Distance-based control maps a measured or commanded object position to a focus setting. Image-based autofocus evaluates captured images and adjusts focus toward a selected sharpness criterion. A hybrid starts from a distance estimate and makes a limited image-based correction.
| Control method | Information required | Main advantage | Main limitation |
|---|---|---|---|
| Calibrated distance-based control | Object distance or a reliable part-height recipe | Avoids a broad image search during each cycle | Distance errors and calibration drift become focus errors |
| Image-based autofocus | A usable image region with focus-sensitive detail | Selects focus from the actual image | Requires trial images and can follow the wrong feature |
| Hybrid control | Approximate distance plus a suitable image region | Restricts the search around a likely setting | Retains calibration and image-quality dependencies |
A height measurement can provide feedback about the object while the focus actuator remains open-loop. Unless you also verify the optical outcome, the system does not know that the commanded setting produced a sharp image.
Distance-based control fits repeatable fixtures, known product recipes and predictable height changes. Image-based control fits uncertain object positions when suitable detail remains visible. A hybrid is useful when distance estimates are imperfect but a full-range search would consume too much time.
Do not select the method solely from an actuator response figure. The complete control loop determines inspection throughput and reliability.
Check the complete optical assembly before choosing parts
Confirm sensor coverage, mount, clear aperture, usable wavelength band and focus range for the complete assembly. Mechanical fit alone does not establish optical compatibility. A restriction inside the assembly can reduce corner illumination or usable aperture.
Use the active sensor dimensions rather than treating an optical-format label as a physical measurement. The sensor-format guide explains that distinction. Also check mount spacing and clearance before selecting adapters.
As an independent planning example, suppose the active sensor width is 8.8 mm and the required object width is 110 mm. The required magnification is:
The focal-length estimate assumes an ideal thin lens with an object distance of 400 mm from its principal plane. A housing-based working distance is only an approximation to that distance. This calculation establishes an optical starting point, not a liquid-lens drive setting.
Repeat the coverage check at both distance extremes. Refocusing can change effective magnification, distortion and usable field of view. The focal-length selection guide provides the underlying selection method; the lens finder helps organize candidate optics.
Budget from the command to the usable inspection image
Electrical command completion, optical settling and image availability are different events. A driver acknowledging a command does not prove that the image has reached its final focus.
A conservative sequential timing budget is:
Consider a hypothetical station operating at 10 inspections per second. Each inspection has a 100 ms budget. Suppose distance acquisition takes 8 ms, command latency 2 ms, verified optical settling 25 ms, exposure 3 ms, and transfer plus processing 35 ms.
These are application assumptions, not specifications for any catalog product. Some operations may overlap, but count that benefit only after verifying the actual sequence.
An image search can cost substantially more. If each trial requires 25 ms settling, 3 ms exposure and 12 ms readout plus scoring, five trials consume 5 × 40 = 200 ms. That excludes any additional return to the selected setting and final inspection exposure.
Test the largest required focus jumps in both directions. Small adjustments near the current focus do not establish performance across the entire operating range.
Calibrate distance-based control across operating conditions
Build the focus mapping with the actual camera, optical assembly, aperture and illumination. Record object distance, focus command, temperature and an image-quality result at each calibration point.
A useful commissioning sequence is:
- Select a stationary target containing detail representative of the inspection task.
- Find the best usable focus at the nearest and farthest required positions.
- Add intermediate calibration points wherever interpolation produces unacceptable focus error.
- Repeat selected points after approaching from both command directions.
- Check the mapping after warm-up and across the intended operating temperatures.
- Validate separate distances that were not used to build the mapping.
Calibration spacing should follow focus sensitivity, not a convenient equal-distance grid. Nearer object positions can demand larger optical-power changes for the same physical movement.
For an idealized example, hold image distance at 0.04 m. Focusing an object at 0.20 m requires equivalent power of 1/0.20 + 1/0.04 = 30 diopters. At 0.50 m, the equivalent power becomes 1/0.50 + 1/0.04 = 27 diopters.
The difference is 3 diopters for this simplified system. It is not a required tuning range for a particular liquid element: the surrounding optical layout determines that relationship.
Temperature compensation also needs system-level validation. A driver may compensate its own component without correcting every thermal change in the lens assembly or camera mount. Use the diagnostic approach in camera focus drift with temperature to separate likely causes.
Make image-based autofocus search the right feature
Select an image region containing the feature that must pass inspection. A sharp fixture edge can otherwise dominate the score while the part surface remains blurred. Keep the region attached to the part when its position changes.
Stabilize illumination and exposure during the search. Changing brightness, clipping or noise can alter a sharpness score without improving optical focus. If automatic controls remain active, verify their interaction using the principles in automatic iris, exposure and gain control.
A practical search begins with a bounded command range. Use a coarse sweep to locate a promising region, then refine within that region. Record the final command and confidence indicators rather than returning only a success flag.
The focus-metric selection guide covers scoring choices. Here, the key requirement is control behavior: define what happens when the target lacks texture, glare saturates the region, or the best score occurs at a search boundary.
For example, a five-position search ending at its upper boundary has not demonstrated a peak inside the allowed interval. The controller should report that condition, follow a validated recovery sequence, or reject the inspection. It should not silently treat every completed search as successful focus acquisition.
Verify measurement repeatability separately from sharpness
A sharp image is necessary for many measurements, but it does not establish a constant pixel-to-length relationship. Refocusing can change magnification and distortion, while object-height changes introduce additional geometric effects.
Suppose a hypothetical calibration gives 0.050 mm per pixel at one focus state and 0.051 mm per pixel at another. A feature spanning 400 pixels represents 20.0 mm in the first state and 20.4 mm in the second. Applying the first scale to the second image introduces a 0.4 mm error despite sharp edges.
This example illustrates calibration sensitivity, not an expected error for liquid lenses. Measure the actual change across your operating range.
For dimensional inspection, choose and validate one of these approaches:
- Maintain a single qualified object plane and focus state when the process allows it.
- Store separate geometric calibrations for discrete, repeatable focus recipes.
- Validate a distance-dependent calibration model across intermediate distances.
- Evaluate a metrology-oriented optical arrangement when perspective sensitivity dominates the error budget.
The image-marker calibration guide explains geometric scale checks. The object-space pixel-size guide helps relate sampling to the measurement requirement.
Use an independent reference feature to verify the final result. Repeating the same sharpness measurement used during autofocus does not independently validate dimensional accuracy.
Compare against a fixed-focus baseline
Before committing to active focusing, test whether fixed focus and sufficient depth of field already meet the requirement. A smaller aperture may help, but it requires an exposure and diffraction tradeoff. It does not provide unlimited depth coverage.
The following catalog examples are fixed machine-vision lenses, not liquid-lens assemblies. They provide reference points for conventional optical selection; neither listing establishes compatibility with an added liquid element or driver.
The LS-FFL-0679 is a fixed-lens candidate for evaluating a conventional imaging layout. Select it only after checking its catalog specifications against the application.
- Type
- Machine vision fixed
- Sensor format
- 2/3"
- Mount
- C-mount
- Resolution
- 6-10 MP
The LS-FFL-0567 offers another fixed-lens reference. Its listing should likewise be assessed independently rather than treated as approval for an active-focus accessory.
- Type
- Machine vision fixed
- Sensor format
- 1.1"
- Mount
- C-mount
- Resolution
- 16-25 MP
Compare candidates through the machine vision lenses category. For the imaging side, use the area scan cameras category and camera finder to check sensor format, mount, shutter and interface requirements.
Liquid lens autofocus may be the wrong choice when several widely separated depths must remain sharp in the same exposure. It may also be unnecessary when a fixture can hold the inspection surface inside a validated depth band. Reconsider the arrangement if focus-dependent geometry consumes too much of the measurement tolerance.
Acceptance checklist before ordering
Write acceptance criteria for the complete station, not just the focusing component:
- Distance coverage: demonstrate usable inspection detail at the nearest, farthest and intermediate object positions.
- Image coverage: inspect center and corner performance, including illumination falloff and field changes during refocusing.
- Timing: measure command-to-usable-image delay for the largest required focus transitions.
- Repeatability: revisit the same distances from different starting settings and compare the inspection outputs.
- Temperature behavior: verify cold-start, warmed-up and intended operating conditions without assuming one calibration covers them all.
- Search failure handling: detect missing texture, saturated regions, boundary solutions and unavailable distance readings.
- Measurement accuracy: check an independent dimensional reference at every qualified focus recipe or modeled distance.
- Integration: confirm driver requirements, supported commands, electrical compatibility and synchronization with exposure.
For repeated validation, a starting test could include 30 captures at each required distance, followed by additional testing where the observed spread approaches your acceptance limit. That sample count is a commissioning aid, not proof of long-term process capability.
Begin the optical layout in the lens configurator. For active-focus evaluation, send the distance range, sensor dimensions, required field of view, cycle time and measurement tolerance through application support so the complete assembly and control requirements can be reviewed.
Questions
Does a liquid lens autofocus system need a distance sensor?
Distance-based control uses a calibrated relationship between object position and focus command. Image-based autofocus evaluates captured detail and searches for a suitable setting. A liquid lens can support either approach, but it does not determine the control strategy by itself. The available distance information and capture-time budget guide the choice.
Can a liquid lens be added to an existing machine vision lens?
Mechanical attachment does not establish optical compatibility. The liquid element’s aperture, optical position, tuning range and aberrations must work with the surrounding lenses and sensor. Evaluate a documented complete assembly or obtain an application-specific compatibility review rather than assuming an accessory will preserve the original lens performance.
How long should the camera wait after a focus command?
Allow enough time for the optical image to meet your inspection criterion after the focus command. Command acknowledgments and electrical response figures are not substitutes for that test. Measure the required delay across large transitions, both command directions and the intended temperature range before setting the exposure trigger.
Will dimensional calibration remain valid after refocusing?
Not necessarily. Refocusing can change magnification and distortion, and changing object height can alter the measurement geometry. Validate dimensional accuracy independently of sharpness. Depending on the tolerance, you may need separate recipe calibrations, a validated distance-dependent model, or a different optical arrangement.
When is fixed focus preferable to liquid lens autofocus?
Fixed focus is often preferable when the inspection surface stays within a qualified depth band and meets image-quality requirements without adjustment. It removes focus-command timing and search failure modes. Compare both approaches using the required exposure, smallest relevant feature and measurement tolerance rather than choosing active focus automatically.

