Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

DOI 10.4010/2016.

1838
ISSN 2321 3361 © 2016 IJESC

Research Article Volume 6 Issue No. 6

Printed Circuit Board Assembly Defects Detection Using Image


Processing Techniques
Ganavi V M1, Dr. Mahesh Rao2
M.Tech student1, HOD & PG coordinator2
Department of Electronics and Communication Engineering
Maharaja Institute of Technology, Mysore, India
Ganavi158@gmail.com1, maheshkrao_ece@mitmysore.in2

Abstract:
Defect free printed circuit board assembly (PCBA) manufacturing has gained lot of importance due to the proliferation of low cost
consumer electronic products such as television, mobile, washing machine, etc., In PCBA there are so many types of defects and
producing defect free PCBA's is becoming a challenging task. Defects detection typically undergoes manual inspection and it is
time consuming, costly and it further results in high wastage. Proposed system identifies the PCBA defects using image
processing techniques effectively and it also provides a comparison results by different methods that helps to evaluate best suited
detection technique for real time implementation of the defects detection in the PCBA.

Key words- PCBA Defect detection, Template Matching, Wavelet Transform, Background Subtraction.

1. Introduction 2. Problem Definition

The PCBA (Printed Circuit Board Assembly) industry The use of manual labor to visually inspect each PCBA is no
continues to adopt increasingly higher Windowing and Defect longer viable since it is prone to human errors, time
Extraction Operation levels of integration and achieving consuming, requires large overhead costs and results in high
higher levels of component density. As a consequence, the wastage. The proposed system which is non contact reference
tolerance on PCB assembly has become tighter and tighter. based image processing approach for defects detection and
Defects free PCBA making is more important and there are missing component identification etc., may be of great
many kinds of defects that can occur in PCBA. Identifying and importance to the industry. Here an attempt has been made to
ensuring defects free PCBA is a challenging task. Most of the compare various techniques to see what would be the ideal
defects are difficult to identify by human inspection. The use method and algorithm for real time detection of defects in
of manual labour to visually inspect each PCBA is no longer PCBA.
viable since it is prone to human errors, time consuming,
requires large overhead costs and results in high wastage. In 3. Literature Survey
order to reduce the cost caused by the defected PCBA, it must
be inspected and defects to be identified and sorted at the early The paper [1] presents an efficient algorithm for an automated
stages of the assembly process. Different methods have been Visual PCB inspection system that detects and locates any
developed for the computer based inspection of the PCBAs. defect found on PCBs. The PCB inspection system is then
These methods can be classified as referential and non- improved by incorporating a geometrical image registration,
referential methods. In referential method, test image has to be minimum thresholding technique and median filtering in order
compared with the base image which is considered to be to solve alignment and uneven illumination problem. Finally,
‘perfect image'. Examples of referential methods are image defect classification operation is employed in order to identify
background subtraction, template matching and wavelet the source for six types of defects namely, missing hole, pin
transform. Proposed system which is non contact reference hole, under etch, short-circuit, mouse bite, and open-circuit.
based image processing approach for defect detection, missing The goal of this technique is to enhance the image difference
component identification etc. uses various image processing operation in term of computation time using wavelet transform
algorithms such as Background Subtraction, Template techniques like a dB1, dB2, dB3 and dB4 wavelets.
Matching and Wavelet Transform. This paper makes a A new image Template Matching method for component
comparative study of all such algorithms, to analyze their inspection of electronic assembly systems is presented here
shortcomings and thereby providing an optimal approach to [2]. To recognize incorrectly assembled components, the input
detect maximum number of defects with higher accuracy as image of the components is matched with standard images
well as speed. using a template matching algorithm. To produce a rapid

