[Overview] Machine vision uses machines to replace human eyes for measurement and judgment. A machine vision system refers to a system that uses machine vision products (i.e., image acquisition devices, which are either CMOS or CCD) to convert the captured target into image signals, which are then transmitted to a dedicated image processing system. Based on pixel distribution and information such as brightness and color, these signals are converted into digital signals. The image system performs various calculations on these signals to extract the target's features, and then controls the equipment's actions based on the judgment results. The main advantage of machine vision systems is that they improve the flexibility and automation of production. In hazardous working environments where manual operation is unsuitable or where human vision is insufficient, machine vision is often used to replace human vision. Furthermore, in large-scale industrial production, manual inspection of product quality is inefficient and inaccurate; machine vision inspection methods can significantly improve production efficiency and automation. Moreover, machine vision facilitates information integration and is a fundamental technology for computer-integrated manufacturing. Because machine vision systems can quickly acquire large amounts of information, are easy to process automatically, and are easily integrated with design and processing control information, they are widely used in modern automated production processes for conditions monitoring, finished product inspection, and quality control. [Basic Structure] A typical industrial machine vision system includes: a light source, lens, CCD camera, image processing unit (or image capture card), image processing software, monitor, communication/input/output unit, etc. The system can be further divided into: host computer, frame grabber and image processor, video camera, CCTV lens, microscope lens, lighting equipment, halogen light source, LED light source, high-frequency fluorescent lamp source, flash lamp source, other special light sources, image display, LCD, mechanism and control system, PLC, PC-Based controller, precision table, and servo motion machine. [Working Principle] The machine vision inspection system uses a CCD camera to convert the target to be inspected into an image signal, which is transmitted to a dedicated image processing system. Based on pixel distribution and information such as brightness and color, it is converted into a digital signal. The image processing system performs various calculations on these signals to extract the target's features, such as area, quantity, position, and length. Then, based on preset tolerances and other conditions, it outputs results, including size, angle, number, pass/fail, presence/absence, etc., to achieve automatic recognition. Machine vision industrial inspection systems, in terms of their inspection nature and application scope, are divided into two main categories: quantitative and qualitative inspection, each further subdivided into different subcategories. Machine vision is highly active in various applications of online industrial inspection, such as: visual inspection of printed circuit boards, automatic flaw detection of steel plate surfaces, parallelism and perpendicularity measurement of large workpieces, container volume or impurity detection, automatic identification and classification of mechanical parts, and geometric dimension measurement. Furthermore, in many situations where other methods are difficult to use, machine vision systems can effectively achieve the required results. The application of machine vision is increasingly replacing humans in many tasks, which undoubtedly greatly improves the level of production automation and the intelligence level of inspection systems. Examples of machine vision applications in quality inspection: Machine vision systems have been widely used in various aspects of quality inspection. For example, a large workpiece parallelism and perpendicularity measuring instrument using a laser scanning and CCD detection system uses a stable collimated laser beam as the measurement baseline, coupled with a rotating axis system, and a rotating pentagram prism to scan mutually parallel or perpendicular reference planes, which are then compared with the surfaces of the large workpiece being measured. When processing or assembling large workpieces, this instrument can be used to measure the parallelism and perpendicularity between surfaces. A dynamic detection system for online measurement of the geometric parameters of hot-rolled rebar is achieved by using stroboscopic light as the illumination source and surface-mounted and line-mounted CCDs as detection devices for the external contour dimensions of rebar. Vision technology monitors bearing load and temperature changes in real time, eliminating the dangers of overload and overheating. It transforms the traditional passive measurement method of ensuring processing quality and safe operation by measuring the surface of ball bearings into active monitoring. Using microwaves as the signal source, square waves with different wave frequencies emitted by the microwave generator are used to measure cracks on the metal surface; the higher the frequency of the microwave wave, the narrower the crack that can be measured. [Typical Structure]A typical machine vision system includes the following five main parts: 1. Illumination: Illumination is a crucial factor affecting the input of a machine vision system, directly impacting the quality of the input data and the application effect. Since there is no universal machine vision lighting equipment, appropriate lighting devices must be selected for each specific application to achieve the best results. Light sources can be divided into visible light and invisible light. Commonly used visible light sources include incandescent lamps, fluorescent lamps, mercury lamps, and sodium lamps. A disadvantage of visible light is that the light cannot remain stable. How to stabilize light energy to a certain extent is a problem that urgently needs to be solved in the process of practical application. On the other hand, ambient light may affect image quality, so a protective screen can be used to reduce the influence of ambient light. Illumination systems can be classified according to their illumination methods: backlighting, front lighting, structured light, and stroboscopic lighting. Backlighting places the object under test between the light source and the camera, and its advantage is that it can obtain high-contrast images. Front lighting places the light source and the camera on the same side of the object under test, which is convenient for installation. Structured light illumination projects gratings or line light sources onto the object under test, and demodulates the three-dimensional information of the object under test based on the distortion they produce. Stroboscopic lighting illuminates the object with high-frequency light pulses, and the camera shooting requires synchronization with the light source. 2. Lens: FOV (Field of Vision) = Required resolution * Sub-pixel * Camera size / PRTM (Part measurement tolerance ratio). Lens selection should consider: ① Focal length ② Target height ③ Image height ④ Magnification ⑤ Distance from image to target ⑥ Center point/nodal point ⑦ Distortion. 3. Camera: According to different standards, cameras can be divided into standard resolution digital cameras and analog cameras, etc. Different cameras and high-resolution cameras should be selected according to different practical applications: line scan CCD and area scan CCD; monochrome cameras and color cameras. 4. Image acquisition card: The image acquisition card is only one component of a complete machine vision system, but it plays a very important role. The image acquisition card directly determines the camera interface: black and white, color, analog, digital, etc. A typical example is a PCI or AGP compatible capture card, which can quickly transfer images to computer memory for processing. Some acquisition cards have built-in multiplexers. For example, eight different cameras can be connected, and the acquisition card can be told which camera's information to use. Some acquisition cards have built-in digital inputs to trigger the acquisition card to capture images; when the acquisition card captures an image, the digital output port triggers a gate. 5. Vision processor: The vision processor integrates the acquisition card and the processor. In the past, when computers were slower, vision processors were used to speed up visual processing tasks. Now, because acquisition cards can quickly transfer images to memory, and computers are much faster, vision processors are used less frequently. [Advantages] Because machine vision systems can quickly acquire large amounts of information, are easy to automate, and are easily integrated with design and manufacturing control information, they are widely used in modern automated production processes for conditions monitoring, finished product inspection, and quality control. The characteristic of machine vision systems is that they improve the flexibility and automation of production. In hazardous working environments unsuitable for manual labor or where human vision is insufficient, machine vision is often used to replace human vision. Simultaneously, in large-scale industrial production, manual inspection of product quality is inefficient and inaccurate; machine vision inspection methods can significantly improve production efficiency and automation. Furthermore, machine vision facilitates information integration and is a fundamental technology for computer-integrated manufacturing. In short, with the maturation and development of machine vision technology, it is expected to be increasingly widely used in modern and future manufacturing enterprises. [Machine Vision System Example] 1. Intelligent Integrated Testing System for Instrument Panel Assembly Based on Machine Vision: The EQ140-II automotive instrument panel assembly is an instrument product manufactured by a Chinese automotive company. The instrument panel is equipped with a speedometer, odometer, water temperature gauge, fuel gauge, ammeter, and warning lights. Due to its large production volume, a final quality inspection is required before shipment. Inspection items include: checking the indication error of five instrument pointers (speedometer, etc.); and checking for damage or missing parts of 24 warning lights and several lighting lights (9 lights in total). Traditionally, manual visual inspection is used, resulting in large errors and poor reliability, failing to meet the needs of automated production. The intelligent integrated testing system based on machine vision changes this situation, achieving intelligent, fully automatic, high-precision, and rapid quality inspection of the instrument panel assembly. It overcomes various errors caused by manual inspection, greatly improving inspection efficiency. The entire system consists of four parts: an integrated multi-channel standard signal source providing analog signal sources for the instrument panel; a dual-coordinate CNC system with image information feedback positioning; a camera image acquisition system; and a master-slave parallel processing system. 2. Automatic Flaw Detection System for Metal Plates: Metal plates, such as the flat wire coils of large power transformers and radio casings, require high surface quality. However, traditional methods using manual visual inspection or dial indicators with control styluses are susceptible to subjective factors and may introduce new scratches into the surface. The automatic flaw detection system for metal plates utilizes machine vision technology to automatically inspect metal surface defects, performing high-speed and accurate detection during production. Furthermore, the non-angle-based measurement method avoids the possibility of creating new scratches. Its working principle is shown in Figure 8-6. In this system, a laser is used as the light source. A pinhole filter removes stray light around the laser beam, and a beam expander and collimator make the laser beam parallel and uniformly illuminate the inspected metal plate surface at a 45-degree incident angle. The metal plate is placed on an inspection table. The inspection table can move in the X, Y, and Z directions. The camera uses a TCD142D 2048-line CCD, and the lens is a standard camera lens. The CCD interface circuit uses a microcontroller system. The host PC primarily performs image preprocessing and defect classification or scratch depth calculation, and can display the detected defect or scratch images on the monitor. The CCD interface circuit and the PC communicate bidirectionally via an RS-232 port, combined with asynchronous A/D conversion, forming an interactive data acquisition and processing system. This system mainly utilizes the self-scanning characteristics of the linear CCD combined with the X-axis movement of the inspected steel plate to obtain three-dimensional image information of the metal plate surface. 3. Automotive Body Inspection System: The 100% online inspection of the dimensional accuracy of the 800 series automotive body contours by the British ROVER Automotive Company is a typical example of machine vision systems used in industrial inspection. This system consists of 62 measurement units, each including a laser and a CCD camera, used to inspect 288 measurement points on the car body shell. The car body is placed under the measurement frame, and the precise position of the car body is calibrated by software. The calibration of the measurement units affects the inspection accuracy and is therefore given special attention. Each laser/camera unit is calibrated offline. Simultaneously, there is a calibration device calibrated offline using a coordinate measuring machine, which can perform online calibration of the camera top. The inspection system inspects one vehicle body every 40 seconds, covering three types of vehicle bodies. The system compares the inspection results with the acceptable dimensions drawn from CAD models by humans, with a measurement accuracy of ±0.1mm. ROVER's quality inspection personnel use this system to determine the dimensional consistency of key parts, such as the overall shape of the vehicle body, doors, and glass windows. Practice has proven that the system is successful and will be used for vehicle body inspection in other ROVER series vehicles. 4. Banknote Printing Quality Inspection System: This system uses image processing technology to compare and analyze more than 20 features (numbers, Braille, color, patterns, etc.) of banknotes on the banknote production line to detect the quality of banknotes, replacing the traditional method of human visual identification. 5. Intelligent Traffic Management System: By placing cameras on major traffic arteries, when a vehicle violates traffic rules (such as running a red light), the camera captures the vehicle's license plate and transmits it to the central management system. The system uses image processing technology to analyze the captured images, extract the license plate number, and store it in a database for management personnel to retrieve. 6. Metallographic Analysis: Metallographic image analysis systems can accurately and objectively analyze the matrix structure, impurity content, and composition of metals or other materials, providing a reliable basis for product quality. 7. Medical Image Analysis: Automatic blood cell classification and counting, chromosome analysis, cancer cell identification, etc. 8. Bottled Beer Production Line Inspection System: Can detect whether beer meets standard volume and whether beer labels are intact. 【Conclusion】 In short, the application of machine vision systems can significantly reduce inspection costs, improve product quality, and accelerate production speed and efficiency. As a high-precision, non-contact measurement solution, vision systems involve optics and image processing algorithms, making them highly specialized products. In the entire measurement and control system, they often need to cooperate with motion control systems to complete position correction and feed control. Furthermore, when performing synchronous and continuous inspection of multiple processes on a production line, the vision system must have distributed networking capabilities. The combination of machine vision with advanced technologies such as motion control and network communication is changing the face of industrial automation production. Currently, system integrators with technical backgrounds in motion control, machine vision, and network communication have emerged in China. Their professional technical support and service capabilities make them a bridge between original suppliers and end users. For businesses, those who recognize technological trends and are the first to implement them will undoubtedly be at the forefront of the competition.