Precision lens manufacturer for machine vision, medical, and industrial imaging applications.

Focus Hunting at Shift Start: Split Thermal Drift From the Control Loop

Home - Technology Explainers - Focus Hunting at Shift Start: Split Thermal Drift From the Control Loop
Reading Time: 6 min ( Word Count: 1,532 )

Two different faults produce the same morning image, and they are fixed in different places. Hunting, where the lens searches back and forth around focus, is a control-loop problem: the step size, the update rate, the region of interest, or a low-contrast target the search cannot settle on. Drift, where focus moves slowly while the command value stays the same, is thermal: the liquid cell’s focal power changes as the cell warms up. Split the two with one test. Hold the command fixed at working temperature and watch the focus; if it oscillates, it is the loop. Then log the focus against temperature across a shift; if it walks away steadily, it is the cell. Only after that split does it make sense to ask the lens maker for a temperature-calibrated control package, because half of the packages sold for this problem fix the wrong half.

Hunting and Drift Are Two Faults With One Symptom

The first test costs nothing and needs no new hardware. Set the lens to a fixed command value at the working distance and leave the loop alone. If the focus measure oscillates around a mean that is not moving, the problem is the loop or the target, not the optics. Usual causes sit on the integration side: a search step that is too coarse for the depth range, an update rate fighting the exposure, a region of interest that includes low-contrast background, or illumination that flickers at a frequency the search reads as contrast change. A printed reference target with hard edges and stable light removes most of it, and if the oscillation disappears with the target changed, the lens was never the fault.

If instead the focus holds steady for a minute and then walks in one direction as the cell warms, the fixture is not at fault. Liquid lens cells change focal power with temperature, and on an uncalibrated drive a constant command value no longer means a constant focus position. The test that separates this from anything mechanical is a temperature log: record the focus measure and the cell temperature every few minutes for an hour or two from a cold start. A smooth curve that flattens as the cell reaches equilibrium is thermal behaviour, and it is exactly what the calibration pack is for. A step change that follows a mechanical event, such as a cable being touched or a bracket being knocked, is not.

What the Maker’s Calibration Pack Should Contain

Once the drift is confirmed as thermal, the ask is specific. Liquid lens focus on the ZWA series is electrowetting: the shape of the liquid interface is changed by voltage, with no moving parts, and focus settles in about 20 milliseconds. That mechanism is fast because it is electrical, and it is also the reason the drive has to be temperature-aware. The package that fixes the drift holds:

  • A calibration file or table for the lens, identified by serial number, mapping temperature and drive value to focal power. A generic curve for the model is not the same thing, because the fill and the cell vary unit to unit.
  • The temperature sensor’s location, accuracy and response time. A sensor that reads the housing rather than the cell, or that lags the cell by minutes, will correct for a temperature that was true ten minutes ago.
  • The supported temperature range, stated in numbers, and what the maker expects at the ends of it.
  • The control mode the lens supports and the command units. If the driver can accept focal power in dioptres rather than a raw voltage or DAC count, the integration becomes a table lookup instead of a fitting exercise.
  • Behaviour after power cycling, and the repeatability of focus at a fixed command and fixed temperature.

The background to the mechanism, for engineers who want the physics rather than the datasheet, is set out under electrowetting. The delivery format matters as much as the content: ask for the calibration as a file with a version number, so that a lens swap does not leave the station running on the previous unit’s numbers. The ZWA liquid lens family is the place to start if your application needs focus that cycles faster than a mechanical stage can move.

Electrowetting liquid autofocus lens standing on a bench before calibration

The Warm-Up Gate on the Line

Thermal drift is not fully removable, and the practical answer on the line is a warm-up gate. The cell reaches equilibrium in a predictable time, and until it does, the focus position for a given command is still moving. A gate is a documented interval at the start of a shift: the station runs against the reference target until the focus measure is stable inside the agreed band, and only then does production start. Parts inspected during the window are either re-inspected after the gate or held aside. The gate turns an unexplained morning argument into a schedule item, and it costs a few minutes once per shift instead of a false rejection later.

The gate only holds if it produces a record. One line per check is enough: time, cell temperature, command value, and the focus measure against the reference target. The log belongs with the station, not with the operator, because its value is in the comparison across weeks. When the focus measure at the same temperature starts to differ from the first month’s entries, that is the moment to re-run the calibration rather than to accept a slow decline. Write the gate’s pass band into the station’s work instruction at the start, with what to do when the check fails: stop, clean the reference target, repeat; if it still fails, swap the lens and run the calibration file for the replacement. An operator who knows the two-step answer will use it, and the shift starts on time instead of waiting for an engineer.

One Shift-Length Test as the Handover

Before accepting a calibration pack, run it once for a full shift on one station and keep the output. The test is the same log as the gate, extended across a whole shift with the drift correction active, and judged against a tolerance you and the maker agree in writing. The value of doing it once properly is that the acceptance is then a comparison rather than an opinion, and the same run becomes the station’s baseline for every later check. If the pack does not hold focus through a shift on the bench, it will not hold it on the line, and the disagreement costs one test day rather than a rejected production batch.

What Temperature Correction Does Not Fix

A calibration pack corrects the lens, and the machine around the lens also moves. Camera brackets, the workpiece fixture and the frame itself grow and shrink with the room’s temperature, and a focus correction that only reads the cell will happily hold the cell steady while the object plane walks away from it. The symptom looks the same in the image and different in the log: with the cell temperature flat and the calibration active, the focus measure still drifts. The way to catch it is a second temperature reference in the room or on the fixture, recorded in the same log, and a check on a fixed artefact that never leaves the station. If the artefact needs a focus change at a constant cell temperature, the thermal problem is mechanical, and the answers are a stiffer or shorter mount, or letting the whole machine reach equilibrium before the gate opens. Buying a finer calibration for the lens does nothing for either.

When the Lens Is Swapped

Calibration belongs to the unit, so a replacement lens arrives with its own file and a new serial number that goes into the station record. The swap procedure should be written before the first spare is needed: replace the lens, load the new calibration by serial, re-run the reference target check, and repeat the shift test for the first day. Skipping the shift test after a swap is how a station quietly drifts for weeks while every individual part looks acceptable and the outgoing quality record still shows green. Two practical rules make the procedure stick. Keep one spare lens per critical station rather than a shared pool, so the calibration file and the unit stay together. And write the swap into the maintenance plan with the check that follows it, because a swap that happens during a breakdown is a change nobody records.

Order Lines for the Next Batch

Four lines carry the whole arrangement. The calibration pack per serial number, with version and units. The supported temperature range and the focus tolerance inside it, in numbers. The temperature sensor’s location, accuracy and response time. And the shift-length acceptance test, with the log format agreed so that your line record and the maker’s acceptance use the same fields. If the application also needs a fixed-focus option, the honest comparison between the two is worth running before the next order, and the family overview under fixed-focus FA lenses shows what an autofocus cell is bought to improve. With the four lines in the order, the next morning the line starts soft is a chart check rather than a phone call.

Baker Zhao

Baker Zhao

Founder, Lensmind Optics

Baker Zhao is the founder of Lensmind Optics, with 26 years of experience in the optical industry — including Vice President of Sales at Sunny Optical (Zhongshan) and earlier roles at Foxconn, LG and Sintai Optical. He leads Lensmind with a mission to help customers find reliable, application-specific optical solutions from development to volume production.

Leave a Comment