Hello, I’m trying to use a camera (connected to my robot system by the serial port COM1) to track my path between two points.
I need to go from point A to point B (+Y direction), and I use the camera to find the varations in space refering to my workobject (+/- X direction).
Basically, I start by sending the pattern position that was found by the camera, to the robot system as a STRING.
After that, I use ReadStrBin to read the STRING in my program (I convert the value with StrToNum) and next I save the value as the position of my point B (pointB.trans.x)
I use a loop to execute continously my moveL command :
ReadStrBin… StrToNum… pointB.trans.y :=valueY ; MoveL pointB, v30, fine, Tool\Wobj ; …. pointB.trans.y :=pointB.trans.y+1 ;
Usually, I use a TRAP to stop the loop.
The problem that I have is the stop time between the moment when the program is reading the serial port channel and the moment when the robot is moving on.
So my question is : there’s a way to do that continously ? or somebody knows a better way to do it ?
Thanks !