Download Bi-i Vision System Programming Guide

Transcript
Table of Contents
1. Introduction ........................................................................................................................................................ 1
2. The AMC Language ........................................................................................................................................... 2
2.1. Introduction ............................................................................................................................................ 2
2.2. AMC Compiler ...................................................................................................................................... 2
2.3. Running AMC Programs ....................................................................................................................... 2
2.4. General Rules ......................................................................................................................................... 3
2.5. Argument Types .................................................................................................................................... 3
2.6. Address Spaces ...................................................................................................................................... 5
2.7. Data Structures ....................................................................................................................................... 5
2.7.1. Images and Other 2D Arrays ..................................................................................................... 5
2.7.2. Vectors ...................................................................................................................................... 6
2.7.3. Templates .................................................................................................................................. 6
2.8. Basic AMC Code ................................................................................................................................... 6
2.9. Image handling ...................................................................................................................................... 6
2.10. Flow Control ........................................................................................................................................ 7
2.10.1. Loop ........................................................................................................................................ 7
2.10.2. Calling Subroutines ................................................................................................................. 7
2.10.3. Tiling ....................................................................................................................................... 8
2.10.4. Definitions And Conditional Compilation .............................................................................. 9
2.11. Avi handling ...................................................................................................................................... 10
2.12. Frame Grabber ................................................................................................................................... 11
2.13. Image Acquisition from the Ibis Sensor ............................................................................................ 12
2.14. ACE16k ............................................................................................................................................. 12
2.14.1. Image And Template I/O ...................................................................................................... 13
2.14.2. Logical Operation .................................................................................................................. 13
2.14.3. Template Execution .............................................................................................................. 14
2.14.4. Image Acquisition ................................................................................................................. 14
2.15. Image Processing Library (IPL) ........................................................................................................ 14
2.16. Profiling ............................................................................................................................................. 15
3. AMCedit ........................................................................................................................................................... 16
3.1. Editing AMC codes ............................................................................................................................. 16
3.1.1. The Editor Window ................................................................................................................. 16
3.1.2. The Info-tree Window ............................................................................................................. 17
3.1.3. Status Bar ................................................................................................................................ 18
3.2. Running the AMC ................................................................................................................................ 18
3.2.1. Selecting the Device ................................................................................................................ 18
3.2.2. Selecting the Workspace ......................................................................................................... 19
3.2.3. Compiling the AMC ................................................................................................................ 19
3.2.4. Running the ABC .................................................................................................................... 19
3.3. Menu Items, Toolbar Buttons and Shortcut Keys ................................................................................ 19
4. The API ............................................................................................................................................................ 23
4.1. Running an Application ....................................................................................................................... 23
4.2. Receiving Messages ............................................................................................................................. 25
4.3. Sending Messages ................................................................................................................................ 26
4.4. Data Transfer ....................................................................................................................................... 26
4.4.1. Data Representation ................................................................................................................ 26
4.4.2. Data Transfer Messages .......................................................................................................... 27
4.4.3. Direct Transfer ........................................................................................................................ 28
4.5. Cooperation with AMC and SDK ........................................................................................................ 28
4.6. .NET Components ............................................................................................................................... 29
4.6.1. Installing the Components ....................................................................................................... 29
4.6.2. Usage of the Components ....................................................................................................... 30
4.7. Parameter generation (ParamTool utility) ........................................................................................... 32
4.7.1. Special comments .................................................................................................................... 33
4.7.2. Parameter Handling Class ....................................................................................................... 34
iii