Capture and process camera data
Knowing how a frame grabber works will help you choose the best one for vision applications.
Jon Titus, Editorial Director -- Test & Measurement World, 4/15/2002
|
Ask most people involved with machine vision what a vision system comprises and they'll tell you a camera, a computer, and software. There's another key component—the frame-grabber board—that deserves attention. This board plugs into a computer and connects one or more cameras to the computer's main bus. Because this board converts analog signals into the digital information that machine-vision software will process, it plays a key role in ensuring a vision system has good data to work with.
In addition to acquiring image data, frame grabbers provide other I/O functions such as triggering a camera, turning lights on and off, and communicating with programmable logic controllers (PLCs). Input lines can sense external on/off events such as the arrival of a product at the proper position for image acquisition.
![]() |
| Figure 1. The Data Translation DT3162 provides a complete frame grabber that puts out several camera-control signals that let the board work with a variety of camera types. This board streams its data to main memory over the PCI bus. Courtesy of Data Translation. |
Frame-grabber boards (Figure 1), usually just called frame grabbers, come in several varieties. These boards differ in the types of cameras they work with and how they manipulate image data prior to sending it to a PC's main memory. But no matter what type of camera signal a frame grabber accepts or how it gets data to a PC's memory, it still has one main function: to convert an image into useful data.
Most area-scan monochrome cameras used in machine-vision applications put out standard analog NTSC or PAL signals that connect directly to a frame grabber. The frame grabber's front-end circuits filter out extraneous information and separate timing signals from video signals. One of the timing signals, called horizontal sync, works with a phase-locked loop (PLL) to recreate an accurate pixel clock on the board. This clock synchronizes the frame grabber's operations with the video data coming from the camera. In particular, the pixel clock determines when the frame grabber's analog-to-digital converter (ADC) will digitize the video portion of the camera's signal. You can set up the PLL circuit to provide the correct timing for the ADC for a specific camera type. Each analog-to-digital conversion produces a digital value for a single pixel in the received image. For an 8-bit ADC, the pixels range from black (0) to white (255) along a gray scale.
In general, frame grabbers offer either 8-bit or 10-bit resolution. Some provide both and let you choose which resolution to use. Most machine-vision applications operate nicely with 8-bit data, although some metrology applications that use subpixel measurement techniques can benefit from the higher resolution. For this article, I'll assume 8-bit pixel data.
Because a frame grabber that processes analog signals relies on reconstructed timing information, the board's circuits can introduce errors in digitized data. Two types of errors, rms noise and nonlinearity, arise from the analog electronics. The rms noise represents the electrical noise produced in all electronic circuits. For a frame grabber, an rms noise value of less than 0.7 LSB is very good, and an rms noise value of less than 0.5 LSB is deemed excellent (Ref. 1).
Nonlinearity errors appear as digitization differences between standard gray-scale values "seen" by a camera and the values actually produced by the frame grabber's ADC. Good design can keep nonlinearity values under 0.5 LSB.
![]() |
| Figure 2. To properly convert an image signal, a frame-grabber’s ADC must sample close to the middle of each pixel’s signal. A small amount of jitter in the ADC’s timing can introduce digitization errors. (Signals exaggerated to show details.) |
Although most machine-vision applications in the electronics industry rely on monochrome cameras, some applications require the use of color cameras. The frame grabbers used with color operate in a similar fashion, but they provide three ADCs, one per color—red, green, and blue. So, the same concerns about pixel jitter and noise apply to the frame grabbers used with color cameras. Keep in mind, though, that the three ADCs produce three bytes per pixel, so the interface for a single color camera takes three times as much circuitry as that for a monochrome camera. And each color pixel takes three times as much memory.
Cameras perform conversionsTraditionally, monochrome and color machine-vision systems have relied on analog signals to transmit video information from cameras to host computers. But the ambient electrical noise present in industrial facilities can disrupt those signals. To help alleviate the noise problem, camera manufacturers have started to transfer some frame-grabber functions from the host computer to the camera itself. Thus, many newer camera perform analog-to-digital conversions close to the image sensor to help eliminate timing errors and reduce the effects of ambient noise. Unlike the NTSC or PAL signals that require only a single coaxial cable, digital-camera transmissions require a set of parallel wires.
Cameras that perform their own analog-to-digital conversions carry a higher price tag, but they still require a frame grabber to serve as a simple digital interface to a PC. Such a frame grabber acquires the digital data from the camera—usually sent as low-voltage differential signals—and reassembles the bits into bytes that represent pixels in the original image.
Some camera manufacturers have adopted the Camera Link standard that further simplifies camera-to-PC connections. The Camera Link standard mandates a specific type of connector and cable, so vision systems no longer need expensive custom cables. This standard provides for several types of transmissions and specifies the signals used for data and camera control (Ref. 3). As a result, a Camera Link camera should easily connect to any Camera Link-compatible frame grabber.
Thanks for some memory
![]() |
| Figure 3. National Instruments PCI-1409 frame grabber can work with as many as four video sources. The board’s ADC offers either 8- or 10-bit resolution, and the board can store 16 Mbytes of image data. Courtesy of National Instruments. |
Whether or not you choose a frame grabber with onboard memory depends on how fast you need to get images to a host computer's main memory. If you have an application that taxes the PC's bus, or that doesn't need immediate access to an image, you might choose to temporarily store the image data rather than put it on the bus as soon as it arrives from a camera.
Applications that can tolerate some latency between acquiring an image and processing it may route image data into onboard memory and later transfer it to main memory all in one block rather than in small pieces. Or, an application could set up the memory to act like a first-in, first-out (FIFO) buffer. As the onboard memory accepts new data, the memory pushes the previous image onto the bus.
Look up pixel valuesIn addition to temporarily storing data, some frame grabbers can process pixel data prior to transferring it to a PC's memory. This "preprocessing" takes some of the image-processing burden off the host CPU. One of the simplest processing tasks involves altering the contrast in an image. Assume you have adjusted light sources to get the best possible range of gray-scale values in images of electronic assemblies you want to inspect, but in each image, the assembly still looks too dark. In effect, the image contains pixel values "compressed" at the black end of the gray scale.
![]() |
| Figure 4. a) Due to imaging conditions, pixels may cluster within the gray scale; in this example, they cluster at the black end. b) Using a LUT to spread the pixels across the entire gray scale will ease the task of locating details in an image by enhancing the differences between gray levels. In effect, the LUT operation gives machine-vision software a larger range of pixel values to work with. |
You also could use an LUT to produce binary—black-or-white—pixels in an image. Pixels with gray-scale values equal to or less than a threshold you set get translated to black, and pixels with values greater than the threshold get set to white. The resulting image contains only black and white pixels. Such images lend themselves to pixel-counting applications that can detect changes from one image to the next (Ref. 4). Those changes could signal a missing component or an extra component. You use machine-vision software that comes with a frame grabber to calculate and set up the LUT values. Even though a frame-grabber board comes with an LUT, you don't have to use it.
This sort of simple onboard processing can improve image contrast, reduce noise, and perform other simple tasks. By increasing the quality of the image as pixel data passes through a frame grabber, the board can help reduce false failures detected by the PC's machine-vision software. In most cases, the onboard processing takes less time than an equivalent operation in an application program.
Add a real processorYou also can buy frame grabbers that include general-purpose processors, field-programmable gate arrays (FPGAs), or specialized image-processor chips. Once programmed, these devices can perform complicated operations such as convolutions and correlations, feature extraction, edge detection, and so on. Performing some or all of the image-analysis tasks right on the frame-grabber board reduces the software burden that would otherwise fall on the host PC. And some production lines move too fast for PC-based application programs to keep up with them.
Continuous sheets of product—often called a web—move rapidly, and a machine-vision system must detect defects immediately. In a web-type inspection system, a frame grabber, working with a line-scan camera, builds a continuous image a line at a time and processes the image on the fly. Applications such as the high-speed high-resolution inspection of semiconductor wafers or the continuous monitoring of sheet film or sheet metal require an onboard processor.
Manufacturers may provide processing functions on a frame-grabber board or as add-on daughter cards. And some suppliers refer to programmable frame grabbers as accelerator boards, so be aware that a board given the "accelerator" label also may process images without needing to interact with a host PC. To further confuse the nomenclature, note that not all frame grabbers that include an FPGA or other programmable device can process pixels on the fly. Manufacturers may provide an FPGA to let a frame grabber reconfigure camera settings, bus-control logic, or other settings.
![]() |
| Figure 5. The onboard Xilinx FPGA (white IC) on the Datacube MaxRevolution board gives users the opportunity to develop image-processing software that runs without interaction from the host PC. The FPGA can offer a speed advantage in high-speed image-acquisition and image-processing applications. Courtesy of Datacube. |
The XSYS Smart Framegrabber from PLD Applications provides access to the onboard complex programmable logic device (CPLD) that controls operations. Developers can adapt the CPLD to handle special-purpose operations or to apply algorithms to image data. But doing so requires knowledge of the CPLD's architecture and access to programming tools, available from Altera (San Jose, CA; www.altera.com), the CPLD chip vendor. PLD Applications will, however, help OEMs with custom applications.
Not everyone needs an onboard processor, though. Computers with lots of memory, dual Pentium processors, and high-speed buses can tackle all but the most demanding image-processing and machine-vision tasks.
End users: Buy a packageIf you're not an OEM or a system integrator, consider buying frame-grabber boards and software from the same vendor. By buying a "package," you'll ensure the hardware and software will "plug and play." Frame-grabber suppliers want buyers to get machine-vision systems up and running quickly—nothing beats testing hardware and software under real conditions. High-level development tools often let you quickly configure an application so you can test the frame-grabber board, the camera, and lighting setups.
Software tools sold by frame-grabber suppliers ease application development by providing menu choices, drop-and-drag application tools, and configuration wizards. Developers can concentrate on lighting, contrast, image sizing, and so on, rather than on how to pass arguments to algorithm libraries. If developers want to use C, C++, or Visual Basic, they'll find a variety of ActiveX controls, dynamic-link libraries (DLLs), and other routines bundled with most high-level machine-vision tools (Ref. 5).
During your deliberations, look at each supplier's line of frame grabbers. One type of board may meet today's needs, but you may need more powerful boards, or boards for different cameras, in a new application. Frame grabbers in a manufacturer's product line may require different drivers, but using a different type of board shouldn't force you to rewrite a lot of code. The same applications software, function calls, libraries, and ActiveX controls should work across a product line.
As you look at frame-grabber hardware and software, keep the future in mind. In the next few years, you can expect to see increasing adoption of the Camera Link standard, higher image-data bandwidths, and larger image sizes. And as the prices for color cameras drop, you'll find more applications that can take advantage of color images. You want to ensure your supplier recognizes these trends and either already has products that work with large-format cameras, color cameras, or cameras that use the Camera Link interface or has such products in its near-term plans.
For more informationTo locate frame-grabber suppliers, use the online Buyer's Guide at www.tmworld.com and search on the keywords frame grabber.
The following company information appeared in the original print version of this article. For up-to-date information about companies, visit the Frame Grabbers portion of our Buyer's Guide.
| Manufacturers of programmable frame grabbers | ||
| Advanced Products and Design Div. San Diego, CA 858-527-6100 www.titansystemscorp.com/divisions/apd |
Alacron Nashua, NH 603-891-2750 www.alacron.com |
Coreco Imaging Billerica, MA 978-670-2000 www.coreco.com |
| Datacube Danvers, MA 978-777-4200 www.datacube.com |
Euresys Dallas, TX 514-684-3993 www.euresys.com |
i2S Line Scan Niskayuna, NY 888-842-7872 www.i2S-linescan.com |
| Leutrek Vision/Atlantek Microsystems Burlington, MA 781-238-0213 www.leutrek.com |
Matrox Electronic Systems Dorval, QC, Canada 514-822-6000 www.matrox.com |
PLD Applications Aix-en-Provence, France +33-442-393-600 www.plda.com |
| RVSI Acuity CiMatrix Canton, MA 781-821-0830 www.rvsi.com (Click on "Acuity CiMatrix" button) |
||
| References | ||
|
|