International Journal of Engineering Science and Computing, June 2016 7824 http://ijesc.org/
inspection system, the processing time of the matching Reference Based Inspection
algorithm should be minimized. Since the standard images of This is based on point or feature comparison between a
all components located in a PCBA are stored in the computer, reference image and input image. It requires much time for
it is desirable to minimize the memory size of the standard image processing and enhancement; specially image
image. The discrete wavelet transformation is applied to registration task before image comparison is applied.
minimize the image size as well as the processing time. Only
7% memory of the BMP image is used to discriminate 1.1.1. Background Subtraction
between how well or not the components have been In many computer vision applications, identifying objects of
assembled. Comparative results are presented to verify the interest in a 2D image is of paramount importance .A common
usefulness of the new proposed method [3]. approach to this problem is background subtraction. It
Providing a solution that can cover a larger inspection area of basically consists of comparing a current captured image with
a PCB so it can reduce inspection time and increase the an estimated reference image (with no objects of interest) and
throughput of PCB production. This solution is targeted for removing common areas. In order to do this, two aspects of
missing and misalignment defects of SMT devices in a PCB image processing are required; background modelling and
by an alternative visual inspection approach using color subtraction technique. During run-time, these aspects are
background subtraction. It is presented to address the stated combined and performed by the background subtraction
defect. Experimental results of various defect PCBs are also algorithm. However in many applications, the occurrence of a
presented [4]. static background is very rare, at least from the camera sensors
The authors make a comparative study of all such algorithms point of view. Hence background subtraction algorithms
developed till date to analyze their shortcomings and thereby should be flexible to the following dynamic situations:
provide an optimal approach to detect maximum of the defects  Illumination changes that is gradual or sudden,
with higher accuracy as well as with speed [5]. This approach  Motion changes that is internal or external,
uses morphological image segmentation algorithm and simple  Geometry changes that is intentional or unintentional.
image processing theories. The given algorithm can overcome These types of dynamic situations are also present in a visual
most of the defects of previous algorithms and detect more system used for PCB inspection. In some case, the
than 80% of defects in a given PCB which ranges from components in a PCB assembly may not be missing or
missing components, broken tracks, misplaced components misaligned, but merely not in the supposed geometrical form;
etc. for example not round but slightly ellipsoid or not straight but
slightly curved. These situations must be considered in the
4. Methodology development of a background subtraction algorithm for PCBA
Keeping in mind the observations made in the literature survey inspection [5]
and the problems summarized the present study has been
carried out in three phases in the specific objective mentioned PCBA image
below
Convert
PCBA Inspection RGB to HSV

Reference based
inspection
Convert
HSV to gray

Background Template Wavelet Apply


Subtraction Matching Transform median filter

Figure 1: PCBA Inspection Methods

4.1. PCBA Inspection Trace region


boundary in
Typically, the PCB's are inspected for either the components binary image
(missing or wrongly placed) or track inspection (broken).
 Components Inspection (missing, wrongly placed or
wrong orientation).
 Tracks Inspection (broken or shorting), this is called Defects detected
as Bare Board Testing (BBT) on both sides in case of Figure 2: Block Diagram for Background Subtraction
double side PCBAs.

International Journal of Engineering Science and Computing, June 2016 7825 http://ijesc.org/
4.2.2. Template Matching
PCBA image
Template Matching is a method of identifying features in a
source image that match a smaller sub-image called the
RGB to gray
template image [6]. It is commonly used in object recognition
applications. Conversion

PCBA image
Apply median filter
Convert RGB to Gray

Calculate NCC between template and Wavelet transform


reference image

rrrrrrere
Split color image and do template Image difference and
matching on RCB morphological
operation

Combine the result

Defects detection
Defects detected
Figure 4: Block diagram of wavelet transform
Figure 3: Block Diagram of Template Matching

Typically, the Normalized Cross Correlation (NCC) is used in 3.3. Detection of defects in PCBA images
Template-Matching algorithms and is given by
There are so many types of defects that occur in PCBA. This
proposed system using different image processing techniques
identifies the following defects in PCBA images:
 Area Defects
 No Population Test
 Side Overhang(Offset)
