Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Limit Inspection Time in VBAI V2.61

Is anyone aware of a way to set a fail output on a CVS with VBAI V2.61 if the inspection is taking too long?  As an example if I am using an OCR tool and it takes longer than 100ms to interpret the text I would like to set a fail output.

Thanks,
Steve Mleczewski
Industrial Logic
0 Kudos
Message 1 of 6
(4,171 Views)
Hello Steve,

Thank you for contacting National Instruments.  Based on what you have described, it sounds like you want to toggle a failed inspection after a certain amount of time has elapsed while the step is running.  Unfortunately, a step status cannot be changed while the step is executing.  This is a limitation of VBAI, and I apologize for this inconvenience.

One possible workaround is to create two LabVIEW vis that take timestamps before and after the OCR step.  Place the first LabVIEW step in front of the OCR step and have it take a timestamp and pass the value out as an indicator for later use.  After the OCR step, create a second LabVIEW step that receives the timestamp from the previous LabVIEW step, and also take a new timestamp.  The VI would then take the difference between the current time, and the previous timestamp, and pass out a true or false if that elapsed time is too long.  You can then configure this LabVIEW step to pass or fail based on the result of the comparison in the VI.

Regards,

Mike T
National Instruments
0 Kudos
Message 2 of 6
(4,140 Views)

Hi Mike-

Thanks for the reply.  This is a common question in mail sorting/verification applications.  If it is taking too long (sometimes they set it to 50ms) then they want to kick it offline as a fail.  What do you think about the idea of using the pulsed timed outputs.  I could set a pulse output to go high after a set time like 50ms which could override the pass/fail outputs.  Let meknow what you think.

Thanks,

Steve Mleczewski

Industrial Logic

0 Kudos
Message 3 of 6
(4,127 Views)
Hi Steve,

That is a good idea on how to get around this.  I am assuming that you are looking for a means to actually intercept the pass/fail outputs that leave the digital I/O port on the CVS within a certain time interval.  Doing so would require programming with IMAQ I/O.  Am I correct on this?  If so, then I will check if this can be accomplished.

Regards,

Mike T
National Instruments
0 Kudos
Message 4 of 6
(4,108 Views)

Yes, in a way I'm trying to intercept the pass/fail signal if the inspection is taking too long.  If it is taking too long to figure out what the OCR characaters are it is probably bad print anyway. 

Thanks,

Steve Mleczewski

Industrial Logic

0 Kudos
Message 5 of 6
(4,007 Views)
Hey Steve,
 
This might be possible using IMAQ I/O to toggle a digital output high after a certain amount of time has elapsed after the time that the LabVIEW VI is called in VBAI.  This output should go high even while the inspection is still running.  You can use this digital output as an alternate Pass/Fail condition.
 
Regards,
 
Mike T
National Instruments
0 Kudos
Message 6 of 6
(3,990 Views)