Jools Hudson at Gardasoft Vision writes that to achieve reliable images needs careful design of lighting control
Experienced designers know that to get great results from a machine vision system you must get a great image. No amount of software processing can recreate data that hasn’t been captured on your camera sensor, and to get that perfect image, time after time, you must have accurate and consistent lighting control. Most machine vision systems use an LED illumination source with one of three drivers: a simple voltage drive, voltage-drive with pulse width modulation (PWM) or a constant-current drive. Simple voltage drive can be the cheapest option but it has significant practical disadvantages due to the way LEDs function. Although LED lights are often specified by voltage, it is actually the current flowing through the light that dictates the brightness obtained and not the supply voltage. As you can see in diagram 1, a tiny change in voltage creates a much bigger change in the current flowing, and the change in current creates a large change of brightness. This important effect means that simple voltage drive cannot be used to accurately adjust lighting intensity. In addition, any fluctuations in the system supply voltage may cause fluctuations in lighting levels.
PWM voltage controllers provide limited intensity control by pulsing the light on and off so that the average intensity is approximately what’s needed. To increase brightness, the light is simply pulsed on for longer. However, PWM also has practical disadvantages. The speed of the PWM cycles dictates how many intensity steps are available for adjustment and it’s usually limited to about 100 coarse levels. The PWM pulses are usually independent of exposure timing which can cause intensity variations between exposures, particularly for fast systems. Diagram 2 shows an example where the timing of the camera exposure and PWM pulses results in the first exposure receiving more than 30 per cent more light than the second exposure. A faster internal PWM clock can reduce this effect, but these high-speed voltage pulses can cause EMC interference in neighbouring systems.
Diagram 1: Relationship between voltage, current and intensity of LED lighting
Constant-current controllers are usually the best choice of lighting drive for LED lighting. They directly adjust illumination levels by accurately controlling the current flowing through the light. There is no fundamental limitation on the number of adjustment steps and a typical Gardasoft controller will provide 3,600 steps of brightness with no risk of EMC interference.
Strobing and overdriving
Continuous illumination can be adequate for some applications. Usually, a light will be set up to below 100 per cent brightness so that illumination can be increased later if needed. Both voltage-drive and constant-current controllers can drive continuous illumination. However, one well-known effect is that as an LED light heats up, the illumination intensity will fall. This effect is often minimised by using the ability of LEDs to be pulsed on briefly so that the light is only illuminated while the image is captured. Pulsing the light prolongs the life of the light, which will degrade with on-time. Pulsing is also an important technique to prevent image blur on fast production lines. Effective strobing relies on obtaining consistent and repeatable square light pulses with rapid rising and falling edges. Sharp edges are more difficult to achieve with a PWM controller, particularly if there is a long cable between the controller and the light. If the pulse edges have a poor profile, the intensity of the illumination is likely to vary between exposures. Constant-current lighting controllers are inherently able to create accurate, repeatable square pulses with sharp rising and falling edges.
Diagram 2: How PWM can cause variable brightness
A powerful extension of strobing is overdriving, where a current higher than the maximum rating is driven through the LED light. This short pulse can produce much brighter illumination than the maximum specified by the device manufacturer and will not damage the light when a good strobe controller is used. A quality strobe controller will carefully manage the frequency, pulse duration and current to prevent heat build-up that could damage the light. Only constant-current controllers can achieve a safe and accurate overdrive. Voltage-based lighting controllers including PWM versions that supply a standard 24V cannot overdrive lights and those that offer the option of an additional, higher voltage suffer from an unpredictable discontinuity in brightness between the two voltage levels. Most constant-current controllers can operate with complete flexibility in either continuous, strobe or overdrive modes.
High-speed lighting control
Certain applications must have very short camera exposures. High-speed inspection lines and systems using a single imaging station to capture multiple images will need short exposures. Line scan applications also use short exposure times which need precision lighting control. Some more advanced PWM systems offer the ability to synchronise the PWM cycle with the camera shutter to avoid the issues shown in diagram 2, but this can be difficult to implement in practice. Constant-current lighting controllers offer much more flexibility at high speed because they allow the intensity and duration of lighting to be precisely adjusted and are not tied to a PWM cycle.
Author: Jools Hudson, Gardasoft Vision Ltd, Trinity Court, Buckingway Business Park, Swavesey, Cambridge, CB24 4UQ, UK; Tel: +44 1954 234970; E-mail: vision@gardasoft.com; Internet: www.gardasoft.com