2.2.2. Wavelet Transform  Upside Mount
 Tombstone
Wavelet Transform is zero mean function and satisfies the  Solder Bridge
division condition during the computation of the wavelet  Lifted Component
transform on a 2D image .It undergoes successive convolution  Missing Component(IC, Capacitor)
by passing it through a filter of row/Column arrangements as  Misaligned Component(IC, Capacitor)
depicted. For 2D wavelet transform, after the first level  Insufficient Solder Joint
Wavelet Transform operation the input image can be divided  Damage Component
into 4 parts: approximation, horizontal, vertical, and diagonal
details where the size of each part is reduced by a factor of 5. Result
two compared to the original input image. The approximation
image is a compressed and large part of the original input The proposed methodology uses different PCBA images
image. Meanwhile the horizontal, vertical, and diagonal details which contain various components of different size, sorts,
contain the horizontal, vertical, and diagonal components of color and fittings. First we use the defect free PCBA as
the input image respectively. When a second level wavelet reference image and a data base of components characteristics
transform is applied, the approximation part of the first level were extracted. After that an image of similar PCBA but with
will be further decomposed into four components. For a higher defects such as missing or misaligned components is tested.
level, iteration is repeated in the same way until the desired After pre-processing the defect PCBA is subtracted from
level is reached [1]. reference PCBA image.

International Journal of Engineering Science and Computing, June 2016 7826 http://ijesc.org/
A large presence of foreground pixels will indicates that there
is some form of defect. The result is arranged in the following
manner whereby the top most image is the reference/good
image, middle image is the defective image and bottom most
image is the result in the processed image.

(a)

(a)

(b)

(b)

(c)
(c)
Figure 6: Detecting missing component (no population test)
Figure 5: Detecting upside mounts using wavelet transform defects using template matching

The figure 5 (c) shows the image representing the results of The figure 7 (c), it shows the image represents the
Wavelet transform being applied successfully to identify the Result of background subtraction being applied successfully
upside mount defect in PCBA. to identify misaligned IC identification in PCBA.
The figure 6 (c) shows the image represents the result of
Template Matching being applied successfully to identify the
missing component in PCBA.

International Journal of Engineering Science and Computing, June 2016 7827 http://ijesc.org/
(a)

Figure 8: Graphical Interpretation of Simulation Time

6. Conclusion and Future work

The proposed work mainly discussed uses of background


subtraction, template matching and wavelet transform to make
the defects detection and classification in PCBA.
All most all types of defects are successfully detected and also
(b)
it gives the comparison that helps to evaluate the real time
implementation of defect detection and sorting.

It is possible to improve further by extracting structural


features based on these regional properties to get detailed
information about the defects.

Acknowledgement

I would like to thank Dr. Sharath Kumar Bhatt, managing


director of Kaynes Technology Pvt. Ltd, Mysore for providing
me with relevant pictures and data for my project.

(c) References
Figure 7: detecting misaligned IC using background subtraction
1. Amith.H, choksiA*,Ronak vashiA ,Mayur sevakA &
The simulation time using MATLAB is tabulated in the table Raushal patelA,"printed circuit board defects
below to show the difference between background subtraction, detection using wavelet transform", in International
template matching and wavelet transform operation of journal of current engineering and technology, Aug
reference PCBA and test PCBA using proposed algorithm. 2014, vol.4,no.4
The execution time for a mounted PCBA for test 1 takes 0.382
seconds, test 2 takes 1.783 seconds and test 3 takes 0.289
seconds to prepare the same picture utilizing the proposed 2. J.W Foster iii, P.Griffin, and J.Korry, "Automated
visual inspection of bare printed circuit boards using
calculation.
parallel processing hardware", The international
journal of advanced manufacturing technology, Vol
Table No.1: Simulation time with different sample PCBA's
2, no.15, pp.2625-2631,2003
Defects detections execution time
methods Upside No Misaligned Misaligned
mount population IC capacitor 3. Han-Jin, Tae-Hyoungpark, "Wavelet transform based
test image template matching for automatic component
Background 0.382 0.562 0.356 0.320 inspection ", Int J Adv Manuf Techno (2010)
subtraction 50:1033-1039, 2 March 2010
Template 1.783 1.957 1.232 1.483
matching
Wavelet 0.289 0.2720 0.253 0.293 4. K. sundaraj, " PCB inspection for Missing or
transformation Misaligned Components using Background

