Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

image processing conflict when two seperate programs run simultaneously

Hi,

we have two seperate NI scripts A & B run simultaneously in one PC, the details as below:

A functions to inspect is there any ball damage in a BGA package device image captured, for example, the BGA package has 769 balls, the software locate each of ball in the image first, then check each ball has damage or not base on some algorithm, IMAQ Create & IMAQ Count object 2 used in the process.

B functions to search one white dot (size:1.5 x1.5mm) within a defined ROI (4.5X4.5MM) in an image captured,  IMAQ Create & IMAQ Count object 2 used in the process.

 

problem found: when above A & B script run concurrently, the result for both A & B wrong intermittently.  err message pop up: the image is not large enough for operation when IMAQ Count object 2 called. this happens either in A or B scripts. the err as attached shows.

 

hardware & software set up: Guppy digital F503B camera & PCIe-8255R used, win7 OS, Labview 8.6, NI Vision 8.6 used.  

 

some evaluation tried:

1. is there any duplicate image memory name allocated in IMAQ Create? No

2. is there any duplicate global variable name occurs in A and B? No 

3. copy B into A, if run both in different loop concurrently, same error happens. if run A & B in sequence (case 1 and case 2). no error occurs.

 

Question:

1. how does memory allocated when two NI scripts run simultaneously to avoid conflict in the system?

2. how to address and fix the issue I encoutered ?

 

I appreciate if anybody can give me some advice on this, it is really headach for me,  two weeks passed already, still no clue to address why the issue happens. Thanks a lot.

 

Joe

0 Kudos
Message 1 of 7
(5,006 Views)

the image is not large enough for operation as attached.image is not large enough for operation.png

 

 

A is to inspect ball damage in a image as  below:

A image.png

 

B is to search a white dot in the image as below shows:

B search for white dot.png

0 Kudos
Message 2 of 7
(5,005 Views)

I guess you are thresholding the image from each roi. Check whether you have created  a unique imaq create and connected to img dst. Check also if the image that you are extracting from the roi is large enough. First check whether your roi is right by storing all the roi images in the harddisk. Check whether you are extracting them right. Then you can go for processing them

0 Kudos
Message 3 of 7
(4,979 Views)

If searching for the white dots is the aim, you can also use circle detection . See the attached vi

0 Kudos
Message 4 of 7
(4,976 Views)

Yes. thresholding set before IMAQ Count object 2.vi called. it is used to find white obj or dark obj.

Unique IMAQ Create used. cheked already. IMAQ Create outside the loop, IMAQ dispose outside the loop as well.

ROI is right since it is fixed and read from txt file which created in set up mode (used for define ROI)

Extracting only happens in IMAQ Count object 2.vi call, in my sourcecode, no other place to extract image.

 

the problem is if run either A or B program only, no issue, if run concurently, the err image is not large enough for operation happens, and the processing result are wrong as well. any others I need to check? Thanks

0 Kudos
Message 5 of 7
(4,968 Views)

did u check the circle detection?

0 Kudos
Message 6 of 7
(4,965 Views)

u might be recursively calling imaq extract and the imaq create is being over written. Can you post a screen shot of ur vi?

0 Kudos
Message 7 of 7
(4,964 Views)