Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Building an Educational Machine Vision Tool Using LabVIEW

  Print

Author(s):
Cheong Loy - ITE West
-

Industry:
University/Education

Products:
Vision, Motion Control, LabVIEW

The Challenge:
Adopting an easy, projectbased approach to learning machine vision for the knowledge-based economy (KBE).

The Solution:
Using LabVIEW, IMAQ, motion, vision, and data acquisition (DAQ) boards to create user-friendly front panels on a touch screen monitor enabling users to access front panel options either at the station itself or remotely in a classroom using a Web browser.

"The easy inspection of handphone LCD display uses the strength of NI products -- motion and vision controllers, NI-DAQ and LabVIEW, IMAQ and OCR software. This approach arouses the interest of ITE students and enhances their learning process in machine vision."

Introduction

In this fast-changing technological era, product life cycle is short. The components of the products are increasingly complex and demand higher accuracy. Customers require quality control for these components with almost zero defects. To fulfill this expectation, 100 percent on-line inspection station is built into the production machine or processes. In view of this situation, a vision inspection station can ensure the quality of the components. The sophisticated vision system can consistently operate during a long period of time in hazardous or less conducive environments.

As a world-class technical institution, it is essential that we teach our students this advanced technology. We built a multi purpose vision inspection workstation (MPVIEW) as an evaluation workstation for the industries and as a training aid for the Institute of Technical Education (ITE) students in the area of machine vision.

Building MPVIEW

We constructed PC-based controlled MPVIEW in two modules.

The top module houses the hardware of motion and vision system. The bottom module has multiple compartments for placing different types of accessories and a PC. A servomotor driven X-Y table (or stage) brings the component to inspect under a camera. A stepper motor driven zoom lens, which we attached to the camera, varies the field of view. The user can operate both the X-Y table and the zoom lens using a joystick, a wireless mouse, or a touch screen monitor. Front and back LED lights are selectable for illuminating the objects under the camera. The front light is four-sided LED bar light. Users can turn each bar light on or off independently. Users can adjust these bar lights to any inclined angle to achieve different illumination requirements. We fixed a backlight at the hollow center of the X-Y table. The users can adjust the intensity of these lights using the control knobs.

We used NI vision (IMAQ PCI-1409), motion controller (PCI-7344), and DAQ PCI-6025E) cards for this MPVIEW. In addition, a PCI network card connects this MPVIEW to the Internet through the local area network (LAN).

To facilitate learning, we mounted all the motion controlled items, such as three power supplies, two torque amplifiers and one universal motion interface (UMI) unit, on a single base plate. Similarly, we mounted the zoom lens and camera interfacing units on another plate.

Using LabVIEW

All of the vision, motion, and DAQ components integrate using the LabVIEW graphical programming language. The numerous examples in the software provided a quick jump-start for this project. With LabVIEW, we easily designed a professional front panel as the user interface. There are three main panels for the user to select object identification, object inspection, and future development option. Within each panel, enlarged customized buttons help the user learn different vision inspection methods on the touch screen monitor. Depending on the number of users, they can access these buttons at either the workstation itself or in a remote classroom using the Microsoft Internet Explorer. When a user presses a button, the system activates an application and a sub-panel displays. It can only return to the main front panel when the user selects the <return> button. The <Manual Adjust> sub-panel manipulates the movement of the x-y table and zoom lens.

LabVIEW and IMAQ vision software provide rapid prototyping capabilities. By calling the dynamic link library (dll) within LabVIEW, the user can move the x-y table using a joystick. Moreover, previewing the live image coupled with tracking a sample position shortened the set-up time. Apart from using the existing vision examples files, the user can add new applications on this station. The following example shows one of the applications developed by ITE students.

Interesting and Practical Application

We found it was essential to adopt an interesting and practical approach in vision and motion control because this workstation provides a training tool for machine vision. We used a handphone instead of merely checking the LCD display for any handheld devices (PDAs, calculators, etc.). The inspection procedure was as follows:

1) After clicking or pressing the handphone button on the object identification panel, the x-y table brings the handphone sample under the camera.

2) Subsequently, a message appears on the screen to invite the user to dial a specified handphone number.

3) Once the line connects, the system displays the user’s handphone number on the screen one after another. The user may make another attempt (by clicking “try again” button) or quit the application and return to the main page. When the user quits the application, the x-y table and the zoom lens return to default positions.

How It Works

A radiation flash sticker attaches to the handphone’s antenna. It lights up when it receives a call. A light sensor, which adheres on the radiation flash sticker, triggers the LabVIEW program. The system takes a snapshot of the handphone’s LCD image, which lists the caller’s number. The program decodes the caller’s number using optical character recognition (OCR) capability. After this, the caller’s number splits into single digits, announces through prerecorded .WAV files in corresponding digits, and eventually displays on the monitor.

We received positive feedback from staff and students on this interesting and practical approach in inspecting the handphone’s LCD.

Conclusion

The MPVIEW provides the capability of object identification and inspection. The easy inspection of handphone LCD display uses the strength of NI products motion and vision controllers, NI-DAQ and LabVIEW, IMAQ and OCR software. This approach arouses the interest of ITE students and enhances their learning process in machine vision. We consolidated numerous vision examples and displayed them on a touch screen monitor for students to easily access either at the station or in a remote classroom.

For more information, contact:

Cheong Fook Loy

Training Officer

Mechanical Engineering Department, ITE West (Dover)

Tel: 065-67770889 ext. 845

E-Mail: Cheong_Fook_Loy@ite.edu.sg 

 

Browse All Case Studies »

  Print