International Journal of Engineering Science and Computing, June 2016 7828 http://ijesc.org/
Subtraction" wave transaction on information science 16. H. H. Loh et al., "Printed circuit board inspection
and application, issue 5,vol 6,may 2009 using image analysis," in Proc. 1995 Inter. IEEE/IAS
Conf. Industrial Automation and Control,pp. 673-
5. Mohit Borthakeer, Anagha lathe, pooja kulkarni, "A 677.
comparative study of Automated PCB defect
detection algorithms and to propose an optimal 17. Z. Ibrahim, S. Al-Attas, and Z. Aspar, "Analysis of
approach to improve the technique", International the wavelet-based image difference algorithm for
journal of computer applications vole 114, PCB inspection," vol. 4, pp. 2108-2113, 2002.
no.6,march 2015
18. D.-M. Tsai and C.-T. Lin, "Fast normalized cross
6. Seul M,o'gorman L,sammon MJ(200) practical correlation for defect detection," Pattern Recognition
algorithm for image analysis, description, examples Letters, vol. 24, no. 15, pp. 2625-2631, 2003.
and code , cambridge university press, Cambridge.
19. G. K. B. Kaur and A. Kaur, "Study and analysis of
7. W. Yokho, "Automated optical inspection of surface defect detection in printed circuit boards using image
mount components using 2D machine vision", IEEE subtraction method," International conference on
15th Annual Conference of IECON, vol. 3, pp. 584- Control, Communication and Computer Technology.
589, 1989.
20. A. Nakhmani and A. Tannenbaum, "A new distance
8. C. Y. C. Hong Dar Lin and W. T. Lin, "Principal measure based on generalized image normalized
component analysis based on wavelet characteristics cross-correlation for robust video tracking and image
applied to automated surface defect inspection," recognition," Pattern recognition letters, vol. 34, no.
WSEAS Transaction on Computer Research, vol. 3, 3, pp. 315-321, 2013.
no. 4, pp. 193-202, 2008

9. Jayaraman et al. (2009). Digital Image Processing.


Tata McGraw Hill Education.

10. Zuwairie Ibrahim, Syed Abdul Rahman Al-Attas and


Zulfakar Aspar," Model-based PCB Inspection
Technique Using Wavelet Transform", The 4th Asian
Control Conference, Singapore, pp.55-58, 2002.

11. Zuwairie Ibrahima and Syed Abdul Rahman Al-


Attasb (2005), Wavelet-based printed circuit board
inspection algorithm, Integrated Computer-Aided
Engineering, 12(1), pp 26-31.

12. W. Y. Wu, M. J. Wang and C. M. Liu (1996),


Automated inspection of printed circuit boards
through machine vision, Computers in Industry,
.28(2), pp.103-111.

13. Horng-Hai Loh, Ming-Sing Lu (1999) Printed circuit


board inspection using image analysis. IEEE Trans
Ind Appl 35(2):426-432

14. E. K. Teoh, D. P. Mital, B. W. Lee, and L. K. Wee,


"Automated Visual Inspection of Surface Mount
PCBs," IECON '90., 16th Annual Conference of
IEEE , pp. 27-30, November. 1990.

15. Y. Nakagawa, "Automatic visual inspection of solder


joints on printed circuit boards," Proc. SPIE, vol.
336, 121-127, 1982.

International Journal of Engineering Science and Computing, June 2016 7829 http://ijesc.org/

You might also like