Choosing lighting for machine-vision inspection
Careful selection of dedicated lighting based on a few key factors can improve repeatability, reliability, and accuracy
BY BRENT EVANGER
Banner Engineering
Minneapolis, MN
http://www.bannerengineering.com
In search of cost-effective quality control solutions, many engineers employ machine vision equipment. Sometimes overlooked is the fact that such equipment, which may have outstanding performance specifications, still requires sufficient lighting to obtain accurate results. A dedicated lighting configuration allows vision sensors to yield high-contrast images that dramatically improve the repeatability, reliability, and accuracy of a visual inspection (see Fig. 1 ).
Fig. 1. Dedicated lighting offers numerous techniques and configurations able to meet diverse application requirements, such as those for PCB inspection.
Engineers can determine the ideal lighting technique and configuration for their application by considering the target object/feature of interest, as well as the plant environment and the mounting requirements.
It’s all in the technique
Lighting solutions use three main techniques — or three different arrangements of how the light is positioned relative to the target object. Each method offers distinct advantages.
In the first lighting technique, backlighting, the light source is located behind the target object, with the light directed into the camera. Backlighting delivers the highest contrast of the three lighting techniques, but requires space behind the part to mount the light (not possible in some setups).
When the light source is positioned to shine perpendicular to the object, the most common lighting technique is being employed: bright-field illumination. Bright-field lighting is easy to set up but such installations can suffer from lighting “hot spots” or glare, especially if the target part is shiny or has a smooth finish.
In dark-field illumination, on the other hand, the light source is positioned at a low angle relative to the camera. This setup causes the light to reflect off the smooth surfaces of the target object, away from the camera. In this way, the object is lit indirectly. Only raised or lowered features stand out when this lighting technique is used: flat portions of the part appear dark in the image.
The object of your inspection
The optical properties of the target object/feature of interest are the most important factor in selecting a lighting strategy for a vision application. Consideration should be given to the target object’s shape, texture, color and translucency. Understanding and exploiting what differentiates the target object from the background is crucial to creating contrast and securing an accurate inspection.
Lighting based on shape is one of the most common ways to solve applications. Shape includes change in height, width, length or edge features. Since backlighting creates the highest contrast, producing a binary image that is easy to process, engineers should first consider this technique for applications that rely on the optical property of shape (see Fig. 2 ).
Fig. 2. The highest contrast lighting technique, backlighting provides even illumination and is ideal for inspecting translucent materials, such as bottles.
In addition to selecting a lighting technique that will detect irregularities in shape, engineers should consider the need for highlighting differences in the target object’s surface texture, such as flaws or other features including cuts, embossing, scratches and difference in surface finish. For inspections that focus on surface texture, backlights, which aren’t affected by changes in texture, shouldn’t be used. Instead, a dark-field lighting technique can be employed.
Dark-field lighting causes the smooth surfaces of an object (perpendicular to the camera) to appear dark, and is useful in making surface defects, raised or lowered features and textures to appear bright. Area lights, a source of dark-field lighting when positioned correctly, provide even illumination in a concentrated area.
Additionally, these lights can be mounted at any angle to provide a solution for many otherwise challenging applications. Light rays are reflected differently by various surface textures. While smooth, flat surfaces reflect away from the lens, diffuse surfaces reflect a portion of the light rays into the lens. To effectively use this technique, engineers should experiment with placing area lights at different angles from the target object.
To differentiate one color from another — a capability that proves valuable in many vision inspection applications — contrast must be established between a correct and incorrect color, instead of an object and its background. Many times this sort of lighting problem is solved with a well chosen colored ring light.
A type of bright-field lighting, ring lights surround the camera lens, directing light straight to the target object and creating even illumination of the surface so that the vision sensor can accurately detect the color of the object. Useful for providing general diffused illumination over a small area, colored ring lights can also be used to create contrast between color differences in various parts of an object.
When a light source color is similar to the color of the target object, it will make the part appear brighter. On the other hand, when a light source color is complimentary to the color of the part, the part will appear darker. Because of this, colored lights and/or colored lens filters can create the necessary contrast.
Translucency refers to the object’s ability to transmit light. Since detecting the presence of translucent portions of a part can be difficult with a bright-field light, a backlight should be used for these applications.
In backlighting, the highest-contrast lighting technique available, the light source is positioned behind the object, shining directly into the camera, causing only transparent features (like holes) to be visible. A polarizing filter can also be used with a backlight, particularly when the objective is to detect flaws in otherwise clear materials.
Consider your environment
In addition to the properties of the target object, consideration should be given to certain aspects of the surrounding plant environment. Inconsistent lighting from ambient fluorescent bulbs as well as windows or skylights interferes with the repeatable contrast needed for accurate vision sensing.
Inspection failures due to inconsistent lighting conditions can be eliminated by either suppressing the ambient light or shrouding the inspection area. The first method involves using a light source much brighter than the ambient light, and placing it in close proximity to the target object, which can be accomplished through the dedicated lighting techniques described above. Additionally, the effects of ambient light can be suppressed by use of filters.
The second method involves mechanically shrouding an inspection area. This is accomplished through positioning a physical barrier between the ambient light source and the inspection area. An area can be shrouded with an opaque material such as a steel plate or a semitransparent material such as a tinted polycarbonate.
All lighting equipment should be rated according to the environmental requirements, such as dust and dirt, as well as washdown. For example, high-frequency tubular lighting rated NEMA 4, IP67 can be used in harsh environments, and numerous additional options are available for diverse requirements (see Fig. 3 ).
Fig. 3. Selecting properly rated lighting products is key to ensuring long life and safety in harsh environments, such as demanding washdown applications.
Mounting requirements
Even when a dedicated lighting technique provides the capabilities required by a specific application, mounting requirements may make it impractical for that particular application. For example, while backlighting provides ideal contrast for many applications, placing the light behind the target object may be physically unfeasible. Backlighting also requires the area of illumination to be larger than the area of inspection, which may not fit the parameters of some setups.
Low-angle lights — a dark-field technique that directs light nearly parallel to the imaged surface of the target object, casting shadows that emphasize changes in elevation and enhancing the contrast of surface features — can also pose logistic problems for some applications. These lights must be set up with the light source close to the target object, which may be impossible in some vision inspection layouts.
While mounting restrictions prevent certain lighting techniques from being used in restrictive applications, engineers can select a configuration that better meets their requirements, such as ring lights. These lights provide even illumination for small objects and can be mounted directly on the sensor, providing a viable option when space is at a premium.
Dedicated lighting can guarantee constant, consistent conditions that can be manipulated to create a high-contrast image for vision inspections. By considering the optical properties of the target object as well as the environmental and mounting requirements, a lighting configuration can be determined to best meet an application’s needs. ■
Learn more about Banner Engineering