Home
VIM Vision Input Module User`s Manual
Contents
1. 5 45 Chapter Chapter Objectives What this Manual Contains 1 Using This Manual This chapter provides an overview of the contents of this manual It also contains a definition of the intended audience an introduction to vision vocabulary warnings cautions and other important information information on related publications and updates on revisions to the manual This manual provides reference information on the Allen Bradley Vision Input Module commonly referred to as the VIM module It includes instructions and reference information needed to successfully operate a VIM system Table 1 A provides a quick overview of the organization of this manual Table 1 A VIM Module User s Manual Organization Using This Manual This chapter includes chapter overviews audience definition major terms cautions related publications and revision information Introduction to the Vision Input Module This chapter introduces you to the software and hardware features provides hardware descriptions and shows application examples This chapter introduces the operating principles behind the vision tools and provides advice on setting acceptance range limits VIM System Theory of Operation Staging for Vision Applications This chapter discusses vision application principles such as image quality lighting lenses and setup Installation
2. 05 4 12 Object Positioning sccecscs dchadeanowd it wk weet 4 14 Still Objects 603 ats as lat AnG Aha ome we meee cd ee 4 14 Moving Objects aa 4 14 5 Installation and Integration Chapter Objectives aaau na 5 1 Integration of VIM Components 5 1 Requirements for Installation Into an Existing PLC 1771 I O Rack 5 1 Table of Contents Chapter Objectives 000 0022 ee The Icon Interface 2000000 How the Icon system works Commonly Used Icons 0 0005 3 at ss iS Chapter Title Page 5 cont Requirements for Installation Into a 1771 Standalone 1 0 Rack 5 2 I O Rack Installation 5 2 Power Supply Installation 5 2 VIM Module Installation 5 2 Camera Component Installation 5 5 Light Pen Installation 5 10 Video Monitor Installation 5 10 Strobe Light Connection 5 11 SWINGIN ener hth oe a ites Seay 5 11 Swingarm Connections 0 5 11 Swingarm Installation 5 13 Grounding Considerations 5 14 Indicator Lights LED s 5 15 Integrating a VIM System With Your Process 5 16 Defining Your Interface Requirements 5 16 The Discrete Data Interfaces
3. 5 18 Swingarm Field Wiring Discrete Data Interface nnana 5 18 Discrete Bit Communications to the PLC 5 18 Black Transfers ereiten raa Duwag ar eh we as 5 20 Configuration Blocks 2 22 5 20 Results Block i ones ante eri Baal 5 21 Addressing the Discrete Bits From a PLC Program 5 22 PLC Control of the VIM System 5 22 Bit Manipulation 2000 5 22 Bit Manipulation Example 1 5 23 Bit Manipulation Example 2 5 24 PLC Block Transfer Interface 5 24 Block Length aa chap AUNG BALA 5 25 Typical Inspection Handshake Sequence 5 27 Inspection Cycle time 2 5 5 28 Displaying the Results Block 5 30 Results Block Format 2 5 31 Block Transfer Numbering Systems 5 32 Push button Triggering 5 35 Single Shot Push Button 5 35 Continuous Push Button 5 36 6 Introduction to the User Interface Table of Contents 4 Poe A ee ER AA aaa AA AA Chapter Title Page 6 cont Removing Icon Strips and Displaying Analog IMAG CS 2b rie Soke Paes soe ek NANO LANG ENT 6 5 Changing the Run Time Display 6 5 The Menu Branching Map 6 6 Main Software Branches a 6 7 The Menu Branching Diagram
4. Using Filters With Filters are devices used to suppress interference which the VIM Module 5 would appear as noise in an image Lens and Illumination filters may be used in a VIM module application situation Lens Filters A colored lens filter can be useful in an application situation that requires a certain colored item to stand out If you are inspecting shiny transparent or translucent workpieces polarizing filters can be valuable Neutral density filters can be used to restrict the focus or depth of field of a lens setup Use an infrared pass or cut filters if your workpiece is heated or if you with to exclude ambient visible light Photographers have used lens filters for more than a century The techniques they have developed are all applicable to machine vision The bibliography in Appendix D contains several references for photographic filter techniques Illumination Filters Illumination filters can also be used or a combination of illumination and lens filters can be used For example you can illuminate a fluorescent workpiece with ultraviolet light and observe the visible light it gives off You can also illuminate the workpiece with horizontally polarized light and view through a vertical polarizing filter The 2805 N13A Ring Polarizer and 2803 N13 Ring Light make dual polarization a popular technique 4 16 Chapter Workstage Shielding 4 Staging for Vision Applications To control contrast and shadows you ne
5. Chapter 5 Installation and Integration ngg VIM Module Installation continued Figure 5 3 Installation of the VIM Module Camera Component This section describes installation procedures for the video Installation camera cable lens and extension tube Figure 5 4 provides a graphical illustration of camera component configurations Connector Cable The video camera Cat No 2801 YB is attached to the VIM module by a 12 pin connector cable 2801 NC4 2M 2810 NC5 5M 2801 NC6 10M or 2801 NC7 25M To connect the camera cable 1 Identify the male and female ends of the cable 2 Plug the male end of the cable into the camera input jack located on the face of the module see Figure 5 5 3 Plug the remaining female end of the cable into the 12 pin output jack located on the back of the camera see Figure 5 6 Camera I O Locations Chapter Installation and Integration T P 5 g Camera Component Installation continued Figure 5 4 Camera Configurations C MOUNT LENS pan 2801 YB VIDEO CAMERA EXTENSION TUBE 2801 N1 OPTIONAL PHOTOGRAPHIC LENS om 2801 YB VIDEO CAMERA EXTENSION TUBE 2801 N1 OPTIONAL C MOUNT LENS 2801 NL1 25 mm 2801 NL2 12 5 mm 2801 NL5 12 75 mm Zoom C MOUNTTO PHOTOGRAPHIC LENS ADAPTER 2801 N2 2801 NL3 105 mm 2801 NL4 55mm Chapter 5 Installation and Integration T Camera Component Installation continu
6. Upper Function Status of Line Gauge 22 Reject or Error Lower Function Status of Line Gauge 22 Reject or Error Reserved for Future Expansion Brightness Probe Luminance Level Window 1 Pixel Count Window 2 Pixel Count Window 3 Pixel Count Window 4 Pixel Count Upper Function Result of X Fioat Gauge Lower Function Result of X Float Gauge Upper Function Result of Y Float Gauge Lower Function Result of Y Float Gauge Upper Function Result of Line Gauge 1 Lower Function Result of Line Gauge 1 Upper Function Result of Line Gauge 2 Lower Function Result of Line Gauge 2 Upper Function Result of Line Gauge 3 Lower Function Result of Line Gauge 3 Upper Function Result of Line Gauge 4 Lower Function Result of Line Gauge 4 Value of 0 to 255 Upper Function Result of Line Gauge 5 Value of 0 to 255 0 Upper Function Status of Line Gauge 15 0 Accept 1 Reject or Error 1 Lower Function Status of Line Gauge 15 10 Accept 1 Reject or Error 2 Upper Function Status of Line Gauge 16 0 Accept 1 Reject or Error 3 Lower Function Status of Line Gauge 16 0 Accept 1 Reject or Error 4 Upper Function Status of Line Gauge 17 0 Accept 1 Reject or Error 5 Lower Function Status of Line Gauge 17 0 Accept 1 Reject or Error 6 Upper Function Status of Line Gauge 18 0 Accept 1 Reject or Error 7 Lower Function Status of Line Gauge 18 0 Accept 1 Reject or Error 8 Upper Function Status of Line Gauge 19 0 Accept 1 Reject or Er
7. r The Triangle Two Window Icon h The Triangle Three Window Icon x The Triangle Four Window Icon 4 Chapter 7 User Interface Reference Section T The Window The Circle Window Icon Main Menu continued The Train Through the Lens Icon The Train Through the Lens option allows you to take an image through the lens and retain it as a mask similar in function to the windows The areas under the white portions of the mask will be counted and summed Note It is not possible to modify this mask using the Window Move or Window Size menus The train through the lens feature is only available on windows 1 2 and 3 The X Y Float Icons The windows can be set to accommodate workpiece position variation The position data is referenced from the X and Y line gauges Each window is set for X Y float individually The X Y Float Disabled Anchored Icon This icon indicates that the window position is fixed on the screen and will not move The anchor symbolizes that the window is firmly attached and stationary Picking this icon toggles it to the enabled status This mode is recommended for workpieces which are well fixtured Pd biko Chapter 7 User Interface Reference Section The Window The X Y Float Enabled Icon Main Menu This icon indicates that the window position is adjusted continued according to the measurements made by the X and Y Float line gauges The three lines symbolize water and fl
8. 2 3 17 Count Black White Pixels 3 19 Count Number of Blobs 0 5 3 20 Count Number of Edges 4 3 21 Using Line Gauge Filters 3 22 X Y Float Gauges 46 na Ni cuaecsaeeeseetoatnaeies 3 24 Window Measurements 205 3 24 Setting Windows 00 3 24 Counting Pixels 20 00 pa DAA ANABU ax maha 3 25 PLC Communications Overview 3 26 Discrete Bit Communications 3 26 Block Transfer Communications 3 26 Chapter Summary 00 0c e eee 3 27 4 Staging for Vision Applications Chapter Objectives 22 00005 4 1 Forming the Image 2 e e0eeee 4 1 FOCUS paga Taal la utah eta NG ate Touts AA 4 1 Image Contrast Xa nasama aa toon sues eee akes 4 2 The Importance of Illumination 4 2 Different Types of Illumination 4 4 Methods of Illumination 4 5 Direct IHlumination 2 4 4 5 Indirect Illumination 4 6 Lens Selection and Adjustment 4 7 HowaLens Works 2 2 a 4 7 Selecting the Lens for Your Application 4 10 Using the Lens Selection Table 4 12 Lens Selection if FOV is KNOWN 4 12 Lens Selection if Accuracy isKnown 4 12 Lens and Camera Set up
9. If you use the Hi Lo display to troubleshoot after a Stop on Reject you may see a different reading due to the different line position You will not see this effect with anchored non floating line gauges Chapter J User Interface Reference Section na pO The Window Branch The Window Branch is used to set up the four vision windows The windows perform area measurements by counting pixels These measurements can be range checked to make an accept reject decision This type of inspection is ideal for presence absence verification and for checking variations in area related features The windows may be set to a variety of shapes and sizes to suit different features on the workpiece Window size and location is also flexible The Window Branch THE WINDOW MAIN MENU ON m gt 3 r THE ETC WINDOW MAIN MENUS T Gs Em THE WINDOW HI LO RANGE MENU Er 206 256 THE WINDOW SIZE MENU THE WINDOW MOVE MENU 7 lt B gt ol En ae Chapter 7 User Interface Reference Section nel The Window Tasks The tasks that may be performed in the window branch are listed below Set Windows Enable disable window Set window shape Enable disable X Y float position compensation Set Window Position Set Window Size Set Black or White Area Measurement Set Window Hi Lo Acceptance Range Chapter J User Interface Reference Section The Window The Window Main Menu is used to enable disable the Main Menu windows
10. VIM System Theory of Operation Block Transfer A Block Transfer is a method of communicating a block of data between a PLC and an VO module In this case the I O module is the VIM module and the block of data includes individual measurement results data and configuration data All block transfers are invoked by an instruction from the PLC controller Brightness Probe A sample area of the image used to measure light intensity or brightness This probe can be used to Measure the brightness of a small section of the image Detect lighting changes and compensate for variation Column A row of pixels in the vertical Y direction in the image or on the display screen e Configuration Block A block of data that may be uploaded to or downloaded from a PLC controller This block contains configuration information about measurement windows line gages the brightness probe and other setup information Chapter Using This Manual T Vocabulary One of the more important aspects of the VIM module is continued that configuration data can be transferred in blocks to and from the PLC controller Asa result configuration data may be sent to the PLC controller the VIM module removed and replaced and the replacement module easily reconfigured Contrast The brightness difference between the workpiece and the background as seen in the image Good contrast is important for reliable operation of t
11. 6 7 Points to Remember When Using the Menus and cons maY ha aalng 6 7 Chapter Summary 2 2 6 8 7 User Interface Reference Section Chapter Objectives a 7 1 The Sign on Banner ceic2sicuvrctdletesaias cexes 7 1 Main Menu Tasks 22 200 eee ee eee 7 2 The Main Menu paaa ede cae shew nates oe Re 7 3 The Brightness Branch 0 20005 7 7 Brightness Branch Tasks 00055 7 8 The Brightness Main Menu 7 9 The Probe Move Menu 02 5 7 13 The Probe Hi Lo Range Menu 7 15 The Threshold Adjust Menu 7 19 The Line Gauge Menu Branch 7 23 The Line Gauge Tasks 2 002005 7 24 The Line Gauge Main Menu 7 25 The ETC Line Gauge Menu 7 31 The Line Movement Menu 7 37 The Line Size Menu 2 0 0 200 e ee eee 7 39 The Line Hi Lo Range Menu 7 41 The Window Branch 7 45 THE Window Tasks kada GAAN runnen 7 46 The Window Main Menu 7 47 The ETC Window Menu 220005 7 51 The Window Move Menu 7 53 The Window Size Menu a 7 55 Window Sizing Characteristics 7 55 The Window Hi Lo Range Menu 7 57 Appendix A Menu Branching Diagram Appendix B Results
12. OK Icon Size Menu Picking this icon returns you to the ETC Line Gauge Main continued Menu Chapter J User Interface Reference Section ae The Line The Line Hi Lo Range Menu is used to set the acceptance Hi Lo Range Menu range limits on the line gauges When the measurement falls outside the acceptance range an alarm bit is set in the results block A kug Em GF a saczas Each acceptance range must be carefully chosen based upon the measurement functions selected for the line gauge Complete explanations of measurement functions and how to set proper acceptance ranges are provided in Chapter 3 VIM System Theory of Operation Make sure that you have the specific measurement type clearly in mind while setting the range limits Note The values are expressed in pixels only If you wish to transform these values into standard units inches centimeters etc the host PLC must apply the conversion factor The icons will flash when the Low or High Acceptance Range Limits reach the end of the possible range or the values become equal to each other The Increase Value Icon The active underlined value is increased by one increment each time this icon is picked Use the Select Increment icon if a larger or smaller increment is desired oP The Decrease Value Icon The active underlined value is decreased by one increment each time this icon is picked Use the Select Increment icon if a larger or smaller increment i
13. The active range limit value is identified by underlining 7 16 Chapter J User Interface Reference Section The Probe Hi Lo The Increase Value Icon Range Menu The active underlined value is increased by one increment continued each time this icon is picked Use the Select Increment Icon if a larger or smaller increment is desired Holding the light pen against the icon causes it to increase continuously xy The Decrease Value Icon The active underlined value is decreased by one increment each time this icon is picked Use the Select Increment Icon ifa larger or smaller increment is desired Holding the light pen against the icon causes it to decrease continuously G The Select Increment Icon This icon modifies the amount by which the low or high range limit is increased or decreased Each pick of this icon scrolls through an increment list of lor 10 Pick the icon until the desired increment is displayed The OK Icon Picking this icon returns you to the Brightness main Menu Note The brightness reference level used for lighting compensation is sampled when you pick the OK icon in this menu Chapter 7 User Interface Reference Section ae ae a i np fe rr aaa The Probe Hi Lo The Hi Lo Value Display Range Menu The three numbers in the value display are the Low Range continued Limit Brightness Reading and High Range Limit When the brightness reading is outside the acceptable Hi Lo range the
14. This allows you to identify the cause of the reject so that you can make prompt adjustments if necessary The Trouble shooting Icon toggles through three different states They are 1 Go 2 Freeze 3 Stop The Normal Run Icon GO on REJECT This is the normal operating mode The troubleshooting features are deactivated and system operation proceeds normally regardless of the accept reject decision status G0 Chapter 7 VIM User Interface Reference Section T poA Ay The Main Menu The Freeze on REJECT Icon continued This mode saves a copy of the rejected image Of the four thresholded images only the image that was on the screen when the reject occurred will be saved This may or may not be the window that caused the reject The VIM module continues to operate normally while the frozen image is displayed The freeze status is re armed to capture the next reject with the first pick of the Light pen The Freeze on Reject feature does not penalize the inspection cycle in any way The Halt on REJECT Icon STOP This mode stops the system when a reject occurs All four of the thresholded images are saved and the system stops collecting and processing images in response to the trigger You may then inspect the images to determine the cause of the reject decision The Stop on Reject feature does not penalize the inspection cycle time except while the system is stopped Note The BUSY signal is held TRUE 1 while the system is s
15. Trigger has been received and goes off after Trigger has been reset and Decision is set reset This is an open collector transistor type output rated for 3 to 32 VDC 1 ampere BUSY status low impedance to common and LED ON NOT BUSY or READY status high impedance and LED OFF Swingarm Installation A Swingarm is required to operate the VIM module The lower end of the Swingarm forms a C shaped bracket which snaps onto the horizontal bar of the I O chassis see Figure 5 10 The Swingarm pivots upward and snaps onto the front connector edge of the VIM module see Figure 5 11 Figure 5 10 Installation of the Swingarm AD 5 14 Swingarm Installation continued Grounding Considerations Chapter 4 Installation and Integration The Swingarm is removed by lifting the release tab located at the top of the Swingarm just above the first terminal Figure 5 11 Swingarm Latch Connection EERIE Note The Swingarm release tab requires a fair amount of pressure Be careful not to press the tab too hard because damage may occur Sufficient and proper grounding is extremely important to the performance of your VIM module Your images will show signs of interference or noise if the system is improperly grounded Noise is due to electromagnetic and electrostatic interference and is eliminated by proper earth grounding CAUTION Ground loops can seriously impair the performance of
16. and menu trees These graphic tools make the VIM module easy to operate At the end of this chapter you should understand how icons are activated and how they are built into menus and menu trees The VIM module has been designed for easy operation using icons Icons are small symbols that can be selected to activate a function perform a task or move through selections of options The icons are easily activated by picking them with the tip of the light pen Figure 6 1 Picking an Icon Using the Light Pen BULLETIN 100 CONTACTOR k 7 c CONTACTEUR re SCHUTZ ONTATOR 2 p 2 c The light pen is activated by a switch in the pen tip The switch is activated when the tip is pressed against the video screen When the pen is activated on top of an icon area a function is involved All module functions are controlled through the use of the light pen and icons You do not need to set any switches or jumpers 6 2 How the Icon System Works Chapter 6 Introduction to the User Interface The icons represent functions and tools built into the VIM module Picking an icon allows you to tailor functions to your application You don t need to learn a computer programming language Menus The icons are presented in sets referred to as menus A menu is a group of icons associated with a particular vision task Each menu appears in the black bar dis
17. are excellent for illuminating small objects Some fluorescent lamps flicker at a rate of 60 Hz This is the same rate as the video frame rate This flicker may cause some jitter in the image This jitter is most apparent in image areas such as edges 3 Strobe Lamps When an object is moving past the camera at high speeds a strobe lamp flash of light can freeze the motion to create clear images The strobe produces high intensity light for a very short period of time The brightness of the strobe flash may vary from flash to flash The timing of the flash must be synchronized so that the workpiece is present when the camera scans the area The VIM module can trigger an accessory strobe light through the swingarm Chapter 4 Staging for Vision Applications ja Methods of Illumination In addition to evaluating what type of illumination is most appropriate you must also determine the optimum placement of the light source s Illumination methods can be divided into two categories 1 Direct Illumination Backlighting Light travels directly from the source to the camera lens and is not reflected The object is placed between the light source and the lens and a silhouette is produced This technique is often referred to as backlighting because the illumination comes from in back of the workpiece Backlighting limits the type of features that may be detected to edge features only Features that fall within the object edge areas
18. the release tab may not be properly seated in the slot To remove the light pen press the release tab while pulling the plug out of the jack The monochrome video monitor Cat Nos 2801 N6 12 inch and 2801 N9 9 inch is connected to the VIM module by a BNC type coaxial cable Cat No 2801 NC2 5M or 2801 NC3 10M The video output jack is located on the front panel of the VIM module The video input jack is located on the rear panel of the video monitor see Figures 5 8 and 2 9 12 inch monitor Figure 5 8 12 Inch Monitor Chapter 5 Installation and Integration zi Video Monitor Installation Note Remove the plastic screen cover that comes with on continued your video monitor The screen can interfere with the operation of your light pen To connect the video monitor to the VIM module 1 Locate the video input jack on the rear panel of the monitor Figure 2 9 Plug in one end of the coaxial cable by aligning the slot found on the connector with the cylindrical keys found on the outside of the input jack Twist clockwise to lock counterclockwise to unlock 2 Locate the video output jack on the face of the VIM module see Figure 5 5 and plug in the other end of the coaxial cable To disconnect the video monitor reverse the above steps The scan switch on the front panel of the monitor should be set to underscan This allows you to see all the way to the edges of the image The Brightness and Co
19. the other floating line gauges and windows Window Windows are area measurement tools There is one window Measurements for each of the four thresholded images You define the window size and location Each window may be setup to measure either white or black areas Each window may also be set to float for workpiece position compensation Setting Windows Enable Disable Window The windows may be enabled and disabled individually at the Window Main Menu Setting Window Shape The windows may be set to many different shapes This includes a rectangular window a right angle triangle with four possible orientations a circular window and a trained through the lens mask Moving Windows Windows may be moved anywhere within the image area The top 48 rows may not be used for windows if the immediate brightness compensation mode is selected for the brightness probe The train through the lens windows cannot be moved Setting Window Size Window sizes are individually adjusted horizontally and vertically The circle window adjusts in both directions simultaneously The train through the lens windows cannot be adjusted for size Chapter 3 VIM System Theory of operation oe Counting Pixels The windows operate by counting the number of pixels black or white in the window Train through the lens masks count pixels which lie under white areas of the mask Setting Hi Lo Range Limits Setting a range limit for
20. 6 Binarized Image With a High Threshold bo ocho ha KANYANG Nas kaagad 3 6 3 7 The Probe as Seen in the Video Monitor DURING SGIUD sire cesnteuyees eae akuma AG 3 8 3 8 The Probe Reference Patch Seen in the Live Video Image 200 3 8 3 9 Pixels and Corresponding Digital Values 3 9 3 10 Black and White Blobs 3 10 3 11 Line Gauge Function One Measuring the Left top Edge of the Largest Blob 3 12 3 12 Line Gauge Function Four Measuring the Left top Edge and Width of the Left Top Blob 3 13 3 13 Edges fora Black Blob 0 0000 3 13 3 14 Line Gauge Function Two Measuring the Center of the Largest Blob aa KAL peated 3 15 3 15 Line Gauge Function Five Measuring the Center of the Left top Blob aa 3 15 Table of Contents Figure Table Title Page 3 16 Center fora Black Blob 3 16 3 17 Line Gauge Function Three Measuring the Width of the Largest Blob 3 17 3 18 Line Gauge Function Five Measuring the Width of the Left top Blob 3 17 3 19 Width of a Black Blob 00 3 18 4 1 Specular and Diffuse Reflection 4 3 4 2 Example of Diffuse Backlighting 4 5 4 3 Examples of Indirect Illumination 4 6 44 Relationship of the Focal Length of a Lens to Standoff Distance Given a Constant Field OP
21. BRIGHTNESS MAIN MENU mna G5 RS CA PB m Chapter 6 Introductionto the User Interface THE WINDOW HI LO RANGE MENU E WINDOW SIZE MENU 35 IL ES E pan y P2 WINDOW MOVE MENU ma NI GS SS E En THE LINE HI LO RANGE MENU se Ba Ga Kas pr 62266 THE LINE SIZE MENU LIN Li ri a THE LINE MOVE MENU gt gt Bo gt ln o1 t THE THRESHOLD ADJUST MENU PA PA PG l A t THE OT HI LO mm MENU Sr E Gc2G2e255 mi MOVE mo eT 6 9 Chapter User Interface Reference Section Chapter Objectives The objective of this chapter is to provide you with a reference for the use of the VIM module user interface This chapter is organized into three main sections one section for each main branch in the menu tree Each section is organized by menus Individual icons can be referenced by finding the menu upon which the icon is displayed and locating the icon in the definitions which follow The icons are listed in the order in which they appear on the menu when reading from left to right This chapter should be used as a reference tool when you have questions concerning the VIM module interface Read and use the Vision Input Module Self Teach Manual for instructions on how to apply the VIM module The Self Teach manual leads you through application examples and demonstrates how to apply the VIM system effectively The Sign on Banner The Sign on banner is displayed when the PLC controller unloc
22. Configuration block data is stored in the non volatile memory EEPROM when the OK icon is selected at the Main Menu The Clock Icon Strip is displayed while the data is being stored Interrupting the storage process will corrupt configuration data and cause a configuration fault status when you attempt to operate the system Configuration data is also stored into module non volatile memory EEPROM after a block transfer when the SAVE CONFIGURATION bit bit 17 is set This takes about 5 seconds When bit 17 is reset 0 the configuration is only retained in RAM memory and there is no time penalty Chapter 5 Installation and Integration paya Results Block The results block provides specific results data for each vision tool The results are provided in both discrete Accept Reject or Error mode and in actual measurement values Discrete Accept Reject or Error Bits words 1 through 4 for The brightness probe Windows 1 through 4 Xand Y Float line gauges Line gauges 1 through 22 Actual Measurement Values words 6 through 58 for Brightness probe luminance level Pixel counts for windows 1 through 4 Upper and lower function results for the X and Y Float line gauges Upper and lower function results for line gauges 1 through 22 Figure 5 12 Instruction Addressing Terminology Input 1 or Output 0 Rack No 1 7 Module Group No 0 7 aaa Terminal No 10 17 See Table 5 A AN XXXIXX W
23. Focal Length of a Lens to Standoff Distance Given a Constant Field of View Field of View k Both Workstages Have the Same Field of h Standoff Distance View Short Focal Distance f With Short Standoff 12 5mm Lens lt Image Plane Camera Standoff Distance __ __ J f Longer Focal Distance f With Longer Standoff 25mm Lens Chapter Staging for Vision Applications g 4 9 How a Lens Works Lens Standoff Distance From the Workpiece continued Standoffis the ideal distance between the lens and the item being inspected The standoff for a given field of view is determined by the fixed array size and the focal length of the lens The focal length is the distance between the lens center and the image plane image array in this case when objects in the field of view are in focus Lenses are measured by their focal length A lens with a short focal length such as a 12 5 mm lens has a shorter standoff for a given field of view than a 25 mm lens This is illustrated in Figure 4 4 The camera should be mounted far enough away so that it does not interfere with the process or with the workstage lighting Other considerations might include keeping away from parts that are hot or that emit vapors or dust all of which degrade the performance of the system Figure 4 5 Control of Light Collection Using the F stop of the Lens Aperture Aperture stopped down to decrease brightness Aperture Aperture op
24. Gauge Y Axis Start of Line Row Value of 11 to 252 BIT Decimal WORD 16 Bits 2 Lo Accept Range Limit Upper Function Value of 0 to 255 Hi Accept Range Limit Upper Function Value of 0 to 255 3 Lo Accept Range Limit Lower Function Value of 0 to 255 Hi Accept Range Limit Lower Function Value of 0 to 255 Selected Threshold Number 0 Threshold 1 1 Threshold 2 for Application of Line Gauge 2 Threshold 3 3 Threshold 4 X Y Float Status 0 Anchored 1 Floating 2 X Y Sequence 3 Y X Sequence Line Status Flag 0 Disabled 1 Enabled Line Direction Flag 0 Horizontal 1 Vertical White Black Count Selection 0 Black 1 White Reserved for Future Expansion Zero Line Function Code Value of 0 to 8 0 Left Edge amp Width of Largest Blob 1 Right Edge amp Width of Largest Blob 2 Center amp Width of Largest Blob 3 Left Edge amp Width of Leftmost Blob 4 Center amp Width of Leftmost Blob 5 Right Edge amp Width of Rightmost Blob 6 Center amp Width of Rightmost Blob 7 Count White amp Black Pixels 8 Count Number of Blobs amp Number of Edges Line Filter Code 0 NoFilter 1 Filter1 2 Filter2 Reserved for Future Expansion Zero 5 Line End Point Location Value of 0 to 254 Floating Reference Zero Ordinate Value of 0 to 254 Zero for Line Gauges 1 to 22 610 Config Data For Y Gauge Same Assignments as Words 1 5 BU Configuration Data For Line Gauge 1 Same
25. Gauge 7 Value of 0 to 255 VALUES N B w N N Alu w N OJo Wl wt w BIfW N Wi wj w DINI A N 02 B gt i hk Ww w w N N N o n wj N wo n N 5 40 Chapter 5 Installation and Integration Table 5 B RESULTS BLOCK 1 OF 1 Block Length of 59 Words 16 Bits Decimal The Indicates Values Affected by the Binary BCD Discrete Bit Setting Na ers lowerruncian Re oftine Gouge 7 vaveotowss Chapter 5 Installation and Integration Table 5 C CONFIGURATION BLOCK 1 OF 3 Block Length of 30 Words WORD BIT FUNCTION VALUES 16Bits Decimal Source of Trigger 0 PLCTRIG 1 SWG TRIG Strobe Light Use 0 Disabled 1 Enabled Reserved for Future Expansion Zero Freeze on Reject Status 0 GO 1 Freeze 2 STOP Reserved for Future Expansion Zero Probe X Axis Position Column Value of 0 to 248 Probe Y Axis Position Row Value of 16 to 240 Probe Compensation Reference Level Value of 0 to 255 Probe Compensation Mode 0 Immed Brightness Comp 1 Next Field Brightness Comp Reserved for Future Expansion Zero Probe Lo Acceptance Range Limit Value of 0 to 255 Probe Hi Acceptance Range Limit Value of 0 to 255 Window 1 Base X Axis Position Column Value of 0 to 254 Window 1 Base Y Axis Position Row Value of 11 to 252 Window Lo Acceptance Range Limit Value of 0 to 62 464 Windo
26. Input Module Cat 2803 VIM1 2 7 Light Pen Cat 2801 N7 0 2 8 Camera Cat 2801 YB 2 10 Camera Cables 2 a Das kala DE eyes 2 10 VIM Power Supply Cat 2801 P1 2 10 Video Monitor Cat 2801 N6 7 2 11 Video Monitor Cables 2 13 Applying the VIM Vision Tools 2 13 Chapter Summary 2 5204 oy tok eee ses Seve hero ies 2 17 3 VIM System Theory of Operation Chapter Objectives 000 0 0 3 1 The VIM Module Imaging Process 3 1 Characteristics of Images 3 1 Gray Levels nA AAP An aanak Ma we 3 3 Gray scale Conversion 3 3 The VIM Module Gray Scale 3 4 Binarization of Gray Level Images 3 4 Setting Image Thresholds 3 6 Reading Image Thresholds 3 7 Brightness Probe Lightness Compensation 3 7 The Probe Operation 3 7 The Probe Reference Patch 3 7 Line Gauges 426 0 mrictenecutiun irapa besides 3 9 BIGDS 4 saa Ba Ama sire hake Ss MAL 3 10 Line Gauge Measurements 3 10 Line Gauge Measurement Pairs 3 11 Table of Contents Chapter Title Page 3 cont Edge Measurements 3 12 Center Measurements 0 5 3 15 Width Measurements
27. Module cycle time attainable is achieved continued using TRIGGER BUSY and DECISION signals via the swingarm With all four 4 windows enabled and anchored and all Line Gauges disabled the inspection cycle time is 1 60th of a second Enabling the X gauge and Y gauge and floating the four 4 windows in X and Y results in a cycle time of approximately 1 15th of a second Employing filtering to eliminate transitions of length 1 pixel for both the X gauge and Y gauge does not change this number appreciably unless there are many white to black and black to white transitions along these gauges Inspection cycle times increase as more Line gauges are enabled or as the length of the Line gauges is increased In the absolute worst case enabling and floating all four 4 windows enabling all twenty two 22 line gauges as 128 pixels in length floated in X and Y and using Filter Selection 2 results in a cycle time of approximately 1 6 1 4th second When you must know precisely what the cycle time is with your particular configuration the best way to obtain that information is to measure it directly This may be done by connecting an oscilloscope to the TRIGGER and BUSY terminals on the VIM s swingarm Trigger the scope scan with the rising edge of the TRIGGER signal Measure the time from this trigger until the BUSY signal drops This is the Inspection Cycle Time Make sure to measure it under a variety of image conditions
28. Technique The Count Number of Edges line gauge simply counts the number of edge transitions from black to white in the line gauge Chapter 3 22 Count Number of Edges continued Using Line Gauge Filters 3 gt VIM System Theory of Operation Setting the Line Gauge Set the line size position that suits your application Leave enough line to accommodate part position variation and filtering Setting Hi Lo Range Limits Setting a range limit for edge counts limits the amount of edge count variation that is tolerated before a reject decision is made This tolerance is expressed in edge counts i e the count may vary by plus or minus three edges There are three steps to setting the range limit Step 1 Place a nominal part in the workstage Select the Count Number of Edges measurement in the Set Range menu and take a reading of the edge count Step 2 Determine the amount of variation that can be tolerated in additional edges and add this value to the nominal count Set the high range limit to this value Step 3 Determine the amount of edge count variation that can be tolerated Subtract this value from the nominal count Set the low range limit to this value An acceptance range of or 3 for a nominal count of 15 appears as 12 lt 15 lt 18 Under some conditions line gauge measurements may be subject to interference or noise in the image The Line Filter function is used to remove this noise Three lin
29. VIOW 22 cattails AA BO ANGKAN 4 8 4 5 Control of Light Collection Using the F stop Ofthe Lens na RG an EPERE haan 4 9 4 6 Aspett Ratio 420s tee pate pate sue ees 4 11 5 1 Installation of Keying Bands 5 3 5 2 Configuration Plug Settings 5 4 5 3 Installation of the VIM Module 5 5 5 4 Camera Configurations 000 5 6 5 5 VIM Front Panel Features 2 5 7 5 6 Camera O Locations 1 la aan tee tek 5 8 5 7 VIM Power Supply dn Ka ka GLAD a NAGA 5 9 5 8 TZN Monitor Xa Pama NAA NAA al doe yao 5 10 5 9 Swingarm Field Wiring Terminals 5 12 5 10 Installation of the Swingarm 5 13 5 11 Swingarm Latch Connection 5 14 5 12 Instruction Addressing Terminology 5 21 5 13 Instruction Addressing Example 5 22 5 14 PLC Bit Manipulation Menu Used to Force Control Bits 1 0 34 aaa live waa ana 5 23 5 15 Rapid Firing of the VIM Under PLC Control 5 24 5 16 Free Running Timer aaaaaaaaaaana aaan 5 26 5 17 VIM Module Handshake Cycle 5 28 5 18 Inspection Cycle Times a 5 30 5 19 Results Block Display in Binary Format MALA 5 31 5 20 Results Block Display in Hexadecimal Format 5 32 5 21 Binary Numbering gt waaa a ya eee LU 5 33 5 22 BCD Word Format 2a naaa bank an aNG 5 34 5 23 Single Shot Push button Circui
30. Vocabulary e Line Gauge Line gauges are one of the vision tools in continued the VIM module A Line Gauge is a set of horizontally or vertically aligned pixels found in a row or column The user sets the length direction and position of the line gauges There are twenty two line gauges available in the VIM module plus two XY positioning gauges Fora complete explanation of Line Gauge operation refer to Chapter 3 Master Range Alarm The Master Range Alarm Decison bit is a discrete output which indicates the ACCEPT REJECT status of an inspection It is available to both the PLC controller and through the swingarm Pick The action of picking a displayed icon or value by pressing the tip of the Light pen against its location on the screen Pixel One picture element or dot in an image The image is a matrix of pixels e Range Alarm The response generated when a measurement falls outside its Hi Lo acceptance range The Range Alarm status is communicated through the results block and or by a discrete output master range alarm via the swingarm or backplane Note Each Vision Tool brightness probe windows and line gauges has a range alarm bit The master range alarm outputs an accept reject after an inspection e Range Limit The high and low range limits define the range of variation that can be tolerated above and below the nominal value Range limits are defined by the user e Results Block A
31. a disconnected camera or loss of illumination such as a burnt out light bulb b Either the X or Y float gauge values are out of range orin error For example if the Y gauge fails to find a blob c Any window or line gauge is floated too far so that it collides with the edge of the screen Through the lens windows will not cause an ACQ ERROR ACQ ERROR conditions cause the DECISION LED to come on signaling REJECT 5 TRIG This light is illuminated when a trigger request is made from the swingarm It remains lit as long as the input is held high The light does not respond to trigger requests from the PLC controller me Chapter 4 Installation and Integration Indicator Lights 6 BUSY This light is lit when the module is actively LED s servicing an inspection trigger This light is yellow continued and goes off when the inspection cycle is complete and Integrating a VIM System With Your Process Defining Your Interface Requirements when Trigger is reset Also this LED is on during software download operations and configuration setup 7 DECISION The Decision LED is illuminated when a REJECT decision is delivered It remains on until an ACCEPT decision is made The output is valid only when BUSY is off low The VIM system may be integrated with your process to to provide feedback for process management and closed loop process control This communication can be done through discrete b
32. before making a REJECT decision The upper value must be less than or equal to 255 You may disable the action of the High Range Limit by setting it to 255 a Chapter J User Interface Reference Section The Probe Hi Lo Range Menu CAUTION When using the probe for lighting continued compensation the reference brightness level is resampled at three points the Probe Move Menu the Probe Hi Lo Range Menu and when the strobe is enabled or disabled After performing one of these functions review all four images in the Threshold Adjust Menu to make sure the black white contrast levels are still reasonable Chapter 7 User Interface Reference Section ag The Threshold The VIM module provides you with the capability to set Adjust Menu different black white contrast ratios thresholds for each of four images Set the thresholds to get the sharpest picture of the features you are interested in inspecting All four thresholded versions of the image are simultaneously available for measurement PG PA Er The window currently defined for the active threshold will be displayed when the user enters this menu Remember the images that you see displayed are binary versions of the video image Binarization turns all of the pixels in the image to either white or black depending on whether they are lighter or darker than the reference threshold gray level Experiment with the threshold adjustments until you learn their ef
33. block transfer table initialized by the VIM module to communicate the results of an inspection This block contains information indicating the accept reject status of acceptance range tests for the brightness probe measurement windows and line gauges The actual probe luminance gray value pixel counts for each window and line gauge results for each line gauge are communicated through the Results Block The VIM module generates one result block for each picture analysis cycle Row A line of pixels across the image in the horizontal X direction e Swingarm A screw terminal connector installed on the front panel of many 1771 I O modules including the VIM module It s used to connect wires to the module Chapter 7 Using This Manual i Vocabulary Threshold A gray level used to transform a gray scale continued video image into a binary image Pixels whiter than the threshold are converted to white 1 values darker or equal to the Threshold are converted to black 0 Vision Tool The VIM vision tools include the brightnessprobe line gauges and windows Vision tools are used to take measurements and generate accept reject decisions See Chapter 3 VIM System Theory of Operation for an explanation of Vision Tool operations Window Windows are shapes which define localized image areas to be used for measurement operations The user defines the window size shape and location The vision operation used
34. both X and Y line gauges The Line Direction Icons The line gauges may be placed either vertically Y axis or horizontally X axis This icon toggles the line gauge between the vertical and horizontal directions The icon will not respond to light pen picks if the line gauge is disabled The Horizontal Line Gauge Icon This icon indicates that the line gauge is set to take measurements in the horizontal X axis Picking this icon will toggle it to the vertical setting This function is not available for the X and Y float line gauges The Vertical Line Gauge Icon This icon indicates that the line gauge is set to take measurements in the vertical Y axis Picking this icon toggles it to the horizontal setting This function is not available for the X and Y float line gauges 7 28 Chapter 7 User Interface Reference Section APA a SC I TI R S F p OE ce Main Menu The X Y Float Icons The Line Gauge The X Y Float icon indicates the Float function workpiece continued position compensation status for the line gauge number displayed The icon toggles between enabled floating and disabled anchored Note The measurement output of the line gauge is always in absolute pixel units It is not affected by the amount of X Y compensation that was applied The X Y Float Disabled Anchored Icon The X Y Float Anchored fixed Icon indicates that the line gauge will remain at a fixed position on the screen The anchor symbol indicate
35. can set high and low acceptance range limits on the probe to define an acceptable range of values The probe may also be used to automatically modify the four threshold settings to compensate for changes in illumination of the workstage Set the limits to allow lighting variation that can be tolerated while still producing accurate line gauge and window measurements If the lighting varies beyond the limits reject decisions are signaled regardless of the measurements made by other tools Be sure that the probe is in the proper location before setting the high and low acceptance range limits The acceptance range limit values are located at the right end of the menu These values are Low Actual High Range lt Brightness lt Range Limit Reading Limit You may set the Low and High Range Limits The lt less than or equal to signs indicates that Low Range Limit must be less than or equal to the Actual Brightness probe Reading and the Actual Brightness Reading must be less than or equal to the High Range Limit to pass the test This formula also dictates that the Low Range Limit cannot be greater than the High Range Limit Select the Low or High Range Limit value by picking it with the light pen Then use the Decrease Value and Increase Value icons to change it to the desired value The icons flash when the Low or High Acceptance Range Limits reach the end of the possible range or the values become equal to each other
36. cannot be detected 2 Indirect Illumination Front Lighting Light is reflected from the object to the camera lens making surface features visible This technique is often referred to as front lighting Front lighting allows you to see normally visible features of the part and to make distinctions based upon gray level appearances It may also cast shadows or create reflections which may or may not be useful Each of these illumination methods is discussed in the following paragraphs Direct Illumination Figure 4 2 shows an example of Diffuse Backlighting Figure 4 2 Example af Diffuse Backlighting Diffuse Backlighting This popular form of direct illumination is useful when a high contrast silhouette is required Diffuse backlighting is similar to a slide viewing table where the light is behind a translucent diffusing surface This is the most easily constructed of all backlighting methods This approach works especially well with flat workpieces a well defined silhouette is produced Camera Po Chapter 4 Staging for Vision Applications Indirect Illumination Indirect Illumination or front lighting is used when surface features must be inspected It s also used when backlighting isimpractical Figure 4 3 illustrates several examples of Indirect Illumination Figure 4 3 Examples of Indirect Illumination Front Lighting Directed Bright Field Directed bright field lighting places the camera near the angle of refle
37. find the center of the right bottom blob amp right bottom blob width Set the function and size that suits you application Leave enough line on each side of the blob being measured to allow for position variation and filtering 4 to 8 pixels is suggested Setting Hi Lo Range Limits Setting a range limit for a blob center limits the amount of position variation that is tolerated before a reject decision is made This tolerance is expressed in pixel counts i e the center location may vary by four pixels in the positive direction and four in the negative direction There are three steps to setting the range limit Step 1 Place the workpiece in the nominal expected position and set the line gauge to the appropriate size location and center finding setting Select the center finding measurement in the Hi Lo Range menu and take a reading of the center location Step 2 Determine the amount of variation that can be tolerated in the positive direction in pixels and add this value to the nominal location value Set the high range limit to this value Chapter 3 VIM System Theory of operation ae Center Measurements Step 3 Determine the amount of variation that can be continued tolerated in the negative direction in pixels and subtract this value from the nominal location value Set the low range limit to this value A range of 4 pixels for a nominal position of 120 appears as 116 lt 120 lt 124
38. four windows Each window is set to a size and location that highlights a feature of interest The windows are set to detect the presence or absence of part features by counting black or white area The Menu The branching diagram Figure 6 14 at end of chapter Branching Diagram shows the relationship of all the branches built into the menu tree Each menu shown is labeled by name You can see how the menus are arranged to allow you to complete functions in a logical and systematic manner Menu Access icons are connected to the menus which they access by solid lines Points to Remember e The OK icon returns you to the previous menu When Using the Menus and cons The Disable icon slash turns a tool or option off Icons with a cut off corner indicate access to additional menus sub menus ae Chapter 6 Introduction to the User Interface Chapter Summary The icon interface is easy to use You will find that it takes very little time to get used to the VIM module interface and progress toward applying your vision technology This chapter has introduced you to the basics of the icon interface The following chapter provides you with the specific functions and operations of each of the menus and icons in the VIM module user interface Figure 6 14 Menu Branching Diagram THE MAIN MENU ee Lr E3 T THE WINDOW MAIN MENU THE LINE GAUGE MAIN MENU E i THE ETC LINE GAUGE MAIN MENU THE
39. in workpiece position Automatic Lighting Adjustment The brightness probe feature may be used to monitor the light level on the workstage and adjust the image processing tasks to accommodate lighting variation Hardware The VIM module is a member of the Universal I O family Features of products It uses the same racks power supplies and swingarm terminations found in all Allen Bradley PLC 1771 systems 2 4 Chapter Hardware Features continued 2 Introduction to the Vision Input Module VIM Figure 2 2 The VIM Module Installed in a 1771 I O Rack Integrating the VIM Module with PLC systems The VIM module may be installed into existing PLC VO racks in your facility The VIM module occupies two slots in a standard 1771 VO rack If you have two slots available in a 1771 VO rack and adequate power you may install a VIM module for the incremental cost of the VIM and accessories see Chapter 5 The VIM module eliminates the hardware costs associated with the installation of turn key vision systems With the VIM system you don t need to purchase items such as enclosures power supplies computer card racks I O modules and other hardware You may already have some of these items installed in your PLC system This elimination of redundant hardware greatly reduces the cost of integrating vision into your process Chapter 2 Introduction to the Vision Input Module VIM PE Hardware Features co
40. insensitive to light variations Brightness compensation is not necessary Chapter 2 introduction to the Vision Input Module VIM 2 17 Applying the VIM Inspections are made by placing an array of line gauges Vision Tools horizontally across the workpiece Line gauges 1 2 3 continued and 4 are set to find the width and the center of the largest black blob that falls within the gauge The top gauges 1 and 2 have range check limits which verify that the upper portion of the wire is not stripped The middle gauges 3 and 4 have ranges consistent with stripped wires The bottom gauge line gauge 5 varifies that the conductor has not been pulled out of the insulation It verifies that the largest white blob is at least 90 of the length of the gauge Chapter Summary In this chapter you were introduced to the main features of the Vision Input Module You also reviewed the accessory devices that work with the VIM module The chapter concluded by providing a few application examples to demonstrate the application of the vision tools Additional details on the manner in which the tools work are provided in the next chapter Chapter 3 VIM System Chapter Objectives The VIM Module Imaging Process Characteristics of Images Theory of Operation This chapter introduces you to the manner in which the VIM module operates You ll learn some basics of vision technology and the ways in which the VIM module uses this technolo
41. lenses include an installation and maintenance instruction booklet Consult your local Allen Bradley representative for additional information Camera Extension Tube The optional camera extension tubes are used to alter the image focal length This allows you to use the lenses at shorter distances See Chapter 4 Staging for Vision Applications Installation instructions are provided with each unit see Figure 5 4 VIM Power Supply VIM 12 Volt power is supplied by an external power supply Cat No 2803 P1 Power supply terminals 4 and 5 are wired to 117VAC Power supply terminal 1 is connected to swingarm terminal 1 and power supply terminal 2 is connected swingarm terminal 2 Terminal 3 is connected to ground The power supply provides enough power for two VIM modules The VIM power supply Figure 5 7 provides the power used by the camera Figure 5 7 VIM Power Supply Chapter 5 10 P Camera Component Installation continued Light Pen Installation Video Monitor Installation 5 Installation and Integration WARNING Remove system power before attempting installation Failure to do so may result in electrical shock The light pen Cat No 2801 N7 is attached in the same manner as a home telephone Align the clear plastic plug located on the end of the light pen cord with the light pen input jack located on the face of the VIM module see Figure 5 5 If resistance is encountered check the alignment
42. of Line Gauge 3 20 2 0 15 0 15 0 15 Lower Function Result of Line Gauge 3 Upper Function Result of Line Gauge 4 N N Lower Function Result of Line Gauge 4 Lower Function Result of X Float Gauge Lower Function Result of Y Float Gauge 0 Accept 0 Accept 0 Accept 0 Accept 0 Accept b sab oi so mam ama hou nh ou wou Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 Value of 0 to 255 VALUES The Indicates Values Affected by the Binary BCD Discrete Bit Setting Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Gray Scale Value of 0 to 255 Value of 0 to 62 464 Value of 0 to 62 464 Value of 0 to 62 464 Value of 0 to 62 464 Value of 0 to 255 Value of 11 to 255 Value of 11 to 255 Chapter 5 Installation and Integration aag Table 5 B RESULTS BLOCK 1 OF 1 Block Length of 59 Words The Indicates Values Affected by the WORD BIT FUNCTION 16 Bits Decimal Binary BCD Discrete Bit Setting 0 15 Upper Function Result of Line Gauge 7 Value of 0 to 255 0 15 Lower Function Result of Line
43. red ACQ ERROR lamp is lit and the corresponding bits are set the Brightness Range Alarm in the transfer block and the Brightness Error bit This is called and out of range condition Each of these is explained The Low Range Limit The Low Range Limit is the lowest acceptable probe reading that your application tolerates before making a REJECT decision You may completely disable the Low Range Limit by setting it to zero The recommended setting for applications which do not use the probe is ten This allows the detection of camera and camera cable faults which cause the reading to be zero The Low Range Limit must be less than or equal to the High Limit The Brightness Reading The Brightness Reading is the brightness value detected by the probe It is the average luminosity of the pixels within the probe window It is expressed as a gray scale valueon a scale of 0 to 255 The value may change slightly as you observe live video images due to real time variations in the image The actual value should be about 200 range of 150 to 250 when using the probe for automatic lighting compensation The value can be changed by adjusting the amount of illumination in the scene by using the F stop to change the amount of light collected by the lens or by using a brighter material for the brightness reference patch The High Range Limit The High Range Limit is the highest acceptable probe reading that your application tolerates
44. set size and enable disable the X Y Float function It s also used to access the other Window setup menus me FC Bee fe The Select Window Number Icon This icon scrolls through the four window icon numbers The current icon status settings for each window is displayed when its number is displayed Pick the icon to scroll through windows 1 through 4 Stop when the desired window is displayed The Window Enable Disable Icon The four windows may be enabled disabled individually The Window Enable Disable icon toggles between the enabled and disabled states The Window Enabled Icon This icon indicates that the window displayed in the Select Window icon is enabled on Picking this icon toggles it to the disabled state The Window Disabled Icon This icon indicates that the window displayed in the Select Window icon is disabled off The other icons on the menu will not respond to Light pen picks if the Disable icon is displayed Picking this icon toggles it to the enabled state sa Chapter J User Interface Reference Section The Window The Window Shape Icons Main Menu The windows may be set to a variety of shapes Select the continued shape that best fits the shape of the feature of interest The window shapes are rectangle triangles a circle and train through the lens This icon will not respond to light pen picks if the displayed window is disabled The Rectangle Window Icon E The Triangle One Window Icon
45. shows a typical results block with results displayed in binary form Figure 5 20 displays the same results block in hexadecimal form Chapter 5 Installation and Integration oy aa Aa ua TP TTS Displaying the Notice that the display in Figure 5 19 is updated with Results Block every inspection cycle continued Figure 5 19 Results Block Display in Binary Format BINARY DATA MONITOR BLOCK XFER READ MODULE ADDR 110 FILE 1000 1034 POSITION FILE DATA 001 00000000 00011000 002 00001010 10000000 003 00000000 00000000 004 00000000 00000000 005 00000000 00000000 006 00000000 00001001 007 00000000 00000000 008 00000000 00000001 009 00001000 00001111 010 00000000 00010000 011 00000000 00000000 012 00000000 00000000 013 00000000 10111111 014 00000000 00100101 015 00000000 10111000 RUN PROGRAM MODE Results Block Format The numerical measurements in the results block can be sent to the PLC controller in binary or binary coded decimal BCD format The format is selected by discrete output Bit 16 If the output is set to one the results will be formatted as four digit BCD numbers If the output is set to zero the measurements will be formatted as 16 bit binary numbers If you are not familiar with the following counting systems refer to your PLC programming manual Chapter 5 Installation and Integration 5 32 a ST aa aaa SS SE ESTE Results Block Format continued Figure 5 20 Results Block Display in Hexadecimal Fo
46. string 1110111 is interpreted as 1111111 The Line Filter Two Icon Line Filter Two filters out double pixel blobs as well as single pixel blobs Two adjacent pixels surrounded by pixels of the opposite color are filtered out This eliminates double pixel noise The pixel string 11100111 is interpreted as 11111111 The ETC Icon Picking this icon returns you to the Line Gauge Main Menu ETL Chapter J Userinterface Reference Section The Line The Line Move Menu allows you to set the position of Move Menu the line gauges within the image The line gauges should be set so that the line intersects the feature of interest and provides a margin on either side to allow for position variations Sc II Cc ol t The Line Move Icons The line gauges are moved by using the Light pen to pick the Arrow icon corresponding to the direction you want to move in Each pick with the Light pen moves the line gauge one pixel Holding the Light pen against the icon causes a rapid movement of the line in the selected direction The arrow flashes when the line reaches the edge of the image and cannot go further via GR Note The line may not be placed into the top 40 lines of the screen if the immediate brightness correction probe setting has been selected ee Chapter 7 User Interface Reference Section The Line The Line Size Menu Access Icon Move Menu Picking this icon moves you directly to the Line Size Menu continued without having to r
47. the heading PLC Communications Brightness Probe The brightness probe can be used to adjust for lighting Lighting Compensation variation and its effect on thresholding results Changes in lighting intensity create corresponding shifts in the gray scale values in the scene This can create changes in the images if the contrast in the scene is not great enough The brightness probe provides feedback on lighting variation that is used to adjust the thresholds in proportion to the lighting shift This feature allows the VIM module to maintain high accuracy while tolerating some lighting variation The Probe Operation The probe is a tool which monitors the brightness in a small area in the image and compares it to a learned reference value If the value it finds is different than the nominal value the thresholds for the images are adjusted accordingly This is an optional function The probe samples a small rectangular area in the image The probe reading is the average brightness value for the pixels within the sample area Figure 3 7 shows the probe positioned over an image The Probe Reference Patch Lighting compensation works best when a stable reference patch is provided The patch should be a white object in the work stage that always falls within the image see Figure 3 8 The reference patch must be illuminated by the same lighting that falls upon the workpiece In this way lighting variations that affect the image of the w
48. tools and techniques to achieve these objectives Forming the Image To use the VIM vision system effectively a well formed image must be presented to the vision system A well formed image gives more precise and consistent measurements Two key elements that affect image quality are focus and image contrast Focus The collection of light through the camera lens is a critical step in the formation of the image The lens must be set at the proper distance from the workpiece and then properly focused Lens focus determines the sharpness of the features in the image Image features such as edges and thin sections must be clearly focused to prevent a loss of clarity due to blurring Blurred images may change appearance as the binary threshold levels are changed This is because features like edges may appear as blurred transitions from white to gray to black and threshold changes move the apparent position Chapter 4 2 Focus continued Image Contrast The Importance of Illumination 4 Staging for Vision Applications of the edge along with the changing gray level of the blurred edge This problem is not encountered when edges have crisp contrast with no blurring Blurring can be caused by rapid motion in high speed applications In this case you can use a strobe light to stop the action and eliminate the motion blurring Focus also impairs the ability to see small detail Small features may be blurred and lose the shar
49. white blobs on the line gauge The blob color counted is selected with the Select Blob Color icon Chapter 3 VIM System Theory of operation 33 CT Aa AA PS6 AA Aa Count Number of Blobs Setting the Line Gauge continued Set the line size position that suits your application Leave enough line to accommodate part position variation and filtering Setting Range Limits Setting a range limit for blob counts limits the amount of blob count variation that is tolerated before a reject decision is made This tolerance is expressed in blobs i e the count may vary by plus or minus two blobs There are three steps to setting the range limit Step 1 Place a good workpiece on the workstage Select the Count Number of Blobs icon in the Hi Lo Range menu and take a reading of the blob count Step 2 Determine the largest number of blobs that can be tolerated Set the high range limit to this value Step 3 Determine the least amount of blobs that can be tolerated Set the low range limit to this value An acceptance range of or 2 blobs for a nominal count of 16 appears as 14 lt 16 lt 18 Count Number of Edges The Count Number of Edges function counts the number of blob edges on the line This count is not affected by the setting of the Blob Color icon This function is useful to measure the texture of the workpiece It measures how frilly or busy the surface is Bland workpieces give low number of edges readings Measurement
50. will move you to the Line HI LO Range continued Menu HI LO The Select Line Filter Icon Under some conditions line gauge measurements may be subject to interference or noise in the video signal The Line Filter function is used to remove this noise Three line filter settings are provided to adjust for varying degrees of noise You can sometimes see image noise in the live video image It commonly appears as a graininess around the edges of indistinct objects This graininess may also be due to shadows or poor contrast between objects Black pixelsin white areas and white pixels in black areas may be caused by noise The filter should be set to accommodate the level of noise in the image Note Image filtering does not change the appearance of displayed image Using filters may reduce VIM system throughput speed A complete explanation of line gauge filter functions is provided in Chapter 3 VIM System Theory of Operation Refer to it for recommendations on using the filters The Line Filter Zero Icon Line Filter Zero does not discriminate between pixel relationships this is in effect no filter at all This is the normally recommended setting 7 36 Chapter The ETC Line Gauge Menu continued 7 User Interface Reference Section The Line Filter One Icon Line Filter One filters out single isolated pixels Single pixels surrounded by pixels of the opposite color are filtered out The pixel
51. 2 13 shows an unacceptable part which has failed the acceptance range test Notice that the reading is 133 which is well below the Low Range Limit Chapter 2 Introduction to the Vision Input Module VIM 2 14 a Applying the VIM Vision Tools continued Figure 2 12 Hole Presence Verification Using a Circular Window Image of a Properly Punched Hole Figure 2 13 Hole Presence Verification Using a Circular Window image of an Improperly Punched Hole B at RE ch Chapter 2 Introduction to the Vision Input Module VIM Applying the VIM Application Example 2 Vision Tools Window Used to Verify Label Presence continued A production lines places labels on a bottled product The high line speeds 12 to 15 bottles per second prevent effective human inspection The VIM module is installed directly into the production line PLC system to verify the proper application of the labels see Figure 2 14 window not shown Line Gauge Measurements Line gauges are used to measure black and white pixel groupings along the rows and columns of pixels in the image The line gauges find features such as edges widths and centers of blobs intersected by the line Application Example 3 Line Gauges Used to Check Label Position Line gauges may be set to check for proper position of a label as shown in Figure 2 14 In this case the line gauge is measuring the left edge of the label This line alone will catch missing labels and m
52. 2 2 2 2 2 2 9 2 0 2 5 36 Chapter 5 Installation and Integration Continuous Push Button The continuous trigger will repeatedly cycle the VIM module as long as the push button is pressed The module must be set to SWG TRIG mode The Busy output is used to loop back a Trigger signal Figure 5 24 Continuous Push button Circuit Swingarm 01 Pwr 02 03 Trigger 04 05 Strobe 06 07 Decision 08 09 Busy 10 NG 11 NC 12 lololol R1 Resistor 560 Ohms 20 S1 Momentary Push Button Normally open A B Catalog 800 AM2AR or 800 AM2AG Open No Trigger Closed Trigger Oscillations Chapter 5 Installation and Integration Table 5 B RESULTS BLOCK 1 OF 1 Block Length of 59 Words WORD FUNCTION 16 Bits mead Brightness Probe Accept Range Status Window 1 Acceptance Range Status Window 2 Acceptance Range Status Window 3 Acceptance Range Status Window 4 Acceptance Range Status Reserved for Future Expansion Upper Function Status of X Float Gauge Lower Function Status of X Float Gauge Upper Function Status of Y Float Gauge Lower Function Status of Y Float Gauge Upper Function Status of Line Gauge 1 Lower Function Status of Line Gauge 1 Upper Function Status of Line Gauge 2 Lower Function Status of Line Gauge 2 Upper Function Status of Line Gauge 3 Lower Function Status of Line Gauge 3 Upper Function Status of Line Gauge 4 Lower Function Status of Line Gauge 4 Uppe
53. AB ALLEN BRADLEY A ROCKWELL INTERNATIONAL COMPANY User s Manual Bulletin 2803 VIM Vision Input Module Cat No 2803 VIM1 40062 042 01 A Publication 2803 800 October 1987 Important User Information Solid state equipment has operational characteristics differing from those of electromechanical equipment Application Considerations for Solid State Controls Publication SGI 1 1 describes some important differences between solid state equipment and hard wired electromechanical devices Because of this difference and also because of the wide variety of uses for solid state equipment all persons responsible for applying this equipment must satisfy themselves that each intended application of this equipment is acceptable In no event will Allen Bradley Company be responsible or liabl
54. Assignments as Words 1 5 16 20 Configuration Data For Line Gauge 2 Same Assignments as Words 1 5 21 25 Configuration Data For Line Gauge 3 Same Assignments as Words 1 5 26 30 Configuration Data For Line Gauge 4 Same Assignments as Words 1 5 31 35 Configuration Data For Line Gauge 5 Same Assignments as Words 1 5 36 40 Configuration Data For Line Gauge 6 Same Assignments as Words 1 5 41 45 Configuration Data For Line Gauge 7 Same Assignments as Words 1 5 Chapter Installation and Integration 5 44 pter 5 9 Table 5 D CONFIGURATION BLOCK 2 OF 3 Block Length of 62 Words WORD FUNCTION VALUES poo Bits AGE 46 50 DE Configuration Data For Line Gauge 8 Same Assignments as Words 1 5 ko ad Configuration Data For Line Gauge 9 Same Assignments as Words 1 5 HE Configuration Data For Line Gauge 10 Same Assignments as Words 1 5 Chapter 5 installation and Integration ee Table 5 E CONFIGURATION BLOCK 3 OF 3 Block Length of 63 Words WORD BIT FUNCTION VALUES 16 Bits Decimal 1 Line Gauge 11 X Axis Start of Line Column Value of 0 to 254 Line Gauge 11 Y Axis Start of Line Row Value of 11 to 252 Lo Accept Range Limit Upper Function Value of 0 to 255 Hi Accept Range Limit Upper Function Value of 0 to 255 2 3 Lo Accept Range Limit Lower Function Value of 0 to 255 Hi Accept Range Limit Lower Function Value of 0 to 255 for Application of Line Gauge 2 Threshold 3 3 Th
55. Block Format Table of Contents 5 Figure Table Title Page List of Figures 2 1 The Vision Input Module VIM 2 1 2 2 The VIM Module Installed in a 17711 O Rack 2 4 2 3 The VIM Module Installed in a Standalone Rack Configuration 2 5 2 4 VIM Module I O Paths 0 2 6 2 5 Easy Installation of Swingarm Field Terminations 2 7 2 6 PIQUE ROD so nuit ated asan AN oe oe ate ode aaa 2 8 2 7 Front Panel Features naana 2 9 2 8 Camera and Lens os cceca25s waaa a maw he oe 2 10 2 9 Video Monitor 0 00220224 2 11 2 10 Video Monitor Connections 2 11 2 11 The VIM Module Peripherals and Cables 2 12 2 12 Hole Presence Verification Using a Circular Window Image of a Properly PONCHECIHGIE a 52 ci gaan AK ea Seale EA 2 14 2 13 Hole Presence Verification Using a Circular Window Image of an Improperly Punched Hole gaan hay maadik La 2 14 2 14 Line Gauge Check for Proper Label Position iso he chad 03i Ya dahan daan 2 15 2 15 Stripped Wire Image Showing Line Gauge GC AA 2 16 3 1 Pixels Arranged in Rows and Columns 3 1 3 2 Image Scanning Pattern and Image Coordinates dd aha E Aha AGA man aNG 3 2 3 3 Four Grays Converted to Digital Values 3 3 3 4 Gray level Analog Image 3 4 3 5 Binarized Image With a kow Threshold a AnG NG Ak Kala 3 5 3
56. Both of these elements are highly dependent upon the lighting provided in the image area sometimes referred to as the workstage Because light is the medium used by the vision system to make measurements it is crucial that the illumination be consistent Chapter 4 Staging for Vision Applications Pa The Importance of You should design an illumination stage that best suits your Illumination application Evaluate the workpiece s features color and continued reflectivity as well as the background in order to determine which type of lighting works best The image collected is the result of direct and reflected light The camera sees only the light intensity it does not see color The gray level of a feature in the workstage is determined by the interaction of light and the surfaces of objects in the workstage area When light strikes a surface it can be absorbed transmitted or reflected e Absorbed Light A red object appears red because all the light rays except red are absorbed Dark objects absorb a lot of light Light objects absorb very little light and reflect most of it away e Transmitted Light Light passes through many types of glasses and plastics The light path is often radically modified by this transmission This light is called transmitted light Figure 4 1 Specular and Diffuse Reflection Specular Reflection Diffuse Reflection Light source Camera Light source Camera A Specularly reflected Diffus
57. FUNCTION 16 Bits Decimal Brightness Probe Accept Range Status Window 1 Acceptance Range Status Window 2 Acceptance Range Status Window 3 Acceptance Range Status Window 4 Acceptance Range Status Reserved for Future Expansion VALUES The Indicates Values Affected by the Binary BCD Discrete Bit Setting Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error HU Upper Function Status of X Float Gauge Accept 1 Reject or Error Lower Function Status of X Float Gauge Accept 1 Reject or Error Upper Function Status of Y Float Gauge Accept 1 Reject or Error Lower Function Status of Y Float Gauge Accept 1 Reject or Error Upper Function Status of Line Gauge 1 Accept 1 Reject or Error Lower Function Status of Line Gauge 1 Accept 1 Reject or Error Upper Function Status of Line Gauge 2 Accept 1 Reject or Error Lower Function Status of Line Gauge 2 Accept 1 Reject or Error Upper Function Status of Line Gauge 3 Accept 1 Reject or Error Lower Function Status of Line Gauge 3 Accept 1 Reject or Error Upper Function Status of Line Gauge 4 Accept 1 Rejector Error Lower Function Status of Line Gauge 4 Accept 1 Reject or Error Upper Function Status of Line Gauge 5 Accept 1 Rejector Error Lower Function Status of Line Gauge 5 Accept 1 Reject or Error Upper Function Status of Line Gauge 6 Ac
58. I Word Bit Address Address Chapter Installation and Integration 5 22 p 5 g Addressing the Discrete Bits The PLC controller addresses and controls V O modules From a PLC Program through ladder logic programming The ladder logic rungs must be programmed to read inputs and write to outputs These read and write operations are controlled through instruction addresses programmed on the ladder rungs These assignments typically appear as shown in Figure 5 12 and Figure 5 13 Figure 5 13 Instruction Addressing Example Output Rack No 1 Module Group No 0 a Terminal No 12 ES 010 12 Www Word Bit Address Address PLC Controlofthe There are several ways to control the operation of the VIM Module module using programming tools in the PLC controller This includes the ability to manipulate bits in the discrete bit communications set techniques to control triggering through ladder logic programming and the ability to transfer and read configuration and results blocks Bit Manipulation Many PLC controllers have a Bit Manipulation Menu which can be used to force the VIM control bits listed in table 6 A as the output bits This example uses a PLC 2 05 and T3 programming terminal Other PLC controllers may be slightly different To access the Bit Manipulation Menu press SEARCH 53 on the T3 terminal The Bit Manipulation Menu will be displayed as shown in Figure 5 14 The bits are listed in octal format Cha
59. N 16 Bits Decimal Binary BCD Discrete Bit Setting VALUES 5 5 5 Upper Function Result of Line Gauge 22 Value of 0 to 255 Lower Function Result of Line Gauge22 Value of 0 to 255 3 4 5 56 57 58 59 PLC is a registered trademark of the Allen Bradley Co Inc Allen Bradley Company Inc 1987 D ALLEN BRADLEY WOU 39 4 ROCKWELL INTERNATIONAL COMPANY Industrial Control Group Milwaukee Wisconsin 53204 Publication 2803 800 October 1987 40062 042 01 A
60. NFIG FAULT lamp will come on indicating a corrupted configuration You must reconfigure the module with either the light pen or a configuration block transfer download If you use the light pen you will notice that all vision tools windows line gauges etc are disabled and returned to their default settings and positions CAUTION The VIM module will begin responding normally to trigger signals as soon as it returns to RUN mode Any equipment cannected to the swingarm outputs may be energized by the resulting activiity Chapter 7 User Interface Reference Section Ja The Brightness The Brightness Branch is used to set up vision functions Branch and tools that relate to brightness Image brightness is influenced by lighting in the inspection scene camera lens size and aperture setting and reflectivity whiteness of the workpiece being inspected The VIM module can compensate for variations in lighting and resultant image brightness The compensation process is set up and controlled in this branch The four image thresholds are also set here They are used to get the sharpest definition for different image features The Brightness Branch THE BRIGHTNESS MAIN MENU 22026255 THE PROBE MOVE MENU lt r 8 eS Ee 2a T Chapter J User Interface Reference Section Brightness Branch Tasks The tasks which may be performed in the Brightness Branch are listed below Set the brightness compensation function to Immedi
61. Note Center range limits float when you use X Y position compensation For example when a horizontal line gauge floats two pixels to the right its high and low range limits are both temporarily increased by two Width Measurements Width Measurements find the width of blobs on the line The width measurement is selected by using the Line Gauge Main Menu to select the desired measurement set You read width measurement settings by noting the location of the bottom arrows in the icon The arrows are located under the blob being measured Figure 3 17 Line Gauge Function Two Measuring the Width of the Largest Blob Figure 3 18 Line Gauge Function Five Measuring the Width of the Left top Blob The icon displays a set of either two or three blobs The three blob set indicates measurements of the width of the largest blob indicated by the two headed arrows positioned under the largest blob in the icon see Figure 3 17 The two blob icon indicates width measurement of the left top or right bottom blob see Figure 3 18 Measurement Technique Blob widths are measured by counting the number of pixels in a blob Which blob is measured is determined by the selection of either white or black blob counting and by the line gauge function selected If black blobs are selected black blobs are measured for width see Figure 3 19 A single pixel may be read as a blob In this case the width would be one pixel Chapter 3 18 Wi
62. O chassis contain a configuration plug This is a stake pin jumper located on the chassis backplane near the PLC controller slot Set the configuration plug to the right position N if you use an external chassis power supply such as 1771 P1 Set the configuration plug to the left position Y if you use a power supply module such as 1771 P4 Set to Y when either Refer to Figure 5 2 You are using an in rack power supply module or You are using VIM modules in the chassis in standalone mode with no PLC processor present Set to N when Both an external power supply and a PLC controller are used Chapter 5 Installation and Integration VIM Module Installation continued Figure 5 2 Configuration Plug Settings Set to Y SettoN When a Power When External Supply Module Power Supply is Used is Used Using Power Supply Module in this Chassis Module Installation Open the module locking latch see Figure 5 3 to insert the module Plastic guides on the top and bottom of each slot permit the module to be easily slid into the rack see Figure 5 3 Do not force the module into its backplane socket Apply firm and even pressure to seat it firmly into its sockets After the VIM module is installed secure it in its place with the module locking latch see Figure 5 3 After the module has been properly seated and locked into place its Swingarm can be attached see Swingarm section of this chapter
63. PLC I O rack has the required space your next step is to determine whether the existing power supply has enough current to satisfy the VIM module The VIM module requires 3 Amps of current maximum in order to operate Each module in the rack uses a portion of the available current supply To determine if your power source has sufficient current subtract the total amount of current consumed by each individual component see individual unit documentation from the total amount of current output from your power source see Power Supply documentation If the resultant number is greater than or equal to 3 amps sufficient current is available Total Current Output Total Current Consumed Available Current If your VO rack meets the above requirements you are ready to install your VIM module see the VIM Module Installation section of this document Chapter installation and Integration Ko p 5 g Aa eee eee reer eee nearer eee E E Requirements for A standalone I O rack such as catalog number 1771 PSC Installation Intoa 1771 has four slots two for the VIM module and two for an in Standalone I O Rack rack power supply catalog number 1771 P3 Since the standalone unit is self contained there will always be enough space and current For additional information refer to the documentation accompanying your standalone rack VO Rack Installation For information on I O rack installation see documents 1771 4 5 Mounting Instruction
64. Window 1 displayed over threshold image 1 2 Window 2 displayed over threshold image 2 3 Window 3 displayed over threshold image 3 4 Window 4 displayed over threshold image 4 5 All four windows displayed over threshold image 1 6 The live analog image The Menu The menus and icons guide you through tasks a step ata Branching Map time Each menu contains the icons required to complete a specific task The resultant relationships create a branching structure that can be represented asa branching tree chart Figure 6 13 shows the main branches in the menu structure Figure 6 13 The Three Main Branches of the VIM Menu Brightness Line Gauge Branch Branch Chapter 6 Introductionto the User Interface Pe Main Software The three main branches of software are accessed Branches individually from the Main menu They are Brightness Branch The Brightness Branch is used to set the brightness measurement function set automatic lighting compensation enable or disable strobe lighting and to set the four different thresholds Line Gauge Branch The Line Gauge Branch is used to set up the twenty four line gauges Two of the line gauges are dedicated for measurements to accommodate variation in workpiece positioning The other twenty two line gauges can be set to perform any of nine different measurement sets each with two measurement output options The Window Branch The Window Branch is used to set up the
65. a threshold is used as a reference value Gray scale values below or equal to the threshold are converted to binary 0 s black and values above the threshold are converted to 1 s white The resultant image shows only black and white pixels Chapter 3 VIM System Theory of operation pik Binarization of Gray Level Images continued Figure 3 5 Binarized Image With a Low Threshold The threshold setting can alter the appearance of the image substantially As the threshold is increased the image becomes darker more gray values fall below the threshold and take on the 0 black value As the threshold is decreased the image becomes lighter more gray values fall above the threshold and take on the 1 white value This difference in image appearance at different threshold settings can be seen by comparing the different threshold settings on the same image in Figures 3 5 and 3 6 The higher threshold setting in image 3 6 creates a darker image and affects the appearance of image features differently The thresholds provide flexibility to allow you to enhance features of interest Chapter 3 6 j Binarization of Gray Level Images continued Setting Image Thresholds 3 VIM System Theory of Operation Figure 3 6 Binarized Image With a High Threshold The effective use of the thresholds requires that you understand how to use them to create the best image for the features you are analyzing The objective of sett
66. ace The pen is activated by pressing picking the tip against the screen Figure 2 6 The tip reads the screen location and the module responds accordingly Figure 2 6 Light Pen Chapter 2 Introduction to the Vision Input Module VIM 3 Light Pen Cat 2801 N7 continued Figure 2 7 VIM Front Panel Features Light Pen Jack Status LED s MONITOR Monitor Connection Camera Connection Swingarm Field Wiring Terminals Chapter 2 Introduction to the Vision Input Module VIM Camera The VIM module uses a solid state camera Figure 2 8 The Cat 2801 YB camera can be configured with a variety of lenses to suit individual application needs Figure 2 8 Camera and Lens Camera Cables The camera is available with a variety of cable lengths They are 2meter Cat 2801 NC4 5meter Cat 2801 NC5 10 meter Cat 2801 NC6 25 meter Cat 2801 NC7 VIM Power Supply The VIM power supply is an external 12 VDC power Cat 2801 P1 supply housed in an aluminum case Chapter 2 Introduction to the Vision Input Module VIM T Video Monitor The Video Monitor used for VIM module applications isa Cat 2801 N6 monochrome video monitor see Figure 2 9 It connects to the VIM module using a BNC type coaxial cable from the VIM module front panel connector to the monitor s VIDEO IN connector see Figure 2 10 Figure 2 9 Video Monitor Figure 2 10 Video Monitor Connections Monitor Conn
67. als and the Probe and X Y Float Error signals Table 5 A PLC Discrete Bits INPUT BIT ADDRESS FUNCTION Module Fault 0 Running OK 1 Fault Configuration fault O Configuration OK 1 EEPROM CONFIG invalid Module Busy 0 Ready 1 Busy Master range alarm 0 Accept 1 Decision Reject Probe Error 0 OK Normal Operation 1 Error Probe Out of Range X Y float Error O OK Normal Operation 1 Error Out of Range Reserved for Future Expansion Reserved for Future Expansion OUTPUT BIT ADDRESS FUNCTION Unlock 0 Lock the Module Disable Progrmg 1 Untock Enable Progrmg Reserved for Future Expansion Reserved for Future Expansion Reserved for Future Expansion Reserved for Future Expansion Trigger O Stand By 1 Initiate an Inspection Cycle Binary BCD results O Standard Binary Number Format 1 BCD Format Save configuration data 0 Temporary Storage Fast Mode 1 Configure Permanently Discrete Bit Output The PLC controller outputs signals to unlock the module and trigger the cycling of the module The PLC also controls the format of the results in either binary or BCD Binary Coded Decimal and the retention mode of configuration data Note The TRIG LED on the VIM module front panel responds only to the swingarm input It does not respond to trigger signals sent from the PLC controller Chapter Installation and Integration 5 20 ptet 9 ud Block Transfers The PLC contro
68. alue of zero creates an all white image A threshold value of 255 produces an all black image The OK Icon Picking this icon returns you to the Brightness Main Menu PET Chapter J User Interface Reference Section This page intentionally left blank Chapter J User Interface Reference Section ppa a YyA Y The Line Gauge The Line Gauge branch is used to set up line gauge tools to Menu Branch make measurements A complete description of line gauge options and functions is available in Chapter 3 VIM System Theory of Operation The VIM module has twenty two general purpose line gauges and two position compensation gauges The two position compensation gauges can be used to measure X Y position offsets of the workpiece The twenty two general purpose line gauges are used to make measurements You select one of nine measurement pairs for use in each general purpose line gauge you activate A subset of seven of these pairs may be used for the X Y float line gauges You have control over line gauge location size range and filtering You can also select which of the four thresholded images is used for each general purpose line gauge measurement The Line Gauge Branch THE LINE GAUGE MAIN MENU si lad m 8 IA GG ES THE ETC LINE GAUGE MAIN MENUS t INE HI LO RANGE MENU Eta I LI M THE LINE SIZE MENU G EN THE LINE MOVE MENU lt r 8 eee ay Chapter J User interface Reference Section The Li
69. and Integration This chapter provides instruction on the proper installation and integration of VIM system components Introduction to the User Interface This chapter introduces you to the operator interface and provides an overview of the software User Interface Reference Section This chapter provides a complete reference source for the VIM module menu and icon functions Chapter 1 2 Audience Vocabulary 7 Using This Manual No computer programming experience is required in order to learn to use the VIM module However past experience in PLC operations will greatly enhance your ability to integrate the VIM module into existing PLC systems If you are installing the module in a PLC system you should be familiar with the Allen Bradley line of PLCs and have some Ladder Logic programming experience There are terms in this manual which are commonly used in the machine vision industry and others which are specific to the VIM vision system These and other key terms are defined below Acceptance Range The range of values that are accepted for vision tool range tests The acceptance range is defined by high and low range limits Blob A group of contiguous adjacent white or black pixels along a line of pixels in an image The line gauges in the VIM module make edge center and width measurements for blobs A complete explanation of blob measurement is provided in Chapter 3
70. are required with the 55mm lens This lens is recommended for most Chapter Object Positioning Still Objects Moving Objects 4 Staging for Vision Applications The presentation of the object to be inspected by the VIM module can be divided into one of two categories 1 The object will be stopped in front of the camera or 2 The object will be moving If the workpiece can be inspected while it is still not moving the application will be easier to set up The optimum set up would position the object in front ofa camera with a repeatability of better than one percent of the FOV For example in a FOV of three by four inches the object would be positioned to within 1 32 of an inch If the object cannot be positioned accurately the VIM tools allow adjustment for position variations It is desirable to fixture the object so that the variation in object location will be less than 25 of the FOV Note that the use of these tools slightly increases the time required to inspect each object When the FOV for the application is calculated the amount of object positional variation must be added to the size of the object inspection area to determine the FOV For example an object that is two by three inches and positioned to within one half inch will require an FOV of 2 1 2 by 3 1 2 inches For objects that are moving past the camera a different set up is required If the object is moving a strobe light is probably needed to fr
71. as follows BCD3 is the high order digit bits 8 through 11 BCD2 is the middle digit bits 4 through 7 BCD1 is the low order digit bits 0 through 3 Chapter 5 Installation and Integration ee Block Transfer You can use discrete bits 14 Probe Error and 15 XY Float Numbering Systems _ Error in your PLC program to verify that all tool readings continued are reported in the Results Block If both these bits are reset 0 then the Results Block will contain measurements from all enabled tools Otherwise some of the readings will be zero Push buttonTriggering You may want to trigger the VIM using a push button connected to the swingarm This is useful for lab testing and system integration Two examples of triggering circuits will be provided here One is a single shot trigger which initiates a single inspection cycle and the other is a continuous trigger which repeats cycles as long as the button is pressed Single Shot Push Button This circuit diagram describes the connections for a push button switch which you may attach to the swingarm to manually control triggering of the VIM module The module must be set to SWG TRIG mode Figure 5 23 Single Shot Push button Circuit Swingarm 01 Input Pwr 02 03 Trigger mi 04 S1 Momentary push button normally open Such as A B Cat 800 AMZAR or 800 AM2AG 05 Strobe 06 07 Decision 08 09 Busy 10 NC 11 NC 12 Q 2
72. asurements of the largest blob indicated by the arrows pointing to features of the largest blob in the icon see Figure 3 11 The two blob icon indicates measurements of the left top or right bottom blob see Figure 3 12 Figure 3 11 Line Gauge Function One Measuring the Left top Edge of the Largest Blob Chapter 3 VIM System Theory of operation oe Edge Measurements continued Figure 3 12 Line Gauge Function Four Measuring the Left top Edge of the Left top Blob The Edge Measurement Technique A blob edge exists wherever two adjacent pixels have different colors So blob edges are detected by a change in pixel value from 0 to Lor 1 to 0 Which change is read is determined by the selection of either white or black blob counting If black blobs are selected transitions from white pixels to black blob strings are counted as edges see Figure 3 13 The pixel which changes the value is read as a blob edge A single pixel may be read as a blob In this case both edges would have the same value and the width would be one 1 Note The edge location reported is that of the first or last pixel of the color shown in the Select Blob Color icon So for a blob that is one pixel wide its left top and right bottom edges are at the same position Figure 3 13 Edges for a Black Blob Blob Left Edge Right Edge Column Column Value of 120 Value or 124 Single pixel blobs are sometimes due to noise in the image unwant
73. ate compensation same video frame compensation starting next video frame e Set the Brightness probe location e Set the brightness range Hi Lo limits Enable or disable the use of a strobe light e Set the four binary thresholds to Set threshold level for each of the four images enable disable brightness compensation for each image Chapter 7 User Interface Reference Section 7 9 The Brightness The Brightness Main Menu allows you to set up VIM Main Menu module tools related to image brightness and to control strobe light operation if a strobe light is used The two image brightness related tools are the Brightness Probe and image thresholds SA es eS CA FPB BS The Brightness Probe is used to measure the brightness of the image gray scale value within a small area of the image This tool is used like a light meter The light level is measured to test for acceptability before the inspection is done and to make adjustments if necessary The probe has two functions 1 You may set high and low range limits Hi Lo on the measurement to make a decision 2 The brightness value is used to compensate for overall changes in the light level of the workstage Corrections can be made to each or all of the four thresholded images This compensates for variation due to aging of light bulbs power fluctuations and inconsistent strobe light flashes Note A reference patch is required when the probe is used for lighting co
74. blank Chapter 7 User Interface Reference Section The Probe The Probe Move Menu allows you to set the position of Move Menu the probe within the image JJ lt gt t The Probe Move Icons The probe is moved by selecting the Arrow Icon corresponding to the direction you want to move Each pick with the light pen moves the probe an increment of eight pixels Holding the light pen against the icon causes a rapid movement in the selected direction The icon flashes when the probe has reached the limit of travel The probe position is limited to the top 40 lines when the Immediate Brightness Compensation mode is selected va ht aay Chapter 7 User Interface Reference Section The Probe The OK Icon Move Menu Picking this icon returns you to the Brightness Main Menu continued Note The probe unlike the windows is permanently anchored and cannot have its XY position floating Chapter J User Interface Reference Section SURE The Probe Hi Lo The Brightness Probe measures the brightness of a Range Menu small area of the screen It can be set to test this value to see ifit is too bright or too dark You set the range of acceptable high and low brightness values for the probe Gta Ng 202r255 The probe allows you to make brightness readings on a selected area of the image For example you might use the probe to measure the brightness of a batch of paint or the brightness of a light bulb under test You
75. cept 1 Rejector Error Lower Function Status of Line Gauge 6 Accept 1 Reject or Error Upper Function Status of Line Gauge 7 Accept 1 Rejector Error Lower Function Status of Line Gauge 7 Accept 1 Reject or Error Upper Function Status of Line Gauge 8 Accept 1 Rejector Error Lower Function Status of Line Gauge 8 Accept 1 Reject or Error Upper Function Status of Line Gauge 9 Accept 1 Rejector Error Lower Function Status of Line Gauge 9 Accept 1 Reject or Error Upper Function Status of Line Gauge 10 Accept 1 Rejector Error Lower Function Status of Line Gauge 10 Accept 1 Reject or Error Upper Function Status of Line Gauge 11 Accept 1 Reject or Error Lower Function Status of Line Gauge 11 Accept 1 Reject or Error Upper Function Status of Line Gauge 12 Accept 1 Rejector Error Lower Function Status of Line Gauge 12 Accept 1 Reject or Error Upper Function Status of Line Gauge 13 Accept 1 Reject or Error Lower Function Status of Line Gauge 13 Accept 1 Reject or Error Upper Function Status of Line Gauge 14 Accept 1 Reject or Error 1 Lower Function Status of Line Gauge 14 Reject or Error ng Appendix B Results Block Format RESULTS BLOCK 1 OF 1 Block Length of 59 Words VALUES The Indicates Values Affected by the Binary BCD Discrete Bit Setting WORD BIT FUNCTION 16 Bits Decimal
76. cted light This is the area of brightest intensity in most cases This is particularly true of highly reflective parts with glossy surfaces or light colors The shadows cast by bright field lighting may be used to create strong contrast between a feature in the workstage and its shadow Use directed lighting to create strong contrast between features of interest and their background areas Diffuse reflection is usually preferred to directed bright field lighting because it offers a wider range of gray values for image analysis This is because the image is the result of the light absorbing and diffusing qualities of the features not the reflecting qualities A commonly used method is to place the illumination source at 45 degrees to the workpiece surface and the camera viewing angle assuming the camera is perpendicular to the surface Front Lighting Directed Dark Field Directed dark field is a side lighting technique where the angle of illumination angle of incidence is very shallow A very small amount of the diffusely reflected light reaches the camera and the surface appears dark Any abrupt change in surface height causes a bright reflection into the camera s lens often with an accompanying dark shadow next to it Surface flaws such as scratches and bumps are often detected using this technique Bright Field Front Lighting The image is greatly impacted by the angular relationship of the lighting and camera This is because mo
77. curacy listed in the second column of the table The required FOV is listed in the first column and the lens standoff distance is listed in the right columns When mounting your camera and lens assembly set the front of the lens at the standoff distance listed in the table for your field of view This distance is an approximation it will get your camera close to the ideal location From there focus the lens and set the F stop to get the proper clarity and brightness Example One The desired FOV is 3 by 4 inches Using the table the preferred lens is 55mm with a standoff distance of 26 inches Example Two The desired accuracy of measurement is 1 16 of an inch or 0 063 inch The closest value in the Table is 0 052 by 0 062 with an FOV of 4 by 5 3 inches The preferred lens size is 25mm using a 1mm extension tube The standoff distance is 15 5 inches Chapter 4 Staging for Vision Applications has Lens and Camera Set up continued Field of View in Inches Height o w an fa fall nje bedi Bessai a ING TA en pos s jna njo O a m nal lo n N 1 5 2 4 5 5 N 21 4 N applications Table 4 A Lens Selection Table epee Pixel Size 12 5mm Lens 25mm Lens pe inlinches in Inches 2801 NL2 2801 NL1 NL3 2801 NL4 em reor fren sr faes er sion AM A 7 ann oos owns a007 oma ar oF tonm o
78. dow position You will not see this effect with anchored non floating windows Appendix A Menu Branching Diagram The three main branches of software are accessed individually from the Main Menu They are the Window Line Gauge and Brightness Main Menu branches The following diagram shows the relationship of all the branches built into the menu tree Each menu shown is labeled by name You can see how the menus are arranged to allow you to complete functions in a logical and systematic manner Menu Access icons are connected to the menus which they access by solid lines Aag Appendix A4 Menu Branching Diagram THE MAIN MENU LOG Ji L Ft CO THE WINDOW MAIN MENU ie by CI THE ETC WINDOW MAIN MENU 4 GS o ce ORS ETC THE LINE GAUGE MAIN MENU Pagi 3 G THE ETC LINE GAUGE MAIN MENU eo Fa KC KO THE BRIGHTNESS MAIN MENU mg G5 ky CA TE E Appendix A Menu Branching Diagram re a AZ aaa THE WINDOW HI LO RANGE MENU GG 2066 256 Eta Ng Ed bd fe os ga a GS BI MI EO 4 a k THE LINE HI LO RANGE MENU THE LINE SIZE MENU lt P NG m Da a 62 206 AL tats a Hali k THE LINE MOVE MENU lt gt Be ol t THE THRESHOLD ADJUST MENU a a PRO CR a kA THE PROBE HI LO RANGE MENU 3 Md THE PROBE MOVE MENU lt r Is fe B2024255 Mal Appendix B Results Block Format RESULTS BLOCK 1 OF 1 Block Length of 59 Words WORD BIT
79. dth Measurements continued 3 VIM System Theory of Operation Note Minimum blob width when using Line Filter One is two pixels Minimum blob width when using Line Filter Two is three pixels Figure 3 19 Width of a Black Blob Width of a Black Blob Pixel Count Value of 5 Setting the Line Gauge The line gauge width measurement functions are Find the width of the largest blob amp left top edge right bottom edge or center find the width of the left top blob amp left top edge or center find the width of the right bottom blob amp right bottom edge or center Set the function and size that suits your application Leave enough line off both edges of the blob being measured to allow for position variation and filtering 4 to 8 pixels suggested Setting Hi Lo Range Limits Setting a range limit for blob width limits the amount of width variation that is tolerated before a reject decision is made This tolerance is expressed in pixels i e the width is permitted to vary by plus or minus four pixels There are three steps to setting a range limit Step 1 Place a workpiece that is the nominal size and set the line gauge to the appropriate size location and width measuring setting Select the width measurement in the Set Range menu and take a reading of the blob width Step2 Determine the amount of variation that can be tolerated in additional width in pixels and add this value to the nominal value Se
80. dule communicates information through Communications discrete I O VIM status is communicated for module failure configuration faults or module status In addition alarms are communicated for Probe Range Alarm X Y Float Range Alarm and Master Range Alarm The Master Range Alarm communicates a decision failure if any of the window line gauge or probe acceptance range tests fail Additional discrete bits are used to communicate trigger signals results block format and to signal busy status Block Transfer Block transfers communicate both numeric measurements Communications and ACCEPT REJECT bits for every vision tool Results Block The detailed results of an image analysis are stored in a Results Block The Results Block is used to communicate actual measurement data as well as discrete accept reject signals to the PLC controller This includes Individual tool range alarm bits brightness measurement pixel counts for each window two line gauge values for each line gauge Configuration Blocks The configuration data for a VIM setup may be transferred to and from the PLC controller These blocks of data are referred to as the Configuration Blocks They include setup data such as window size and location line gauge size location and function acceptance range high and low limits probe location and range limits Chapter 3 VIM System Theory of operation 297 Chapter Summary This chapter
81. e clutter Lens Selection Another factor in quality image formation is lens and Adjustment selection and use The lens projects the image of the workstage into the camera and onto the image collection electronics the image array The lens must form a sharp even undistorted image for consistent measurements to be achieved A brief discussion of the subject is presented here Howa Lens Works Lenses bend light rays as they move from air into glass and then emerge from the glass into the air The degree the light rays bend depends on the angle of incidence and the indices of refraction for glass and air Figure 4 4 shows two simple lenses focusing light onto the image plane In solid state video cameras the image plane is a photosensitive array on an integrated circuit A broad selection of lenses is available to meet a variety of application requirements pp Chapter 4 Staging for Vision Applications How a Lens Works Field of View continued Lens selection is largely determined by the Field of View required to see the full area of interest in the work stage Allow room for variation in part position unless the work piece is accurately fixtured The field of view is the area field seen by the camera and projected onto the image array when the image is in focus There may be several lenses capable of meeting your field of view requirements Each of the lenses has a different standoff distance Figure 4 4 Relationship of the
82. e lighting is used to correct for brightness variations in strobe flash The Probe Move Menu Access Icon This icon moves you to the Probe Move Menu to allow you to move the probe in the image The Probe Hi Lo Range Menu Access Icon This icon moves you to the Probe Set Range Menu to allow you to set high and low limits for the acceptance range for the brightness measurement HI Lo Chapter 7 User Interface Reference Section or The Brightness The Strobe Icons Main Menu The VIM module can fire a strobe light when a trigger continued signalis received The strobe is also fired occasionally during set up The Strobe Icon looks like a lightning bolt to represent the flash of light from the strobe The Strobe Disabled Icon The strobe light fire signal is disabled The display screen shows live video images This is the normally recommended mode when using regular incandescent lights The Strobe Enabled Icon In this mode a strobe fire signal is sent whenever an image is taken The display screen then displays only frozen images No live images are displayed This mode is recommended only when using strobe lighting The Threshold Adjust Menu Access Icon This icon moves you to the Threshold Adjust Menu to allow you to set each of the four binary thresholds The OK Icon This icon returns you to the Main Menu PEP Chapter 7 User Interface Reference Section This page intentionally left
83. e system isin operation This is the recommended setting for applications with stable workstages The Brightness Float Enabled Floating Icon This icon indicates that the Brightness Float function is enabled for the image number displayed in the Image Number icon The threshold values are corrected to compensate for variation in lighting The correction is based upon the brightness probe reading taken during operation The Whiten Image Icon Picking this icon causes the image to get whiter Each pick of the icon changes the threshold one gray level Holding the Light pen on the icon causes a rapid increase in the picture whiteness The icon flashes upon reaching the limit of change The threshold value can be set anywhere in the full gray scale range of 0 to 255 The threshold nominal setting may be read by the PLC controller from configuration block number one 1 Chapter 7 User Interface Reference Section T The Threshold The Blacken Image Icon Adjust Menu Picking tbis icon blackens the image by increasing the continued reference threshold Each pick of the icon changes the threshold by one gray level Holding the light pen on the icon blackens the image rapidly The icon flashes upon reaching the limit of change The threshold value can be set anywhere in the full gray scale range of 0 to 255 The threshold gray scale value may be read by the PLC controller from configuration block number one 1 A threshold v
84. e filter settings are provided to adjust for varying degrees of noise Under low contrast conditions you may see noise in the live video image It commonly appears as a graininess around the edges of objects Black pixels in white areas and white pixels in black areas may be caused by noise The filter should be set to accommodate the level of noise in the image Filters can also be used to ignore fine detail in the image For example you may be able to disregard the thin decorative borderline around the edge of a label by using a two pixel filter Chapter 3 VIM System Theory of operation ag Using Line Gauge Filters The Filtering Technique continued The Line Filters work by comparing relationships between groups of adjacent pixels on the line A series of line readings are used for illustration purposes A line with two large black blobs might look like this 1111000000000000111100000001111111111 eS SS SS eS gt gt gt Black Blob 1 Black Blob 2 Noise in the signal might appear as isolated pixels that do not correspond to part characteristics This creates small signal variations which can be misinterpreted as blobs or breaks between blobs 1111000000001000111100000001111011001 Unwanted variations Line Filter Zero Line Filter Zero does not process the line to eliminate noise Line Filter Zero is actually a filter OFF setting Line Filter One The line filter can be set to ignore these small variations by remo
85. e for indirect or consequential damages resulting from the use or application of this equipment The examples and diagrams in this manual are included solely for illustrative purposes Because of the many variables and requirements associated with any particular installation Allen Bradley Company cannot assume responsibility or liability for actual use based on the examples and diagrams No patent liability is assumed by Allen Bradley Company with respect to use of information circuits equipment or software described in this manual Reproduction of the contents of this manual in whole orin part without written permission of the Allen Bradley Company is prohibited 1987 Allen Bradley Company 50 00 Table of Contents Chapter Title Page 1 Using this manual Chapter Objectives 00 00 00 naa 1 1 What This Manual Contains 1 1 Audience 2 sac oe eset ets APA 1 2 Vocabulary 2 0 ated aaa NEE ka aNG Pe ou ASA a ie 1 2 Warnings and Cautions 00 1 5 Related Publications 2000 1 6 Revision Information 0005 1 6 2 Introduction to the Vision Input Module VIM Chapter Objectives 0 0000202 2 1 What is the Vision Input Module 2 1 Functional Features 0005 2 2 Hardware Features 2 00005 2 3 Vision Input Module Hardware Description 2 7 The Vision
86. ect or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Chapter 5 38 i Table 5 B 5 Installation and Integration RESULTS BLOCK 1 OF 1 Block Length of 59 Words BIT Decimal WORD FUNCTION 16 Bits Upper Function Status of Line Gauge 15 Lower Function Status of Line Gauge 15 Upper Function Status of Line Gauge 16 Lower Function Status of Line Gauge 16 Upper Function Status of Line Gauge 17 Lower Function Status of Line Gauge 17 Upper Function Status of Line Gauge 18 Lower Function Status of Line Gauge 18 Upper Function Status of Line Gauge 19 Lower Function Status of Line Gauge 19 Upper Function Status of Line Gauge 20 Lower Function Status of Line Gauge 20 Upper Function Status of Line Gauge 21 Lower Function Status of Line Gauge 21 Upper Function Status of Line Gauge 22 Lower Function Status of Line Gauge 22 0 1 2 3 4 5 6 7 8 9 0 15 Reserved for Future Expansion Brightness Probe Luminance Level 0 15 Window 1 Pixel Count 0 15 Window 2 Pixel Count Window 3 Pixel Count 0 15 0 15 0 15 Window 4 Pixel Count 1 Upper Function Result of X Float Gauge 12 13 0 15 Upper Function Result of Y Float Gauge 0 15 0 15 0 15 0 15 Upper Function Result of Line Gauge 1 Lower Function Result of Line Gauge 1 17 Upper Function Result of Line Gauge 2 18 0 15 Lower Function Result of Line Gauge 2 0 15 Upper Function Result
87. ection VIDEO A LINE _B 1 Connect Monitor Cable to Line A IN jack me Ka Ba lee 2 Set Line A Back Panel CI NID Switch to ON Select Button to LineA IN 0 3 Set Front Panel LINE 2 12 Chapter 2 Introduction to the Vision Input Module VIM Figure 2 11 The VIM Module Peripherals and Cables a 2803 VIM1 WARNING Disconnect all power before assembling bA JO W mrn pl LI LIGHT PEN 2801 N7 ENTTITITILG EG Pee ee a CABLE 2801 NC2 5M 2801 NC3 10M POWER SUPPLY 2801 P1 VIDEO MONITOR 2801 N6 ca Ej Na CORD CABLE 2801 NC4 2M 2801 NC5 5M 2801 NC6 10M 2801 NC7 25M POWER CORD IL VIDEO CAMERA Nu 2801 YB CAMERA Chapter 2 Introduction to the Vision Input Module VIM ee Video Monitor Cables The video connection cable from the VIM module to the video monitor is available in two lengths 5meter 2801 NC2 10 meter 2801 NC3 Applying the VIM The VIM module measurement tool set offers many high Vision Tools speed measurement capabilities Measurements are based upon image information in windows shapes or line gauges lines in the image Line filtering functions are provided to enhance features in order to improve measurement accuracy Practical applications of these tools are reviewed in the following paragraphs Window Area Measurements Pixel counting Window
88. ed Figure 5 5 Front Panel Features Light Pen Jack Status LED s Monitor Connection Camera Connection Swingarm Field Wiring Terminals Chapter 5 8 Camera Component Installation continued 5 Installation and Integration Figure 5 6 Camera 1 0 Locations Camera Rear View DC In Ext Sync Insert Female End of Connector Cable Video Out No Connections The connectors or plugs should easily fit into their respective jacks If resistance is encountered realign the pins and try again To remove the camera cable reverse the above steps However to unlock the cable from its connection slide the collar of the connector back towards you while pulling the cable out of its jack Lenses When you receive your video camera it will not have a lens You have the option of ordering any of the following lenses depending upon your needs and applications 2801 NL1 25mm C mount 2801 NL2 12 5 mm C mount 2801 NL3 55 mm Photographic requires 2801 N2 Lens Mount Adapter 2801 NL4 105 mm Photographic requires 2801 N2 Lens Mount Adapter 2801 NL5 12 5 to 75 mm Zoom requires 2801 N2 Lens Mount Adapter Chapter 5 Installation and Integration ag Camera Component See Figure 5 4 for an illustration of camera and lens Installation configurations For information on typical lens continued requirements and applications refer to Chapter 4 Staging for Vision Applications All
89. ed signals The edge finding and blob finding functions can adjust for this using line gauge filters The filters cause small blobs one or two pixels wide to be ignored See the Line Gauge Filters heading later in this chapter for details pa Chapter 3 VIM System Theory of Operation SSA EE O OET AT a Edge Measurements Setting the Line Gauge Edge Finding Functions continued The line gauge edge measurement functions are find left top edge of largest blob amp largest blob width find right bottom edge of largest blob amp largest blob width find left top edge of left top blob amp left top blob width find right bottom edge of right bottom blob amp right bottom blob width Set the function and size that suits your application Leave enough line off of the edge of the blob being measured to allow for position variation and filtering four to eight pixels suggested Setting Hi Lo Range Limits for Edges Setting a range limit for an edge limits the amount of position variation that is tolerated before a reject decision is made This tolerance is expressed in pixel counts i e the edge location may vary by four pixels in the positive direction and four in the negative direction There are three steps to setting the range limit Step1 Set the workpiece in the nominal expected position and set the line gauge to the appropriate size location and edge finding setting Select the edge finding measurement i
90. ed to enclose shroud the workstage This prevents stray reflections and shadows from interfering with the automatic operation of your system Shrouding also provides a dark black background which always increases the contrast It is also good practice to have any fixtures close to the workstage finished in a flat black color This prevents reflections and the resulting uneven illumination Thisis the reason that camera lenses are black Chapter 5 Installation and Integration Chapter Objectives In this chapter we will acquaint you with the installation of the VIM system We will also provide guidelines for integration into PLC systems and your process Integrationof This section discusses in detail the installation and VIM Components integration of the VIM module and its components Requirements for Installation of a VIM module into an existing PLC VO rack Installation Into an Existing is dependent upon two variables availability of slot space PLC 1771 1 0 Rack and availability of sufficient power Availability of Space The VIM module requires a module group two adjacent vacant slots in which to be mounted If your existing PLC 1771 VO rack does not have two adjacent empty slots you cannot install a VIM module If this is the case you have two options 1 acquire a larger rack 2 acquire an additional rack See your local Allen Bradley representative for details Availability of Sufficient Power If your existing
91. eeze the object s motion in order to eliminate blur in the image A strobe light is set up in the same manner as a fluorescent or incandescent light The VIM module will trigger the strobe light at the correct time The strobe light trigger is connected to the VIM swingarm In order for the strobe light to eliminate blur in the image it must be much brighter than the ambient lighting A cover or shroud is often needed around the workstage to reduce the ambient light The shroud also prevents the flashing strobe light from becoming a distraction to nearby workers To determine whether a strobe light is needed calculate the FOV necessary for the inspection and find the size of a pixel for that FOV using the Lens Selection Table Divide the Chapter 4 Staging for Vision Applications wae Moving Objects speed of the object in inches per second by sixty If the result continued is greater than one half the pixel size a strobe light should be used e Example The object is a ring with a diameter of three inches moving at a speed of thirty feet per minute six inches per second From the LENS SELECTION TABLE select an FOV of three by four inches The pixel size is 0 013 inch by 0 016 inch The object will move 0 1 inch 6 inches per second 60 This is greater than one half the pixel therefore a strobe light is needed The object speed would have to be reduced to less than two feet per minute to eliminate the need fora strobe light
92. eference Section The Window The Hi Lo Range Display Hi Lo Range Menu This display shows the value of the area measurement made continued in the window and the high and low acceptance range limits for the measurement The Low Range Limit The Low Range Limit is the lowest acceptable value for the measurement If the measurement value is less than the lower limit an out of range condition exists and the corresponding range alarm bit in the results block is set to one 1 The Actual Area Measurement Reading This is the actual measurement made by the window When the reading falls within the acceptance range the corresponding alarm bit in the results block is set to zero 0 The reading may change slightly as you observe live video images this is due to real time variations in the picture The High Range Limit The High Range Limit is the highest acceptable value for the measurement If the measurement value is higher than the high limit an out of range condition exists and the corresponding range alarm bit in the results block is set to one 1 The OK Icon Picking this icon returns you to the ETC Window Main Menu In the Hi Lo Display windows are displayed at their anchored nominal position Their position is not floated The readings are taken from this anchored position So if you use the Hi Lo Display to troubleshoot after a Stop on Reject you may see a different reading due to the different win
93. egration 5 26 pte 3 g Block Transfer Example An example of a results block transfer will serve as an example of block transfer programming The PLC program in Figure 5 16 reads the list of measurement results for each inspection performed Triggering is accomplished through the swingarm you may also use triggering circuits shown later in this chapter Figure 5 16 Free Running T imer VIM Timer ae NG H 12 15 Latch Trigger VIM Busy Unlatch Trigger BLOCK XFER READ DATA 0030 MODULE 100 LENGTH 59 FILE 0500 0572 Chapter 5 Installation and Integration NOPE Typical Inspection The handshake sequence upon which the PLC Handshake Sequence communications are based is as follows 1 The controller issues a TRIGGER command to initiate an inspection cycle 2 The controller waits fora BUSY reply to indicate that the module has begun the inspection 3 The module receives the TRIGGER command It responds by lifting BUSY It begins the inspection of an image 4 Na The controller receives the BUSY signal It responds by dropping the TRIGGER bit It waits for BUSY to go low 5 The module completes the inspection Since TRIGGER is now low it places the DECISION output to the appropriate level either low ACCEPT or high REJECT Then it sets BUSY low to indicate that it is ready for the next inspection 6 The controller sees the BUSY line go low It then reads
94. ely reflected light ray glare light rays lossy object se eae NN e Reflected Light Light that is not absorbed or transmitted is reflected The two types of reflected light are specular and diffuse and usually both types are present A glossy magazine cover exhibits both types of reflection When held ata certain angle light is reflected directly into the reader s eyes specular reflection and the print cannot be observed When tilted slightly the specular reflections are directed away from the reader and the diffusely reflected light allows the print to be observed Figure 4 1 shows both types of reflection Chapter Staging for Vision Applications Different Types of Several types of illumination devices may be used with the Illumination VIM module Many of these may be ordered directly from Allen Bradley as accessories See your local representative for details 1 Incandescent Lighting Incandescent lamps are popular because they are economical and their intensity is easily adjusted However ordinary incandescent lamps have limitations since they exhibit a constant degradation in light during their operating life Using a halogen light source results in a more consistent light output 2 Fluorescent Lighting Fluorescent lamps produce less heat than incandescent lamps yet produce the same amount of light Some fluorescent lamps in multiple lamp fixtures provide large diffuse illumination Circular fluorescent bulbs
95. ened to increase brightness Lens Front View Lens Section View per Chapter 4 Staging for Vision Applications How a Lens Works Lens Aperture F stop Settings continued You may control the amount of light collected by the lens using an internal lens device called the F stop The F stop acts much like the pupil of your eye controlling the amount of light that comes in contact with the lens The smaller the aperture opening the less light that enters the camera Proper F stop setting is very important to image collection Use the F stop to control image exposure and obtain the best possible contrast after the lens has been focused see Figure 4 5 The F stop number indicates the amount of light that passes through the lens aperture Care must be taken to remember that as the F stop setting increases the brightness of the image decreases A typical set of lens F stop values is 2 8 4 5 6 8 11 and 16 The 2 8 setting collects the greatest amount of light and the 16 setting collects the least amount of light For each step up in F stop value e g going from 2 8 to 4 the image brightness decreases by 1 2 Note Always switch the monitor display to the live analog image before adjusting the camera focus or F stop To do this touch the Light pen to the top portion of the display screen until the live analog image appears Selecting the Lens for The following instructions aid you in the selection and Your Application setup
96. escription Input Module and its related peripherals and cables The Vision Input Module The VIM module is an intelligent I O module The main Cat 2803 VIM1 hardware features of the module are e Swingarm connections a characteristic feature of Allen Bradley PLC modules which consist of a swingarm removable bulkhead with screw type terminals The swingarm connections provide easy access to wiring terminations and is easily installed see Figure 2 5 Figure 2 5 Easy Installation of Swingarm Field Terminations The swingarm swings neatly off the front of the module during VIM module removal or replacement and is easily snapped back into place This eliminates the need to disconnect any of the hard wired terminations for the module during maintenance and service Status LEDs These indicator lamps light up to show the operating status of the VIM module Input and output status and error conditions are indicated on the front panel LED s Figure 2 7 dg Chapter 2 Introduction to the Vision Input Module VIM The Vision Input Module Front Panel Peripheral Connections Simple plug in Cat 2803 VIM1 type connectors provide easy connection of VIM module continued peripheral devices This includes the light pen monitor and camera connections Figure 2 7 LightPen The Light Pen is used in combination with the video screen Cat 2801 N7 tocomplete the icon driven user interf
97. esults Block can only be transferred when the module is LOCKED and not BUSY The block transfer write instruction can be used to transfer any of the three configuration blocks to the VIM module Configuration blocks can only be transferred when the VIM module is UNLOCKED and not BUSY It is not possible to write a results block to the VIM module Block Length The VIM module will determine which block of data is being sent or received based on the data length of the transfer request If a block transfer read or write request is sent with a data length of exactly 30 words the module will assume that configuration block 1 Setup and Windows is being made If a block transfer read or write request is sent with a data length of exactly 62 words the module will assume that configuration block 2 X Y Float gauges and first 10 line gauges is being made If a block transfer request is made with a data size of exactly 63 words the module will assume that the request is for configuration block 3 line gauges 11 through 22 When a block transfer read request is made with other than the configuration block lengths of 30 62 or 63 the module will assume that all or a portion of the results block is being requested You may read only a portion of the result block For example the first 15 or 33 words This may accelerate your program execution speed Note You may not transfer exactly 30 word of the results block Chapter Installation and Int
98. eturn to the ETC Line Gauge Main Menu The OK Icon Picking this icon returns you to the ETC Line Gauge Main Menu Chapter 7 User Interface Reference Section pp The Line The Line Size Menu allows you to set the line gauge size Size Menu Lines may be as short as 1 pixel or as long as 255 pixels full image width Say mag beg pr Horizontal lines grow and shrink from the right end and vertical lines grow and shrink from the bottom end The Grow Line Icon Picking this icon causes horizontal line gauges to grow from the right end and vertical line gauges to grow from the bottom end The icon will flash when the Line Gauge has reached the edge of the image It is recommended that you leave at least a small border between the line and the edge of the image The arrows in the icon will be oriented to the horizontal or vertical axis of the line gauge The Shrink Line Icon Picking this icon causes horizontal line gauges to shrink on the right end and vertical line gauges to shrink on the bottom end The icon will flash when the line gauge cannot shrink any more The shortest possible line gauge is on pixel long The arrows in the icon will be oriented to the horizontal or vertical axis of the line gauge ml Ta The Line Move Menu Access Icon Picking this icon moves you directly to the Line Move menu without having to return to the ETC Line Gauge Main Menu sy Chapter 7 User Interface Reference Section TheLine The
99. fect on the features of interest and can decide upon the best settings The Image Number Icon Picking this icon toggles you through each of the four digital images The icon displays the number of the image being displayed Each image may have a different threshold setting Each image has a window associated with it Image icon number one displays thresholded image number one with window number one See the Window Branch section of this manual for additional information on applying windows The Brightness Float Icons The Brightness Float function uses the brightness measurement from the probe to compensate for variation in lighting It does this when the system is in automatic operation by correcting each of the four threshold settings It is enabled disabled individually for each of the four images 7 20 Chapter 7 User Interface Reference Section The Threshold Note Brightness Float is recommended for use with strobe Adjust Menu lighting which may vary slightly from image to image You continued won t see the effects of the Brightness Float feature until you exit the Brightness main menu and return the system to the Run mode Using brightness float full frame update may reduce the throughput speed of the system The Brightness Float Disabled Anchored Icon This icon indicates that the Brightness Float is disabled for the image number displayed in the Image Number icon The threshold level remains constant while th
100. given standoff distance the length of the tube is listed on the chart next to the distance to the object in Table 4 A Note There are techniques for folding and enlarging the standoff distance For example the camera can view the workstage through a mirror or prism This allows considerable freedom in camera placement and angle Chapter Using the Lens Selection Table Lens Selection if FOV is Known Lens Selection if Accuracy is Known Lens and Camera Set up 4 Staging for Vision Applications Reference table 4 A has been provided to aid you in the selection of the best lens for your application You may use the table based upon a known FOV or a desired accuracy To use the LENS SELECTION TABLE in Table 4 A if the FOV is known find the FOV listed in the first column of the table that is larger than the FOV required by the application The FOV column lists the height then width for FOVs from 0 3 to 32 inches in size On the right side of the table the standoff distance for each lens that is recommended is shown for each FOV The preferred lens is indicated in bold type and should be used unless the physical constraints of the application limit the choice of standoff distances The second column of the table gives the accuracy to which an object will be measured at each FOV The third column gives the pixel size To use the LENS SELECTION TABLE if the desired accuracy of the measurement is known find the desired ac
101. gy The VIM module is similar to other machine vision systems in many ways Like most vision systems the VIM module receives its input from a solid state video camera The camera collects light using thousands of light sensitive elements Collectively the light seen in these elements forms the image You ll see many references to these images throughout this manual Video images are collected in a raster scan format The image is made up of many small picture elements referred to as pixels The pixels are arranged in a rectangular array consisting of horizontal rows of pixels and vertical columns of pixels This is illustrated in Figure 3 1 Figure 3 1 Pixels Arranged in Rows and Columns Vertical Columns Horizontal Chapter 3 2 Characteristics of Images continued 3 VIM System Theory of Operation The Camera Array The camera is set up so that the image is focused onto the camera s array of light sensitive elements Each element responds with an electrical signal corresponding to the intensity of the light which falls upon it These values are the sent to the VIM module The Camera Scanning Process The camera scans the light sensitive elements and transfers the readings to the VIM module The scan starts at the upper left hand corner of the array and moves horizontally across the row of pixels in line one It then retraces to the left side and scans across line two This raster scanning proces
102. has introduced you to some of the basics of vision technology and demonstrated how these basics are applied in the Vision Input Module These basics include vision image coordinates gray level image collection binarization of images and setting binary thresholds These techniques help to understand the operating principles of the vision tools used in the brightness probe line gauges and windows Advice was provided on setting acceptance range limits Refer to this section should you have any questions on the proper range limits as you set up your application Chapter 4 Staging for Vision Applications Chapter Objectives Successful vision applications are based upon good image quality Image quality is the result of proper illumination lens selection and camera and lens setup You should keep in mind the first law of machine vision If you can t see it clearly in the video monitor then you can t inspect it with the vision system In Chapter 3 we discussed the image processing task of converting light into images for processing by the VIM module In this chapter we will discuss the application of lighting cameras and lenses to create quality images This process is called staging There are two main objectives in the design of a vision workstage 1 To make the features of interest clearly visible 2 To reduce clutter in the image and eliminate irrelevant features from the image This chapter discusses specific
103. he Busy output to directly energize external equipment the Busy output is energized during power up and reset to indicate that the module is not yet ready to perform an inspection pan N gt Actual Swingarm connection assignments are illustrated in figure 5 9 the following list describes each connection 12 Volt Power Input Cat No 2803 P1 Provides a connection for the external power supply at terminals 1 and 2 Trigger Input Swingarm terminals 3 and 4 are used for connections to sensors or other triggering devices Your Trigger Input signal must be from 3 3 to32 VDC You may use a pushbutton trigger device see Figure 5 21 Chapter 5 Installation and Integration 543 Swingarm Connections Strobe Light Output Provides a connection for a 5 volt continued TTL Strobe light positive edge trigger at terminals 5 and 6 The Strobe light cable must be of shielded type and terminated to at least 7 5 ohms Shielded cables reduce noise and interference and are highly recommended Decision Output Swingarm terminals 7 and 8 are used for output connections The Decision Output will toggle ON OFF asa result of the ACCEPT REJECT analysis This is an open collector transistor type output rated for 3 to 32 VDC 1 ampere ACCEPT LED OFF high impedance REJECT LED ON low impedance to common Busy Output The Busy signal indicates that the module is busy and a decision is pending It comes on as soon as the
104. he vision tools used in the VIM module Depth of Field The range in which objects focus clearly It is measured from the distance beyond the ideal focal point to the distance in front of it in which objects remain in focus Field of View The angle of view that is seen through a lens or optical instrument The distance from the left to the right edge of the visible space Field Video A single scan of the video camera image The camera produces a steady stream of video fields each consisting of a series of scan lines rasters Gray Scale A measure of relative brightness from black through many increments of gray to white Icon A symbolic pictorial representation of a command Picking an icon with the Light pen triggers the command Typical icons include Move Up and Move Down arrow icons that are used to move objects on the screen These icons look like arrows pointing up and down The icon system is explained in Chapter 6 Introduction to the User Interface Light Pen The input device used to interact with the VIM module It s used with the video monitor to pick icons and menus and to configure the system to meet your application needs The light pen is shaped like a pen and has a cord that attaches to the VIM module face during setup The pen responds to the emitted light as images are scanned onto the screen explaining the name Light Pen Chapter Using This Manual
105. icated by downward pointing arrows that center on one of the blobs Figure 3 14 Line Gauge Function Three Measuring the Center of the Largest Blob Figure 3 15 Line Gauge Function Five Measuring the Center of the Left top Blob The icon displays a set of either two or three linear blobs The three blob set indicates measurements of the largest blob indicated by the arrows pointing to center of the largest blob in the icon see Figure 3 14 The two blob icon indicates center measurement of either the left top blob or right bottom blob see Figure 3 15 Measurement Technique Blob centers are measured by finding the center pixel in a blob Which blob is read is determined by the selection of either white or black blob counting and the line gauge function selected If black blobs are selected black blobs are measured for center locations see Figure 3 16 Note When the width of a blob is an odd number the central pixel position is reported as the blob center When the width is even the pixel nearest position to the left of the center is reported er Chapter 3 VIM System Theory of Operation Center Measurements continued Figure 3 16 Center for a Black Blob Center of a Black Blob Column Value of 122 Setting the Line Gauge The line gauge center measurement functions are find the center of the largest blob amp largest blob width find the center of the left top blob amp left top blob width
106. in VIM windows is area measurement by pixel counting e Workpiece The item to be inspected by the VIM module e Workstage The area viewed by the camera Warnings and Warnings and Cautions occasionally appear in this Cautions document They are included in order to protect both you and the equipment They appear as follows Warning A warning symbol means that people might be injured if the stated procedures are not followed Caution A caution symbol is used when the equipment could be damaged or performance seriously impaired if stated procedures are not followed Chapter Related Publications Revision Information 7 Using This Manual The following Allen Bradley documents contain VIM module related information Each document is referenced where appropriate Consult your local Allen Bradley representative for ordering information Vision Input Module Self Teach Manual Publication Number 2803 819 Grounding and Wiring Guidelines Publication Number 1770 4 1 Mounting Instructions for 1771 I O Chassis and Power Supply Publication Number 1771 4 5 PLC 5 15 Processor Manual Publication Number 1785 6 8 1 PLC 5 15 Assembly and Installation Manual Publication Number 1785 6 6 1 Solid State Control General Information Publication Number SGI 1 1 A System of Universal I O Publication 1771 1 2 Mounting Dimensions for 1771 I O Chassis and Power Supplies Publication 1771 4 5 PLC Control
107. ined here A complete explanation of functions is available in Chapter 3 VIM Theory of Operation Note Either white blobs or black blobs may measured See the Select Blob Color Icon later in this chapter for details 7 32 Chapter 7 User Interface Reference Section The ETC Line Gauge The Line Function One Icon Menu This function finds the continued 1 left top edge of the largest white or black blob 2 width of the largest blob ti The Line Function Two Icon This function finds the 1 right bottom edge of the largest blob 2 width of the largest blob i The Line Function Three Icon This function finds the 1 center position of the largest blob 2 width of the largest blob ik The Line Function Four Icon This function finds the 1 left top edge of the left top blob 2 width of the left top blob H Chapter J User Interface Reference Section PE The ETC Line Gauge The Line Function Five Icon Menu This function finds the continued 1 center of the left top blob 2 width of the left top blob nf The Line Function Six Icon This function finds the 1 right bottom edge of the right bottom blob 2 width of the right bottom blob 7 The Line Function Seven con This function finds the 1 center of the right bottom blob 2 width of the right bottom blob T The Line Function Eight Icon This function counts the 1 total number of white pixels on the line 2 total
108. ing a threshold is to get sharp contrast between the feature to be measured and the surrounding area In binary images this means that you need the feature of interest to be either black or white and its surroundings to be the opposite value We ll use two gray objects as an example The object of interest is light gray and the background upon which it is located is dark gray By setting the threshold at a gray value that falls between the light and dark grays of the object and background the object appears as white and the background appears as black If the threshold is too high both object and background appear black Ifit is too low both object and background appear white The VIM module provides you with four images each with its own threshold setting During operation all four images are captured and processed simultaneously This creates the capability to set thresholds to suit a range of image feature values Chapter 3 VIM System Theory of operation a Reading Threshold Values 5 You ll be able to judge the threshold setting best by experimenting View the results of threshold changes on the monitor however if you would like to see the numeric threshold value it can be read through the PLC programming terminal A block transfer of the window configuration block is required to read the actual threshold gray level setting For more information of the use of block transfers refer to Chapter 5 VIM Installation under
109. ion provided in the Results Block is much more detailed than the single Decision Bit However the Results block requires more time to transfer and may add to the inspection cycle time in high speed applications Detailed collection management and processing of results data can be done by the host PLC controller Your PLC controller can greatly add to your systems ability to improve your process Contact your local Allen Bradley PLC supplier for information on data management and information processing options for the PLC controller Many software hardware and communications products are available Chapter Installation and Integration 5 18 pee 2 pRO The Discrete Data Discrete data and system status can be transmitted through Interfaces the swingarm or directly to your PLC controller through bit transfer Swingarm Field Wiring 757 Accept Reject and Busy status can be communicated Discrete Data Interface through the swingarm Swingarm terminals 7 8 9 and 10 are used for discrete output connections Terminals 7 and 8 The Master Range Alarm Decision output will be set depending on the results of the Master Range Alarm s summary Accept Reject analysis low 0 Decision Accept high 1 Decision Reject The state of this output will be the same as the Decision LED off low or 0 on high or 1 Terminal 7 is the output terminal and terminal 8 is common Terminals 9 and 10 The Busy output is set to high 1 when
110. its of the swingarm terminal or through a PLC controller Discrete bit communications will transfer accept reject decision and error condition signals no measurement data is communicated The block transfer approach communi cates a wide range of information including configuration and results data directly to the PLC controller This approach requires PLC ladder logic and block transfer programming skills as well as an understanding of binary BCD binary coded decimal and hexadecimal systems Note The use of block transfer communications increases the operating demands on the VIM module This additional system overhead may add to the inspection cycle time This is a consideration mainly for high speed applications over 5 parts second The interface to your process may be made in several different ways The approach which you choose will be dependent upon your process requirements To begin first determine which type of feedback is required for your process control a single accept reject decision a list of many detailed accept reject decisions or a list of numerical measurements Accept Reject Decision Feedback The VIM System communicates summary accept reject results through the Decision Master Range Alarm discrete output bit The Master Range Alarm transmits a Reject Chapter 5 installation and integration 5 17 Defining Your Interface signal if any of the acceptance range tests for the line gauges Requirements or wi
111. ks the VIM module to allow setup or configuration modification The PLC controller unlocks the module by setting the Unlock discrete output bit number ten 10 to one 1 In Stand alone mode the banner is displayed by picking a bright spot on the screen with the Light pen This enables setup and displays the following menu strip T ba DE DOT I7 m tS FH FZ 2883 UTMI1 SER A FEU AMY EN BRADLEY COMPANY oF The Unlock Icon Pick the Unlock Icon to access the Main menu and begin setup or modification of the VIM module You will move on to the Main menu The Main menu provides access to all other menus and icons 72 Chapter 7 User Interface Reference Section Main Menu Tasks The tasks that may be performed while at the Main menu are listed below Select the source of the trigger 1 PLC triggered or 2 Swingarm Triggered Select the Troubleshooting Mode 1 Normal Run GO 2 Freeze Picture on Reject 3 Halt on Reject STOP Save the system configuration after setup is completed by choosing the OK icon in the Main menu Chapter 7 VIM User Interface Reference Section T The Main Menu The Main Menu is the menu through which all other menus are accessed The Main Menu has the access icons to get to the Brightness Line Gauge and Window menus It also has icons used to setup operating modes for run time troubleshooting external triggering and saving setup parameters ho E E CO a The Brightnes
112. lers 2 16 and 2 17 Processor User Manual Publication 1772 6 5 8 Other VIM module related documentation may be ordered as needed This is the first release of this manual No revisions have been made to date Chapter 2 Introduction to the Vision Input Module VIM Chapter Objectives In this chapter we will familiarize you with the features functions installation and application of the Vision Input Module To clarify subject matter a summary is provided at the end of the chapter Whatisthe The Vision Input Module adds the power of Machine Vision Input Module Vision to the Allen Bradley line of Programmable Logic Controllers PLC It isa member of the Universal I O family of products It gives you the ability to make non contact inspections and communicate the data to your PLC system The VIM module can inspect areas in a scene for information such as workpiece presence or absence and make linear measurements to find edge and center locations and feature widths These measurements can be corrected to accommodate variations in part position and workstage lighting Figure 2 1 The Vision Input Module VIM The VIM module is a low cost vision system providing a new advantage in price and performance to industry The VIM module uses solid state video camera for image collection It s easy to use install and operate VIM module 22 Chapter 2 Introduction to the Vision Input Module VIM Whatis the 5 u
113. ller is capable of gathering blocks of data from the VIM module These blocks can be configuration blocks or results blocks Configuration blocks contain configuration data for the VIM module They can be uploaded to the PLC controller and downloaded to the VIM module The results block changes with each inspection cycle of the VIM module The results block data provides very specific results data A block of data can contain up to 64 16 bit words of data The data may be assigned in either bit or word increments Complete tables of block transfer assignments are provided at the end of this chapter Table 5 B through 5 D You will see that some communications such as accept reject require only one bit for communication while others require a byte of information 8 bits or a full word Block transfers are controlled from the PLC controller using ladder logic programming Configuration Blocks Configuration blocks communicate more data than discrete bits The three blocks are outlined below Configuration Block One 30 Words Trigger status Strobe status Run time debug status Probe position and acceptance range data Window configuration data for all four windows Configuration Block Two 62 Words X Float line gauge configuration data Y Float line gauge configuration data Configuration data for line gauges 1 through 10 Configuration Block Three 63 Words Configuration data for line gauges 11 through 22
114. mpensation The patch should be white or relatively bright It should not move and should be illuminated by the same lighting as the workpiece The Brightness Compensation Mode Icons The Brightness Probe is an instrument that probes the image to monitor the light level The Brightness probe is used much like a photographer uses a light meter to measure luminance The reading can be used to compensate for variations in the overall lighting level on the workstage The adjustment can be set to act upon the current video field or upon the next field collected The Full Image Brightness Compensation Icon In Full Image Compensation mode mode 2 the thresholds are adjusted to accommodate lighting variation in the next acquired field This mode is recommended when using all types of illumination except strobe lights Chapter 7 10 The Brightness Main Menu continued 7 User Interface Reference Section The Immediate Brightness Compensation Icon The Immediate Brightness Compensation mode mode 1 changes the thresholds on the same video field that is being probed before any Line Gauge or Window functions are performed Compensation is made only for the screen area below the top 40 lines lines 41 through 262 Note In the Immediate Brightness Compensation mode the probe must be positioned within the top 40 lines on the screen All other vision tools must be positioned below line 48 This mode should be used when strob
115. n the Hi Lo Range menu and take a reading of the edge location Step 2 Determine the amount of variation that can be tolerated in the positive direction in pixels and add this value to the nominal location value Set the high range limit to this value Note One method to determine this value is to move the workpiece as far right or down as it will go Use the edge reading at this position as the high range limit Step3 Determine the amount of variation that can be tolerated in the negative direction in pixels and subtract this value from the nominal location value Set the low range limit to this value Note One method to determine this value is to move the workpiece as left or up as it will go Use the edge reading at this position as the low range limit Chapter 3 VIM System Theory of operation 3 15 AR a AA Edge Measurements A range of 4 pixels might appear as continued 116x 120x 124 Note Edge range limits float when you use X Y position compensation For example when a horizontal line gauge floats two pixels to the right its high and low range limits are both temporarily increased by two Center Measurements Center measurements find the centers of blobs on the line The center measurement is selected by using the icon interface to scroll to the desired measurement set You read center location settings by noting the location of the top arrow in the icon Center measurements are ind
116. nary bits These strings can be used to find blob edge locations blob widths the number of edges to count white and black pixels and to count numbers of blobs 2 10 Chapter 3 VIM System Theory of Operation Blobs Blobs are clusters of pixels of the same value black or white Blobs typically correspond to features in the image that the line gauge crosses Blob width is measured by the number of pixels in the blob Blobs can be measured for either white pixel or black pixel blob groupings Blob edges are measured in row or column coordinates This is why it is important to fully understand pixels and the screen coordinate system Edges in horizontal line gauges are expressed as column locations Edges in vertical line gauges are expressed as row locations Edges are the row or column location of the first pixel at the beginning of a blob Edges may be detected for either end of a blob Figure 3 10 Black and White Blobs Line Gauge The VIM module offers fifteen different line gauge Measurements measurement and feature counting functions based on the line gauge techniques These are Edge Measurements including find left top edge of largest blob find right bottom edge of largest blob find left top edge of left top blob find right edge of right bottom blob Center Measurements including find center of largest blob find center of left top blob find center of right bottom blob Width Measurements includi
117. ndows fail continued This type of communication is ideal if you want to eliminate unacceptable units from production but do not need to track the detailed cause of the rejection This is practical for inspection of workpiece attributes as seen in completeness of assembly inspections where either the parts are either all there or they are not The resulting output indicates that the part is incompletely assembled and should be removed from production No measurement data is required for theseapplications so none need be communicated Accept Reject feedback can be communicated through the PLC controller or through the swingarm The communication comes as a discrete bit of information indicating acceptance or rejection of the workpiece Similar communications are also transmitted through discrete PLC controller bits We will cover these in detail later is this chapter Block Transfer Feedback Numerical measurement data is communicated through block transfer to a PLC controller A block transfer can be used to send a Results Block The Results Block includes discrete bit Accept Reject results for the Brightness probe Window ranges X Y float gauges Line gauges 1 through 22 It also provides measurements such as Brightness probe gray level from 0 to 255 Window area measurements from 0 to 61 696 pixels X amp Y gauge measurements from 0 to 255 Line gauge measurement results as values from 0 to 255 The informat
118. ne Gauge Tasks The tasks to be performed in the Line Gauge menu branch are listed below Set X Y Float position compensation Enable X Float line gauge for horizontal compensation Enable Y Float line gauge for vertical compensation Set Float order X first or Y first Set Line Gauges 1 through 22 Enable line gauges Set line gauge direction horizontal or vertical Enable disable X Y float compensation Select image to be measured 1 2 3 or 4 e Set Line Gauge Position e Set Line Gauge Size Select Line Function Select Blob Color Set Line Gauge Hi Lo Acceptance Ranges Set Line Gauge Filter Note See Chapter 3 VIM System Theory of Operation for a full explanation of the operating principles of the line gauges A full understanding of these important basics is essential to the effective setup and use of line gauges Chapter 7 User Interface Reference Section Soe The Line Gauge The Line Gauge Main Menu allows you to set up the X Y Main Menu Float gauges and the twenty two measurement line gauges S eN Ee ETC ES The first two lines to be set are the X and Y Float line gauges These gauges measure key locations on the workpiece to measure variations in workpiece position from one inspection to the next The X Y Float icons are indicated by X and Y letters displayed in the select line icon The X Y Float function can be enabled or disabled for each line gauge The twenty two general pur
119. ng width of the largest blob width of the left top blob width of the right bottom blob Chapter 3 VIM System Theory of operation adi Line Gauge Area Measurements including Measurements count white pixels continued count black pixels Blob Counts including count white blobs count black blobs Edge Count The measurement descriptions provided apply to both horizontal and vertical line gauges Vertical line gauges read from top to bottom Left top blob and edge references apply to both Left most and top most blob and edge Right bottom blob and edge references apply to the right most and bottom most blob and edge Left and right edge references apply to the top and bottom edges respectively Line Gauge The line gauge measurements are grouped into pairs You Measurement Pairs may select one of nine different icons each with a different measurement pair They are as follows Line Gauge Function One measures 1 the left top edge of the largest blob 2 the width of the largest blob Line Gauge Function Two measures 1 the right bottom edge of the largest blob 2 the width of the largest blob Line Gauge Function Three measures 1 the center of the largest blob 2 the width of the largest blob Line Gauge Function Four measures 1 the left top edge of the left top blob 2 the width of the left top blob Line Gauge Function Five measures 1 the center of the left top blob 2 the width of the left top bl
120. ns related to a menu An example of the ETC Icon is seen in the Line Gauge Main Menu Figure 6 9 Figure 6 9 ETC icon as Seen on the Line Gauge Main Menu S Ic i Ki Ce The ETC Icon also appears on the ETC Line Gauge Main Menu shownin Figure 6 10 Picking the ETC Icon here returns you to the Line Gauge Main Menu Figure 6 10 ETC Icon as Seen on the ETC Line Gauge Main Menu The Arrow Icons control the position of vision tools that are overlayed on top of the video image during setup The Arrow Icons typically appear in sets of two or four They allow you to control the position Figure 6 11 and size Figure 6 12 of the vision tools On some menus arrows are used to increase and decrease the value of numbers The Up arrow adds to the number and the Down arrow subtracts Figure 6 11 The Window Move Menu Arrow Icons Used to Move Window Position NN oa GS SS kO t Chapter 6 Introductionto the User Interface 6 5 Commonly Used Icons continued Figure 6 12 The Window Size Menu Arrow Icons Used to Change Window Size EJ gt lt lt er E Removing Icon Strips and Displaying Analog Images Changing the Run Time Display You may occasionally need to look at the image underneath the icon strip You can remove the menu strip by picking the light pen on any bright spot in the top half of the screen You may also at times need to see the direct video picture from the camera For example when you need to foc
121. ntinued Figure 2 3 The VIM Module installed in a Standalone Rack Configuration Many different VIM module configurations can be stored by the PLC controller and the appropriate configuration downloaded into the module when needed The configuration and results data may be remotely managed through a Data Highway The Allen Bradley Data Highway extends the capabilities of programmable controllers by letting them exchange data with each other and with other intelligent devices The VIM Module as a Stand alone Vision System The VIM module may be installed as a stand alone vision system This configuration requires a 1771 VO rack and power supply in addition to the VIM module and camera hardware Figure 2 3 P Chapter 2 Introduction to the Vision Input Module VIM 2 Hardware Features continued Figure 2 4 Vim Module I O Paths VIM module PLC a controller RESULTS BLOCK Vision analysis results Measurements decisions buho Measurement Values Stored in volatile RAM H HRH Pictures SPE ORE TION Configuration d Setup data window positions line gage functions and Hi Lo Range Values Reconfiguration data Y Stored in nonvolatile EEROM Q Light Pen TRIGGER BUSY STROBE DECISION Clara Swingarm discrete lines for Standalone and Direct 1 O Chapter 2 Introduction to the Vision Input Module VIM 5y Vision Input Module The following section provides descriptions of the Vision Hardware D
122. ntrast controls should be set for normal viewing If set too dim the light pen will not be able to pick If too bright the wrong icon may be picked Strobe Light The Strobe light trigger input is wired to Swingarm Connection terminals 5 and 6 For additional installation information refer to the manufacturer s guidelines Swingarm This section describes the Swingarm I O connection device Each individual Swingarm connection is discussed as well as the installation procedures for the Swingarm itself Shielded cables reduce susceptibility to electrical noise and interference and are highly recommended for use on all I O connected to the swingarm Swingarm Connections The Swingarm see Figure 5 10 is a detachable I O connection device This convenience enables you to remove or replace modules from your VO rack without having to rewire the connections 5 12 Chapter Swingarm Connections continued 5 Installation and Integration Figure 5 9 Swingarm Field Wiring Terminals Terminal Function 1 Camera Power Input Camera Power Common Trigger 24VDC Input Trigger Common Strobe 5V TTL Output Strobe Common Decision Output Decision Common Busy Output N Ww WIN o Busy Common paa No Connection No Connection Use With 1771 WB Wiring Arm WARNING Remove system power before attempting installation Failure to do so may result in electrical shock Do not use t
123. number of black pixels on the line This function is not affected by the setting of the Select Blob Color or Select Line Filter icons This function is not available for the X and Y Float line gauges Chapter 7 User Interface Reference Section The ETC Line Gauge The Line Function Nine Icon Menu This function counts the continued 1 total number of blobs 2 total number of edges black white transitions T This function is not available for the X and Y Float line gauges The Select Blob Color Icon This icon is used to select the color black or white of the blobs to be measured For example if black blob color is selected along with function number one the left or top edge and width of the largest black blob is measured If white blob color is selected the same measurements is made on the largest white blob See Chapter 3 VIM System Theory of Operation for complete details on blob finding and blob measurement The Measure White Blobs Icon This icon indicates that measurements are being performed on white blobs Picking this icon will toggle it to the Measure Black Blobs state The Measure Black Blobs Icon This icon indicates that measurements are being performed on black blobs Picking this icon will toggle it to the Measure White Blobs state Chapter J User Interface Reference Section PET The ETC Line Gauge The Line Hi Lo Range Menu Access Icon Menu Picking this icon
124. oat functions Picking this icon toggles it to the disabled state ee ef y C a ad The ETC Icon Picking this icon moves you to the ETC Window Main Menu The OK Icon Picking this icon returns you to the Main Menu Chapter 7 User Interface Reference Section The ETC Window The ETC Window Main Menu provides access to the Menu Window Move Window Size and Window Range menus It also provides the option of performing window measurements based on white or black pixels Ee ol ETC The Window Move Menu Access Icon Picking this icon moves you to the Window Move menu The Window Size Menu Access Icon Picking this icon moves you to the Window Size menu The Measure White Black Areas Icons Windows function by counting pixel area within the windowed area The window may be set to measure either the black area or the white area The Measure White Area Icon This icon indicates that the window is set to measure the white area The total number of white pixels within the window is counted and the resultant number used as the measurement value for the window Picking this icon toggles it to the measure black area state Chapter J User Interface Reference Section 7 52 The ETC Window The Measure Black Area Icon Menu This icon indicates that the window is set to measure the continued black area The total number of black pixels within the window is counted and the resultant number used as the measurement
125. ob Chapter 3 12 Line Gauge Measurement Pairs continued Edge Measurements 3 VIM System Theory of Operation Line Gauge Function Six measures 1 the right bottom edge of the right bottom blob 2 the width of the right bottom blob Line Gauge Function Seven measures 1 the center of the right bottom blob 2 the width of the right bottom blob Line Gauge Function Eight counts 1 the number of white pixels 2 the number of black pixels Line Gauge Function Nine counts 1 the number of black or white blobs 2 the number of edges Both measurements in a pair are active when they are assigned to a line gauge You should assign an acceptance range to both of the measurements using the Line Hi Lo Range Menu The acceptance range acts as a accept reject test of the measurement Measurements that fall within the acceptance range high and low limits are good Measurements that exceed these limits are out of range and a REJECT decision is communicated The principles behind these line gauge measurement techniques are explained in the following sections Edge measurements find the edges of blobs on the line left or right top or bottom The edge measurement is selected by using the icon interface to scroll to the desired measurement set You read edge location settings by identifying the location of the top arrow in the icon The icon displays a set of either two or three linear blobs The three blob set indicates me
126. of lenses to suit your applications Determine the required field of view The field of view FOV is the area that the camera sees It should include every feature of the workpiece to be inspected Take into consideration any variation in workpiece position that might move features of interest out of the FOV and set your FOV size to accommodate it Note The image array in the camera has an aspect ratio of approximately 3 to 4 This means that the X axis of the image is longer than the Y axis The Y axisis approximately 75 of the length of the X axis see Figure 4 6 Chapter 4 Staging for Vision Applications Selecting the Lens for Your Application continued Figure 4 6 Aspect Ratio 3 4 Aspect 75 of X Determine the Standoff Distance Determine your ideal camera and lens standoff distance away from the part This is often dictated by a clearance requirement to stay out of the way of moving machinery or workpieces Sometimes it is limited by available floor space or ceiling height or by a requirement to shroud the workstage It might also be the standoff distance that is simply the most convenient for setup and maintenance e Determine Accuracy Determine the accuracy to which the object must be measured Determine the Need for Extension Tubes Some lenses need an extension tube to focus at close distances The extension tube is placed between the camera and lens If an extension tube is needed ata
127. on is active turned on An example of this is shown with the Strobe Icon Figure 6 5 amp 6 6 Figure 6 5 Strobe Enabled Icon Figure 6 6 Strobe Disabled Icon Some icons are seen in several menus The OK ETC and Arrow icons appear on many menus We can use these icons to illustrate how the icon and menu combination works to make the VIM module interface easy to use OK Icon The OK Icon is used to exit a menu and return to the previous menu This icon appears on many menus It s used to leave a menu after a tool is set up and the settings are acceptable Repeated selection of the OK Icon returns you to the Main Menu at the top of the menu branching tree If the OK Icon is selected at the Main Menu level all current configuration settings are saved into the module s non volatile EEPROM memory and the system returns to normal operation Figure 6 7 OK Icon bii Chapter 6 Introduction to the User Interface Commonly Used Icons ETC Icon continued The ETC et cetera Icon is used to display additional menu options when all of the icons related to a tool cannot be displayed on one menu The second menu or sub menu also has an ETC icon selecting it returns you to the original menu Figure 6 8 E J ETC et cetera Icon The ETC Icon typically appears toward the right end of the menu next to the OK Icon Picking the ETC Icon moves you to the rest of the ico
128. orkpiece are detected through brightness variations in the patch Pr Chapter 3 VIM System Theory of Operation The Probe Reference Patch continued Figure 3 7 The Probe as Seen in the Video Monitor During Setup Figure 3 8 The Probe Reference Patch Seen in the Live Video image Chapter 3 VIM System Theory of operation ag The Probe Reference Patch It is recommended that you carefully prepare the object to be continued used as the reference patch when using lighting compensation Suitable materials for the patch include white adhesive labels and white correction tape Line Gauges Line Gauges are used extensively in the VIM module The Line Gauges operate on any of the four binary images The basics of line gauge operation are reviewed here before proceeding to the specific line gauge measurement tools Line Gauges operate by taking a predefined sample from a row or column in the image The line gauge is referred to as a horizontal line gauge when taken from a row or asa vertical line gauge when taken from a column Figure 3 9 Pixels and Corresponding Digital Values Row of Line Gauge Pixels amp Corresponding Digital Values The sampled line from the image is a string of 0 s and I s corresponding to the value of the pixels along the line This is illustrated by comparing pixel representations with their corresponding values as shown in Figure 3 9 The Line Gauges operate by analyzing these strings of bi
129. ost mispositioned wrinkled or folded labels Figure 2 14 Line Gauge Check for Proper Label Position Chapter 2 Introduction to the Vision Input Module VIM 2 16 Applying the VIM Measurement Example 4 Vision Tools Inspection of Stripped Wire Dimensions continued In the manufacture of cable harnesses wires are cut to length stripped attached to connectors and bundled together Since the wire stripping process feeds the connector attachment process improperly stripped wires cause jams and other problems for the connector attacher Positive verification of proper wire stripping is thus a valuable control Figure 2 15 Stripped Wire Image Showing Line Gauge Placement Line Gauge 1 Line Gauge 2 Line Gauge 3 Line Gauge 4 Line Gauge 5 In this application a single stripped wire end is silhouetted back lit in front of a camera so that the entire bare conductor strand and part of the insulation are visible In Figure 2 15 line gauge inspections are made which 1 Verify that the correct wire diameter is being run for this lot 2 Confirm that the correct amount of insulation has been removed 3 Verify that the conductor has not been severed damaged or bent 4 Confirm that an appropriate length of bare conductor is exposed Since the silhouetted image has high contrast between the wire and its background a single binary threshold produces a clear image of the wire Image quality is relatively
130. p definition required for precision measurements If you wish to inspect features at different distances from the camera you may want to increase the depth of field depth of focus of your lens To do this you narrow the aperture increase the F stop setting and add more light to the workstage to compensate for the loss of brightness You can also restrict the depth of field to defocus a busy background In any case experimentation is critically important Image contrast is extremely important to the successful application of the VIM module An ideal contrast situation can be created through the use of backlighting Back lighting illuminates the object from the rear The workpiece blocks the light and appears as a solid black silhouette against a bright white background This distinct contrast in gray scale from the very dark object to the very bright background makes it very easy to set an acceptable threshold and makes the vision system relatively insensitive to small variations in light level Features that have only minor variation in gray scale intensity low contrast are more difficult to separate When setting up your application try to create as much crisp well focused contrast as possible between features of interest and the background This ensures that the thresholds will be easily set and that consistent measurements will be obtained We have seen that sharp focus and contrast are key elements in image formation
131. played near the bottom of the screen The menus contain sets of icons related to specific tasks and also contain icons which take you to other menus The following menu Figure 6 2 is typical of the menus you ll see on the VIM module video monitor Figure 6 2 The Main Menu Shown as aTypical Icon Menu Be m fi Cg Ot Icon Symbolism Each icon is designed to symbolically represent the function which it controls For example a shining light icon Figure 6 3 is used to access the Brightness Menu Branch starting with the Brightness Main Menu Icons help you to understand vision tasks and complete them easily Figure 6 3 Brightness Main Menu Access Icon Menu Access Icons Icons that provide access to sub menus have an angular cut on the lower right corner This represents a corner being cut off to reveal further menu layers below These icons are referred to as Menu Access icons The cut corner on the Window Main Menu Access Icon Figure 6 4 located on the Main Menu Figure 6 2 shows that further menus can be accessed by picking it Figure 6 4 Window Main Menu Access Icon Chapter How the Icon System Works continued Commonly Used Icons 6 Introductionto the User Interface aS Enable Disable Slash A feature common to several icons is the Enable Disable slash The Enable Disable slash is a diagonal line that appears over the icon when the function is disabled turned off No slash appears when the functi
132. pose line gauges are available to perform general measurements These gauges are enabled on the Line Gauge Main Menu and configured in the Line Move Line Size and Line Hi Lo Range menus These menus are accessed through the ETC Line Gauge Main Menu and the corresponding menu access icons The Line Number Icons This icon identifies the number or name X or Y of the line gauge which is being displayed Picking the icon increments the display to the next line gauge Holding the light pen against the icon will cause the icon to rapidly scroll through the line gauge set The sequence is X Y 1 2 3 JA The X Float Line Gauge Icon The X Float Line Gauge Icon is used to measure the position of the workpiece in the X axis The variation from the work piece s normal or nominal position is applied to other line gauges and windows The X axis is the horizontal left right axis on the display monitor The X Float line gauge must be positioned and sized so that the reference feature or edge is detected throughout the anticipated range of X axis position variation Pa 2 Chapter 7 User Interface Reference Section The Line Gauge The Y Float Line Gauge Icon Main Menu The Y Float Line Gauge Icon is used to compensate for continued variation in workpiece position in the Y axis The Y axis is the vertical axis on the display monitor The Y Float line gauge must be positioned and sized so that the reference feature will be detected
133. pter 5 Installation and Integration 5 23 Ey Bit Manipulation continued Figure 5 14 PLC Bit Manipulation Menu Used to Force Control Bits BIT MANIPULATION WORD ADDRESS 0011 BIT NO 17 16 15 14 13 12 11 10 07 06 05 04 03 02 01 00 STATUS 0 O 1 0 0 0 00 100 1 1 10 1 FORCE REMOTE PROG MODE In this example the 0011 is used as the word address The address you use will be determined by the location of the VIM module in your chassis rack Bit Manipulation Example 1 Locking and Unlocking the VIM Module Move the cursor to the Unlock bit number 10 Press 1 to unlock the module and enable light pen programming The video monitor will display the unlock banner Press 0 to lock the module and disable programming The unlock banner will disappear from the video monitor The Unlock output bit is used to control access to the VIM configuration data When the operator wants to enter the setup mode the PLC controller must set this bit high When the operator unlocks the VIM module with the light pen the set up session is started Note As long as the Unlock bit is set low 0 the module s configuration data is safe from unauthorized modifications Chapter Installation and Integration 5 24 j 5 I Bit Manipulation Example 2 Rapid PLC System Triggering of the VIM Module A simple two rung program can be used to rapidly trigger the VIM system inspection cycle see Figure 5 15 In this program the BUSY bi
134. r Function Status of Line Gauge 5 Lower Function Status of Line Gauge 5 Upper Function Status of Line Gauge 6 Lower Function Status of Line Gauge 6 Upper Function Status of Line Gauge 7 Lower Function Status of Line Gauge 7 Upper Function Status of Line Gauge 8 Lower Function Status of Line Gauge 8 Upper Function Status of Line Gauge 9 Lower Function Status of Line Gauge 9 Upper Function Status of Line Gauge 10 Lower Function Status of Line Gauge 10 Upper Function Status of Line Gauge 11 Lower Function Status of Line Gauge 11 Upper Function Status of Line Gauge 12 Lower Function Status of Line Gauge 12 Upper Function Status of Line Gauge 13 Lower Function Status of Line Gauge 13 Upper Function Status of Line Gauge 14 Lower Function Status of Line Gauge 14 VALUES 5 37 The Indicates Values Affected by the Binary BCD Discrete Bit Setting 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Reject or Error Rej
135. reshold 4 X Y Float Status Disabled 1 Enabled Line Status Flag Disabled 1 Enabled Line Direction Flag Horizontal 1 Vertical White Black Count Selection Black 1 White Reserved for Future Expansion ero Line Function Code alue of 0 to 8 Left Edge amp Width of Largest Blob Right Edge amp Width of Largest Blob Center amp Width of Largest Blob Left Edge amp Width of Leftmost Blob 4 Center amp Width of Leftmost Blob 5 Right Edge amp Width of Rightmost Blob 6 Center amp Width of Rightmost Blob 7 Count White amp Black Pixels 8 Count Number of Blobs amp Number of Edges 0 NoFilter 1 Filter 1 2 Filter2 0 0 0 0 Z V 0 1 2 3 Line Filter Code Reserved for Future Expansion Reserved for Future Expansion Zero Selected Threshold Number 0 Threshold 1 1 Threshold 2 11 15 16 20 21 25 36 40 46 50 5 46 Chapter 5 Installation and Integration Table 5 E CONFIGURATION BLOCK 3 OF 3 Block Length of 63 Words WORD FUNCTION VALUES 16 Bits AL a Ur asan tonfauavonbtaForuneGowse22 some Aaigmmersas waa KAKA OOO a es faowonen Ce o beo Jao TA Chapter Chapter Objectives The Icon Interface 6 Introduction to the User Interface The objective of this chapter is to introduce you to the use of a video monitor and light pen to set up the VIM module You make selections through icons menus
136. rmat HEXADECIMAL DATA MONITOR BLOCK XFER READ MODULE ADDR 110 FILE 1000 1034 POSITION FILE DATA 006 0009 007 0000 008 0001 009 O80F 010 0010 011 0000 012 0000 013 00BF 014 0025 015 00B8 016 0013 017 OOAD 018 0010 019 002F 020 1013 RUN PROGRAM MODE Block Transfer There are four numbering systems used with programmable Numbering Systems controllers They are Binary Decimal Octal Hexadecimal These numbering systems differ by the counting base used and the resultant differences in place values The decimal octal and hexadecimal numbering systems are represented by binary bit sets at the PLC controller level and converted for display This coding is referred to as binary coded decimal BCD binary coded octal BCO and hexadecimal Chapter Installation and Integration REY Block Transfer Numbering Systems continued Figure 5 21 Binary Numbering 128 064 032 000 008 004 002 1x20 001 Base 10 value 23949 ee ce ee ean An 8 Bit Byte Two Bytes Per 16 Bit Word Binary Format The binary numbering system uses a number set that consists of two digits the numbers 0 and 1 All information in memory is stored as an arrangement of 0 s and 1 s Each digit in a binary number has a certain place value expressed as a power of two The decimal equivalent of a binary number is computed by multiplying each binary digit by its corresponding place value and adding these number
137. ror 9 Lower Function Status of Line Gauge 19 0 Accept 1 Reject or Error Upper Function Status of Line Gauge 20 0 Accept 1 Reject or Error Lower Function Status of Line Gauge 20 0 Accept 1 Reject or Error Upper Function Status of LineGauge21 0 Accept 1 Reject or Error Lower Function Status of Line Gauge 21 0 Accept 1 Reject or Error 1 1 0 15 0 15 0 15 0 15 0 15 10 0 15 gt 0 15 12 13 0 15 0 15 0 15 0 15 0 15 15 16 17 0 15 18 19 0 0 15 0 15 ao 0 15 0 15 0 15 N 1 N N N WwW 0 15 WORD 16 Bits N mT N N STO wn amp win Oj o Wi wow wit wl w HlpujhPi win W oO 39 aJ AJAJ A W n oO VI PIA Ww Ww N oO 00 N n N gt i 00 uri WU N ma BIT Decimal 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 0 15 Appendix B Results Block Format RESULTS BLOCK 1 OF 1 Block Length of 59 Words The Indicates Values Affected by the FUNCTION Binary BCD Discrete Bit Setting Lower Function Result of Line Gauge 5 j Value of 0 to 255 Upper Function Result of Line Gauge 6 Value of 0 to 255 VALUES is Appendix B Results Block Format RESULTS BLOCK 1 OF 1 Block Length of 59 Words The Indicates Values Affected by the WORD BIT FUNCTIO
138. s continued Setting a range limit for pixel counts limits the amount of black or white pixel variation that is tolerated before a reject decision is made This tolerance is expressed in pixels i e the count may vary by plus or minus four pixels There are three steps to setting the range limit Step 1 Place a nominal workpiece in the workstage Select the Count White Black Pixels measurement in the Hi Lo Range menu and take a reading of the pixel count Step 2 Determine the amount of variation that can be tolerated in additional pixels and add this value to the nominal count Set the high range limit to this value Note One method of determining this value is to use the reading from a barely acceptable workpiece Step 3 Determine the amount of pixel variation that can be tolerated less than the nominal count Subtract this value from the nominal value Set the low range limit to this value Note One method of determining this value is to use the reading from a barely acceptable workpiece A range of or 10 pixels for a nominal count of 95 appears as 85 lt 95 lt 105 Count Number of Blobs The Count Number of Blobs function counts the black or the white blobs on the line This count is not related to any blob features such as edges or widths This function is useful for example for counting the number of teeth on a comb Measurement Technique The Count Black White blobs function counts the number of black or
139. s together as shown in Figure 5 21 When PLC output bit 16 is set to 0 the results block data will be transferred in binary format unsigned integer Each block contains up to 64 16 bit words Each word contains one or more numbers Chapter Installation and Integration 5 34 par 3 7 Block Transfer The formats of the results and configuration blocks are Numbering Systems 5 detailed in the tables at the end of this chapter continued Figure 5 22 BCD Word Format BCD3 BCD2 Scale Factor 3 Digit BCD Value BCD Format BCD words as applied in the VIM system have two parts the scale factor and the value The scale factor is used to allow a greater range of numbers than is possible with only three digits The bits in the scale factor allow the transfer of numbers that are 10 and 100 times greater than the three digit value represented in the three digit BCD value The format of the BCD word is shown in figure 5 22 The Scaling factors represented by the four scale factor bits bits 12 through 15 are W is Not Used X is Not Used Y is set to 1 if the value is 1 100 the actual value Z is set to 1 if the value is 1 10 the actual value The remaining 12 bits are assigned in groups of four one group for each digit This is because it takes four binary number places to reach a decimal count of 9 The numbers displayed in the BCD mode are three digit unsigned decimal integers of 0 through 9 The BCD bits are assigned
140. s Menu Access Icon Picking this icon moves you to the Brightness Main Menu The Line Gauge Menu Access Icon Picking this icon moves you to the Line Gauge Main Menu The Window Menu Access Icon Picking this icon moves you to the Window Main Menu The Select Trigger Icons The external trigger is an input which signals the system to take a picture make measurements on it and output the results You may select triggering from the PLC controller or through a switch or sensor connected to the swingarm Picking the icon causes it to toggle to the other trigger input mode Chapter 7 VIM User Interface Reference Section The Main Menu The PLC Trigger Icon continued The PLC Trigger Icon indicates that the VIM module is set to respond to the trigger bit bit 15 from the host PLC controller When this mode is selected the swingarm trigger input is not active Picking the PLC Trigger Icon toggles it to the swingarm trigger state PLE TRIG The Swingarm Trigger Icon The Swingarm Trigger Icon indicates that the VIM module is set to be triggered from switch or sensor inputs wired to the swingarm Picking this icon toggles it to the PLC trigger state Note Swingarm triggering must be used when no PLC controller is present Stand alone mode The Troubleshooting Icons The VIM module has three troubleshooting modes These functions help in applications development by stopping the module or by capturing an image when a reject occurs
141. s continues until all of the lines are scanned Figure 3 2 Image Scanning Pattern and Image Coordinates X LINE SCAN ROWS Scan Row 11 Scan Row 12 D l R E C T l o N Y SCAN 252 a gt 252 233 X 4 eX DIRECTION Image Coordinates Images are often discussed in terms of the X and Y axes These coordinate references help you to keep track of positions and measurements see Figure 3 2 The X axis corresponds to the horizontal rows The positive X direction is to the right corresponding to the scan direction The negative X direction is to the left The positive Y direction is in the downward direction corresponding to the downward line scan sequence The negative Y direction is toward the top of the image All X Y coordinate values are positive Chapter 3 VIM System Theory of operation T Gray Levels Each pixel in the image array generates an analog signal that corresponds in strength to the brightness of the light The pixel output is converted to a digital value for use by the digital computer system in the VIM module This conversion of the array s analog signals into digital values is known as analog to digital A D conversion Gray Scale Conversion The analog signal is converted into a set of digital values referred to as gray scale This term refers to the fact that the conversion process creates classifications for black pixel values through a wide range of gray values all the way to whi
142. s desired oi api Chapter 7 User Interface Reference Section The Line The Select Increment Icon Hi Lo Range Menu Thisicon modifies the amount by which the high and low continued range limits are increased or decreased Each pick of this icon toggle between increments of 1 and 10 Pick the icon to toggle to the desired increment H The Upper Lower Function Select Icon This icon is used to select which measurement in the measurement pair will be displayed either upper or lower Both of the measurements should be assigned an acceptance range but only one at time is displayed Both measurements will be made and evaluated during inspection Picking the icon toggles between the upper and lower measurements dli The OK Icon Picking this icon returns you to the ETC Line Gauge Main Menu Chapter J User Interface Reference Section 7 43 The Line Hi Lo Range Menu CAUTION On the X and Y line gauges continued entering the Hi Lo Range menu will resample the nominal edge positions for the workpiece currently being viewed After exiting either of these Hi Lo menus review the positions of the windows and other line gauges to make sure that they are still reasonable The Hi Lo Acceptance Range Display This display shows the values of the High and Low Acceptance Range Limits and the actual measurement value for the line gauge The Low Range Limit The Low Range Limit is the lowest acceptable value for the meas
143. s for 1771 VO Chassis and Power Supply and 1770 4 1 Grounding and Wiring Guidelines These documents must be read before attempting installation Power Supply Installation Many PLC system power supplies are available for use by the VIM module For information on the installation of specific power supplies refer to the documentation accompanying that power supply as well as Cat No 1770 4 1 Grounding and Wiring Guidelines VIM Module Installation This section describes the installation procedures for the VIM module Keying Band Installation Keying Bands are shipped with each I O chassis Each backplane socket should be keyed to accept only the designated type of I O module in this case the VIM module assigned to that slot Keying guards against the wrong module being installed in the wrong I O rack slot Each VIM module plugs in to four sockets on the backplane two per slot Keying bands are installed on the top right socket The socket has guide numbers along the right side to aid in the positioning of the keying bands Keying band locations for the VIM module are between numbers 16 18 and 26 28 see Figure 5 1 Keying bands may be installed with needle nose pliers and are easily replaced Chapter 5 Installation and Integration VIM Module Installation continued Figure 5 1 Installation of Keying Bands Keying Bands Backplane Socket Setting the O Chassis Configuration Plug Many 1771 V
144. s icon moves you directly to the Window Move Menu without having to return to the ETC Window Main Menu The OK Icon Picking this icon returns you to the ETC Window Main Menu Chapter J User Interface Reference Section The Window The Set Window Hi Lo Range Menu is used to set the Hi Lo Range Menu acceptance range for the window measurements TE bar BEY ac saczae Note The acceptance range places limits on the pixel area which is accepted This value is based only upon the total number of pixels in the windowed area and is not directly correlated to shapes dimensions or the number of objects within the window The Icons will flash when the Low or High Range Limits reach the end of the possible range or become equal to each other The Increase Value Icon The active underlined range limit is increased by one increment each time this icon is picked Use the Select Increment icon if a larger or smaller increment is desired ir The Decrease Value Icon The active underlined range limit is decreased by one increment each time this icon is picked Use the Select Increment icon if a larger or smaller increment is desired Ka The Select Increment Icon This icon modifies the amount by which the high or low range limit is increased or decreased Each pick of this icon scrolls through an increment list of 1 10 100 and 1000 Pick the icon until the desired increment is displayed 1 7 58 Chapter 7 User Interface R
145. s measure surface area by counting the number of black or white pixels in the window You teach the VIM module the proper pixel count using a good nominal workpiece A specific feature to be measured such as a screw label or hole gives a specific pixel count reading The reading is proportional to the surface area of the feature in the window You select the pixel color you want to count then set an acceptance range that checks the measurement and makes an accept reject decision Application Example 1 Window Used to Test Punched Holes Punched hole presence absence is a simple example ofa windowing application The task is to check for the presence absence of a hole in a workpiece The hole is backlit and appears as a white circle A window is set to view the area where the hole should be found the window is seen as the gray area over the hole in the part Ifthe hole is not large enough or fails to clear through the part there will be too few white pixels in the image The VIM module is taught the proper hole size during setup using a known good nominal part The acceptance range limits are then set to detect when there are too many or too few white pixels and to output an accept reject signal Figure 2 12 shows an acceptable hole which has been set up for verification using a circular window The Hi Lo acceptance range limits are set to 1100 and 1500 The actual measurement reading of this hole is 1338 Figure
146. s that its location will not change Picking this icon will toggle it to the enabled floating Pt Note You must enable the X or Y line gauge or both before any other tools can float The X Y Float Enabled Icon The X Y Float Enabled Icon indicates that the line gauge position will be adjusted according to measurements from the X and Y line gauges The three lines symbolize waves on top of water and the floating movement of the line gauge Picking this icon toggles it to the disabled anchored status ae _ The X1Y2 Icon This icon only appears on the Line Gauge Main Menu for the X and Y Float line gauges It is used to set the order in which the float calculations are made This icon sets the order to X Float first and Y Float second 1 T Chapter 7 User Interface Reference Section 759 The Line Gauge The Y1X2 Icon Main Menu Thisicon only appears on the Line Gauge Main Menu for continued the X and Y Float line gauges It is used to set the order in which the float calculations are made This icon sets the order to Y Float first and X Float second Yi ro ace The Image Number Icon The Image Number Icon toggles through the four thresholded images Each line gauge should be set to use the image that provides the sharpest image of the feature of interest and the best measurement results Each image is displayed as you pick the icon and its threshold number appears Pick the icon until the desired image is displa
147. sers who are familiar with PLC systems will find the VIM Vision Input Module module to be a natural extension of their PLC tool kit continued The VIM module Cat No 2803 VIM1 is a dual slot intelligent O module which mounts into a standard 1771 VO chassis The VIM module can be integrated into your process to inspect products and provide direct feedback to the system s PLC terminal for closed loop process management The VIM module can also be operated as a standalone vision system j System The VIM module comes complete with a set of image Functional Features analysis tools which perform vision tasks These tools let you make four window measurements brightness measurements and twenty two line gauge measurements These capabilities are combined with the ability to close the process loop through communications to PLC systems The vision tools are easily set up and controlled through icons displayed on the screen You simply pick the icon that corresponds to the function you want to activate by pressing the tip of the Light pen against it The icons appear in logically organized groups called menus The menus branch into other menus to allow you to complete different set up procedures Some notable features of the VIM module are Twenty Two Line Gauge Measurements Line gauges may be set to perform any of fifteen different measurements These include a variety of blob measurements for edge center and width They al
148. so include counting operations for counting blobs black or white pixels and edges The line gauges are assigned in pairs of measurements that complement each other You may assign an acceptance range to line gauge measurements for accept reject decisions Four Window Measurements You may use up to four inspection windows to inspect areas of interest in the image Each window corresponds to one of the thresholded images The windows measure surface area by counting black or white pixels Each window may be assigned a high low acceptance range for accept reject decisions Chapter 2 Introduction to the Vision Input Module VIM 2 3 Functional Brightness Measurement Features The brightness probe may be used to measure the continued brightness of the workpiece or product and to make an accept reject decision This tool might be used to test the intensity of a light or the brightness of a painted surface Multiple Threshold Settings The VIM module makes measurements based upon four binarized images Four independent binarization thresholds may be set to provide four different versions of the video image for inspection tasks This versatility allows you to enhance features that appear at different gray levels Automatic Part Position Variation Adjustment Two line gauges are used to automatically adjust for variation in the workpiece s position in the image This allows you to maintain measurement accuracy despite small variations
149. ss foor foo foo oF nore voza cans banas oon wi one ooro foon foose oof oF vi wore oons core owa ocos2 p p ev wr nore oag oor Joos ooo vr ar wore oors ooz oova foor ar 26 none oo ones foor foose pov nono oa 00x3 fowo oon om pi 26 wore Foon ooo foo foo or Misan aor ar wore oos foo oor foo lt vr inn ar none awa oa oor one o rom i im 26 so wore voes ooss oos foo inn sai omm voy sor nore Foose foo oor foon r mm wr Jinn oe oo none voss oor oos oos e amn m imm ov 77 none aasa oor 002 oo smm 19 7 none ar om none oon oos ooze oo or wore 27 nove or oe nore Foor oosa oo oor vor none a froe Foose oes ooo 0038 1 none 2r vow ov aros ores paasa oon we none a aoe fore form ous 00x7 1e wore as wore 7 foes fonse oom aos 1 wore 2 now oe _ Cors ors oos foose 2 none om nore aisa ozsa f oosa oor am wore sr wore oz oer oor oo a now e vow _ ozr osz ooo ores 397 none 7 ame o fos 0375 ows ors a nore or vore No extension tubes
150. st reflected light bounces off of a surface at an angle equal to the angle of incidence angle of approach The camera lens collects the most light if its angle of incidence is along the axis of the Chapter 4 Staging for Vision Applications 4G Indirect Illumination reflected light This bright reflection creates a bright image continued in the camera field of view and is referred to as Bright Field lighting as shown in Figure 4 3 Bright Field lighting often produces glare which may or may not be useful Diffuse Front Lighting Diffuse lighting moves the camera out of the main reflected beam to collect the secondary light that is diffused scattered by the object surface The angle is enough to reduce glare and still catch strong illumination from the diffused light Dark Field Front Lighting Dark field lighting places the camera at such an extreme angle away from the angle of reflection that very little light is reflected or diffused to the camera and a dark image is formed Directed dark field lighting is often used to highlight surface variations such as scratches and pits Backdrops You can often create high contrast between the workpiece and its background simply by providing an appropriate backdrop For example a medium gray object appears light against a black background and dark against a white background You can also place the backdrop far enough from the workpiece that it is out of focus enough to eliminat
151. t 5 35 5 24 Continuous Push button Circuit 5 36 Picking an Icon Using the Light Pen 6 The Main Menu Shown asa Typical Icon Menu 6 Brightness Main Menu Access Icon 6 Window Main Menu Access Icon 6 Strobe Enabled Icon a 6 Strobe Disabled Icon a 6 DAAAAH Amn hwn m Table of Contents 7 Figure Table Title Page 6 7 ko O Gali ao AAP O APA POP PP AA 6 3 6 8 ETC et cetera ICON Kid aaa aalas 6 4 6 9 ETC Icon as Seen on the Line Gauge Main Menu 6 4 6 10 ETC Icon as Seen on the ETC Line Gauge MENG aaa kaan tt oleae eee Moa ies 6 4 6 11 The Window Move Menu Arrow Icons Used to Move Window Position 6 4 6 12 The Window Size Menu Arrow Icons Used to Change Window Size 6 5 6 13 The Three Main Branches of the VIM Menu 6 6 6 14 Menu Branching Diagram 6 9 List of Tables 1 A VIM Module User s Manual Organization 1 1 4 A Lens Selection Table 0 4 13 5 A Discrete Bits Description Decisions 5 19 5 B Results Block 1 of 1 Block Length of 59 Words U 5 37 5 C Configuration Block 1 of 3 Block Length of 30 Words 5 41 5 D Configuration Block 2 of 3 Block Length of 62 Words 5 43 5 E Configuration Block 3 of 3 Block Length of 63 Words
152. t lt ot Window Sizing The windows have different characteristics when changing Characteristics size Each is defined here Keep these characteristics in mind while using the icons on the Window Size menu The Rectangle Window grows and shrinks horizontally from right to left grows and shrinks vertically from top to bottom The Triangle One Window grows and shrinks horizontally from the right grows and shrinks vertically from the top The Triangle Two Window e grows and shrinks horizontally from the left grows and shrinks vertically from the top The Triangle Three Window grows and shrinks horizontally from the right grows and shrinks vertically from the bottom The Triangle Four Window grows and shrinks horizontally from the left grows and shrinks vertically from the bottom The Circular Window grows and shrinks in diameter from the center Note The train through the lens window cannot be modified from this menu The Grow Vertically Icon This icon increases window size vertically Y direction Chapter Window Sizing Characteristics continued 7 User Interface Reference Section The Shrink Vertically Icon This icon decreases window size vertically Y axis ba The Grow Horizontally Icon This icon increases window size horizontally X axis Ng The Shrink Horizontally Icon This icon decreases window size horizontally X axis x The Window Move Menu Access icon Picking thi
153. t the high range limit to this value Chapter 3 VIM System Theory of operation 3 19 Width Measurements continued Step 3 Note one method of determining this value is to find a workpiece that is barely acceptable Then set the high or low range limit to the barely acceptable reading Two workpieces may be necessary one that is almost too big and one that is almost too small Determine the amount of variation that can be tolerated less than the nominal width in pixels Subtract this value from the nominal value Set the low range limit to this value Note one method of determining this value is to find a workpiece that is barely acceptable Then set the high or low range limit to the barely acceptable reading Two workpieces may be necessary one that is almost too big and one that is almost too small A range of or 4 pixels for a nominal width of 20 pixels appears as 16 lt 20 lt 24 Count White Black Pixels The Count White Black Pixels function counts both the black and white pixels on the line This count is not related to the number of blobs on the line A line gauge which counts pixels is like a long thin window Setting the Line Gauge Set the line size position that suits your application Leave enough line to accommodate workpiece position variation pa Chapter 3 VIM System Theory of Operation Cree aN FRR a a B B B aa aaa mp z2 3a aaa Count Black White Pixels Setting Hi Lo Range Limit
154. te The gray scale is characterized by the number of grays that quantified during A D conversion i e 256 Let s look at a simple example of how this works An image is collected and sent to the A D converter The converter is designed to convert into four gray levels In Figure 3 3 we see that dark pixels are assigned a value of 0 Middle gray values are assigned a value of 64 through 128 Bright values are assigned a value of 255 These gray levels provide a measure of light intensity Figure 3 3 Four Grays Converted to Digital Values Gray Hexa Image decimal 3 4 Chapter The VIM Module Gray Scale Binarization of Gray Level Images 3 VIM System Theory of Operation The VIM module converts brightness to 256 gray values This corresponds to the number of values that can be encoded into 8 bits 1 byte This is sometimes referred to as 8 bit gray scale Images displayed in gray scale look like black and white television images with a wide range of grays in the image Figure 3 4 shows a gray scale analog image Figure 3 4 Gray level Analog Image Binarization of images greatly reduces the complexity of the image processing tasks The term binary refers to the two states which may be given to a single bit of information black or white These are ON digital value of 1 and OFF digital value of 0 Using this technique each pixel requires only one bit of information A vision tool known as
155. the DECISION line to get the final status of the inspection 7 Optional The PLC controller performs a block transfer read of the list of measurements the results block It uses these to make more complex decisions or to make process control updates 8 Na The inspection cycle is complete The next cycle can now begin Chapter Installation and Integration 5 28 pter 5 g Typical Inspection Handshake Sequence continued Figure 5 17 VIM Module Handshake Cycles Handshake Sequence with a Short Trigger 1 ms gt Trigger input Busy output Bare i417 250 ms pi i Decision output Handshake Sequence with a Long Trigger 300 ms p l Ciga input usy output AAAH AA T Decision output Inspection Cycle Time Inspection Cycle Time is the elapsed time from the trigger until the inspection is complete The inspection cycle time depends upon the configuration setup the controller and the image Ata minimum it takes 1 60th of a second to receive and process a new image from the camera The module typically can capture an image from the camera and analyze itin less time than it takes for the next workpiece to advance into position on the production line The following section provides timing information which may help you in high speed situations where the inspection cycle time is critical Chapter By Installation and Integration ee Inspection Cycle Time The fastest VIM
156. the VIM module Ensure that proper grounding procedures are followed Refer to Cat No 1770 4 1 Grounding and Wiring Guidelines for correct grounding procedures Chapter 5 Installation and Integration T Indicator Lights The VIM module is equipped with seven indicator lights LED s Light Emitting Diodes The LEDs are located on the front panel of the VIM module see Figure 5 5 and depict the current status of the module The seven lights are discussed below 1 PWR This light is on when the chassis power is on off when the chassis power is off 2 CPU FAULT This light is lit when a possible hardware failure has been detected During normal operation it will be OFF When this light is ON the module does not respond to triggers Note At power up the CPU FAULT LED is illuminated until the reset sequence is complete S CONFIG FAULT This light indicates that the module is not properly configured This can be caused by a loss of memory an inconsistent download or by the loss of a train through the lens mask due to a power outage When this light is ON the module will not respond to triggers The LED is held on at power up until the reset sequence is complete 4 ACQ ERROR Indicates that the camera is not acquiring a satisfactory image The Acquisition Error LED is illuminated when any of these three conditions occur a The brightness probe is out of range This can be caused by
157. the module is processing images The state of this output will be the same as the BUSY LED Terminal 9 is the output terminal and terminal 10 is common Other swingarm terminals accept input signals for triggering and output strobe signals Swingarm terminal assignments are shown in Figure 5 9 Discrete Bit Communications A larger set of discrete bit communications is available to a tothePLC PLC controller The PLC communication structure allows the transfer of 16 discrete bits of information The first eight bits are used for communications control functions and the last eight are used for discrete communications These eight discrete bit lines may be used for both reading input data from the the VIM module to the PLC controller and writing output signals to the VIM module Table 5 A lists the discrete bit assignments for communication between PLC systems and the VIM module Bits are labeled as Input or Output from the PLC controller s point of view Inputs are from the VIM module and outputs are commands from the PLC controller to the VIM module Chapter 5 Installation and Integration sag Discrete BitCommunications Discrete Bit Inputs to the PLC Controller tothe PLC The discrete bit communications to the PLC controller are continued more extensive than those available through the swingarm There are four more communications in addition to the Master Range Alarm and Busy signals These are the Module and Configuration Fault sign
158. this may affect the cycle time somewhat Chapter Installation and Integration 5 30 pre 5 g Inspection Cycle Time continued Figure 5 18 inspection Cycle Times inspection Rate With All Windows Active SwingArm Trigger Activated And No Block Transfers to PLC SPEED XY Lighting Strobe of Inspect Cycles Position Compensation Light Standard PerSecond Compensation Enabled Line Gages S lt lt lt lt lt lt lt lt 2 lt 2Z25 BEST CASE 60 3 FASTEST 30 30 30 30 20 15 12 10 8 WORST CASE 4 SLOWEST 1 N N N N Y Y Y Y Y Y Y lt lt lt lt lt 2 lt lt lt 22 1 Atleast 1 window has XY float option 2 STANDARD line gage is about 4 screen length 64 pixels long medium 1 PIXEL FILTER filter option and simple image The two X and Y source of float gages are not included in number 3 Case only applies to continuous inspections 4 Mode 2 Lighting Compensation FULL IMAGE threshold adjust No compensation or Mode 1 Immediate Brightness Compensation causes no speed penalty General worst case SLOWEST All lines maximum length heavy 2 PIXEL FILTER filter option and complex VERY BUSY image No XY floating windows allowed All 4 line gages are XY floating 5 6 pasig Displaying the To display the contents of the results block place the Results Block blinking cursor on the block transfer instruction and press DISPLAY 0 Figure 5 19
159. throughout the anticipated range of Y axis position variation Note Use of the X Y Float gauges may decrease throughput of the system if floating windows are used The Line Gauge Number Icon This set of the line number icons displays the identification numbers for gauges 1 through 22 The active line gauge number is displayed Only one line gauge may be setup or modified at a time Pa The Line Gauge Enable Disable Icons The X and Y float gauges and the twenty two line gauges may be enabled or disabled individually The Select Line Icon is used to display each line gauge and enable disable them using the Line Gauge Enable Disable icons Picking this icon toggles it between enabled and disabled states Note When the Line Gauge is disabled the other icons on the strip Line Direction X Y Float Select Inage Number and ETC icons are locked and will not respond to the light pen The Line Gauge Disabled Icon This icon indicates that the line gauge displayed is disabled from making measurements Picking this icon toggles it to the enabled state tang Chapter J User Interface Reference Section 7 27 The Line Gauge The Line Gauge Enabled Icon Main Menu This icon indicates that the line gauge displayed is continued enabled for processing Picking this icon toggles it to the disabled state Note You should disable all line gauges which are not used Note When you are using floating tools you may not disable
160. tis used to drive the TRIGGER bit This forms an oscillator which rapidly and continuously triggers the module The VIM module must be set to the PLC TRIG mode at the main menu to enable this program Figure 5 15 Rapid Firing Under PLC Control ae usy 110 12 END 01048 REMOTE PROG MODE The oscillation is stopped when the module is unlocked by rung 1 due to an ACQ ERROR brightness probe out of range The Low Range Limit for the brightness probe should be set to a number greater than 10 to enable the shut off To test this while the program is running disconnect the camera cable You will see that the ACQ ERROR light comes on due to brightness out of range and that inspections will stop To restart the program force the UNLOCK bit back to zero PLC Block Transfer The VIM module is capable of block transfer communi Interface cations with a PLC controller All block transfer requests are initiated by the PLC controller Both read and write block transfers are supported by this module The VIM isa two slot module all block transfer requests must be addressed to the first rack slot that the module resides in Chapter 4 Installation and Integration pi PLC Block Transfer The block transfer read instruction can be used to transfer Interface the Results Block or any of the three Configuration Blocks continued tothe PLC controller Configuration Blocks can only be transferred when the VIM module is not BUSY The R
161. topped You must poke the screen with the Light pen to cycle through all four images and resume operation The picks with the Light pen display each of the four thresholded images in sequence Normal operation continues after the display of all four images CAUTION The VIM module comes to a complete stop when a reject occurs and the Halt on REJECT is enabled Manual action is required to restart the the system and resume operation HI Chapter J VIM User Interface Reference Section The Main Menu The Save Setup Icon Main Menu OK Icon continued The configuration settings for the probe windows line gauges and other setup parameters are saved into memory when this icon is selected The Clock Icon strip appears while the save is being performed The Clock Icon Strip The Clock Icon Strip is displayed while the setup data is being saved to memory The Clock icon prompts you to wait during the short save period about 5 seconds The Clock icon won t respond to Light pen picks The Unlock icon strip is displayed after the save is completed if the unlock discrete output bit is still set to one 1 If the unlock output bit is set to zero 0 the VIM module enters the Active Run mode In Stand alone mode the system goes directly into the Run mode CAUTION The configuration memory will be lost if you turn off power to the module while the clock icon is displayed In this case when power is reapplied the CO
162. urement If the measurement reading is less than the low limit an out of range condition exists and the corresponding range alarm bit in the results block is set to one 1 The Actual Measurement Reading This is the actual measurement made by the line gauge When the reading falls within the acceptance range the corresponding alarm bit in the results block is set to zero 0 The reading may change slightly as you observe live video images due to real time variation in the picture The High Range Limit The High Range Limit is the highest acceptable value for the measurement If the measurement reading is more than the high limit an out of range condition exists and the corresponding range alarm bit in the results block is set to one 1 Note Positional compensation can be applied to a line gauge which is measuring and range checking a blob edge or center position In this case the positional compensation is also applied to the High and Low Range Limit values Note When the X Y positional compensation causes a window or a line gauge to move off the edge of the screen an ACQ ERROR condition exists The red ACQ ERROR light is lit and a REJECT decision is signaled HOY Chapter J User Interface Reference Section The Line In the Hi Lo display line gauges are displayed at their Hi Lo Range Menu anchored nominal position Their position is not floated continued The readings are taken from this anchored position
163. us the lens adjust the viewing angle of the camera or adjust the lighting The direct analog image is best for these purposes The analog picture may also be displayed while the VIM system is operating on line During configuration sequence of picks on the top half of the screen prompts the following results Pick 1 The menu strip disappears from the screen the full digital image is displayed Pick 2 the live video image is displayed this is also called the analog picture Pick 3 the menu strip is redisplayed Note If there is no bright area on the top half of the screen the light pen may not be able to pick In this case turn up the bright knob on the video monitor slightly You can change the display on the video monitor while the module is operating on line performing inspections The act of changing the display does not disturb the inspection process and does not lengthen the inspection cycle time To change the display simply plug the light pen into the front panel and press the tip switch with your finger If your module is locked by a PLC controller you may alternatively touch the light pen to the video monitor You will see the image change Chapter 6 Introduction to the User Interface 6 6 Changing the You may select any one of six displays Each pick of the Run Time Display light pen switches to the next display in the sequence The continued six displays are 1
164. value for the window Picking this icon toggles it to the measure white area state The Window Hi Lo Range Menu Access Icon Picking this icon moves you to the Window Hi Lo Range Menu H i LO The ETC Icon Picking this icon returns you to the Window Main Menu EIL Chapter J User interface Reference Section The Window The Window Move Menu allows you to set the Move Menu position of the windows within the image area lt r IS lt gt ct The Window Move Icons The windows are moved by using the Light pen to pick the Arrow icon corresponding to the direction you want to move in Each pick with the Light pen moves the window one pixel Holding the Light pen against the icon causes a rapid movement of the window in the selected direction The movement icon flashes when the window reaches the edge of the image and cannot go further va GR Note The window must be placed below the top 40 lines of the screen when using the Immediate Brightness Compensation mode vr Chapter 7 User Interface Reference Section The Window The Window Size Menu Access Icon Move Menu Picking this icon moves you directly to the Window Size continued menu without having to return to the ETC Window Main Menu The OK Icon Picking this icon returns you to the ETC Window Main Menu OK Chapter 7 User Interface Reference Section The Window The Window Size Menu allows you to set the size of the Size Menu windows 35 oc l
165. ving them Line Filter One disregards single pixel variations When single pixel filtering is selected the line would then be interpreted as 1111000000000000111100000001111111001 Single pixel noise filtered out Note The dual pixel noise on the right is not removed by Line Filter One Line Filter One requires a minimum of two consecutive pixels to count a blob Line Filter Two Line Filter Two ignores both one and two pixel noise pulses The same line would then be interpreted as 1111000000000000111100000001111111111 t t f One and two pixel noise filtered out Line Filter Two requires at minimum of three consecutive pixels of the selected color to count a blob The left top most pixel on the line is never filtered out The second pixel on the line is filtered out by Line Filter One if both of its neighbors agree Likewise the third pixel is filtered out if both of its neighbors agree This three pixel neighborhood moves along until each pixel has been considered TF Chapter 3 VIM System Theory of Operation XIY Float Gauges X Y Float Gauges use the blob edge or center finding ability of the VIM to detect variation in workpiece location You may use a blob center or edge to measure position variation These measurements are discussed earlier in this chapter The X and Y Float Gauges remember the nominal or normal workpiece position and use the difference between the nominal and the measured position to adjust the location of
166. w Hi Acceptance Range Limit Value of 0 to 62 464 Window Shape 0 Rectangle 1to4 Triangles 5 Circle 6 Through The Lens Window Enable Flag 0 Disabled 1 Enabled X Y Anchored Float Value Flag 0 X Y Anchored 1 X Y Floating Count White Black Pixels Select 0 Black 1 White Brightness Float Status 0 Anchored 1 Floating Binary Threshold Value Value of 0 to 255 Meaning of Word 9 Varies Depending on Window Shape See Word 8 Bits 0 3 Rectangular Window Bottom Rt Cnr Window Corner X Axis Position Column Value of 0 to 254 Window Corner Y Axis Position Row Value of 11 to 252 Triangular Window X Axis Position of Horizontal Leg Y Axis Position of Vertical Leg Column Value of 0 to 254 Row Value of 11 to 252 Circular Window Radius of Circle Reserved for Future Expansion Through the Lens Window Reserved for Future Expansion Value of 0 to 127 Chapter 5 Installation and Integration 5 42 Table 5 C CONFIGURATION BLOCK 1 OF 3 Block Length of 30 Words WORD FUNCTION VALUES 16 Bits kaba ai kon Ipa Window area in Square Pixels Value of 0 to 62 464 Window 2 Data Same as Words 5 10 Bil Configuration Revision Level Chapter 5 Installation and Integration mis Table 5 D CONFIGURATION BLOCK 2 OF 3 Block Length of 62 Words FUNCTION VALUES X Gauge X Axis Start of Line Column Value of 0 to 254 Y
167. windows limits the amount of black or white pixel area variation that is tolerated before a reject decision is made This tolerance is expressed in pixels i e the count may vary by plus or minus 50 pixels There are three steps to setting the range limit Step 1 Place a nominal workpiece in the workstage Take a reading of the pixel count in the window Step 2 Determine the amount of variation that can be tolerated in additional pixels and add this value to the nominal count Set the high range limit to this value Note One method of determining the high limit is to use the reading from a workpiece which is almost too big Step 3 Determine the amount of pixel variation that can be tolerated less than the nominal count Subtract this value from the nominal value Set the low range limit to this value Note One method of determining the low limit is to use the reading from a workpiece which is almost too small A range of or 50 pixels for a nominal count of 495 appears as 445x 495 lt 545 3 26 Chapter 3 VIM System Theory of Operation ERAP td VE I TP a TS PLC Communications The VIM module communicates with the PLC systems Overview through discrete bit or block transfers The Discrete bit transfer sends one accept reject signal to the PLC controller at the completion of the inspection cycle Block transfers send the complete list of measurements and range alarms to the PLC controller Discrete Bit The VIM mo
168. yed You should choose the image in which the specific item to be measured is the clearest and most distinct The ETC Icon Picking this icon moves you to the ETC Line Gauge Main Menu where you may set other line gauge characteristics The OK Icon This icon will return you to the Main Menu stag Chapter 7 User Interface Reference Section aaa sw S N ES P T 66Z6Z Z5Z6Z9Z 5G DZ I i d6 6 6Z6Z6Z656Z6 FT C S 2 j 2rcs858 5 g8 aata This page intentionally left blank Chapter J User Interface Reference Section oe The ETC Line Gauge The ETC Line Gauge Main Menu allows you to set and Menu adjust additional characteristics of the line gauges This includes setting features such as position size measurement type black or white blob analysis Hi Lo acceptance range limits and filter settings Some of these features are accessed through the ETC Line Gauge Main Menu while others are performed directly on the ETC Line Gauge Main Menu The Line Move Menu Access Icon Picking this icon will move you to the Line Movement Menu The Line Size Menu Access Icon Picking this icon will move you to the Line Size Menu The Select Line Function Icons The line gauges each perform two measurements simultaneously These are called the Upper and Lower functions due to their positions in the icon picture Select the measurement pair that best meets your needs for each line gauge Each of the nine measurement pairs is expla
Download Pdf Manuals
Related Search
Related Contents
Samsung NV15 Felhasználói kézikönyv Triarch 31165 User's Manual Mise en page 1 Ami Pro - TP1VLCO.SAM ネットワーク取扱説明書 Mx4000 - Tann Synchronome FireWire Card Il. FEUILLETTE. - Bernard Manual de instrucciones-ES Copyright © All rights reserved.
Failed to retrieve file