02-25-2009 05:42 PM - edited 02-25-2009 05:43 PM
Hi..
My program is to detect movement of an object using a webcam and Labview 8.5.1.
I used an IMAQ RAKE with 'top to bottom' scan direction to find the first edge of my object and I want to keep the coordinate of this first edge (X1,Y1). Then when the object moves, the IMAQ RAKE will find the first edge with same scan direction and the coordinates (Xi,Yi) are needed to calculate the distance of the movement (X1-Xi,Y1-Yi). And this calculation is running in real-time.
My problem is, when the IMAQ RAKE detect the very first edge (X1,Y1), how can I store this as a reference coordinate that I'm going to use in the calculation? Because in my current program, the coordinate will follow the current first edge detection, thus the distance will always be 0.
Many thanks.
02-27-2009 12:52 AM
Hi,
Is this a TestStand related question or would it be best to re-post to one of the other forums such as Machine Vision
http://forums.ni.com/ni/board?board.id=200
Regards
Ray Farmer
03-03-2009 02:58 AM
Hi Amila,
I assume that you are using the output of the function 'first edges'. Depending on your architecture there are different ways to go about doing this. From your problem I assume that you are usign a loop with the function on the inside meaning that on the second itteration the result of the first is being overwritten. My suggestion would be to use a shift register so that the result from the first itteration can be fed back around into the second.
If you need any help in implementing this please don't hesitate to ask.
Regards,
Thomas Clark