Hi all,
I’m trying to find out how to capture 4 coordinate translation(x,y,z) data, so I can then send it to an external 3rd party Raspberry Pi controller.
So far I have used the CPos instruction to capture 4 separate coordinate translation data into some variables, like below:
VAR pos pos1;
VAR pos pos2;
VAR pos pos3;
VAR pos pos4;
PROC main()
MoveJ [[230.00,0.00,309.61],[0.00592441,-2.20071E-8,0.999982,-1.40272E-7],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]], v1000, fine, tool0;
pos1 := CPos(\Tool:=tool0 \WObj:=wobj0);
MoveL [[400.00,-0.00,309.61],[0.00592472,9.63992E-10,0.999982,-1.36007E-7],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]], v1000, fine, tool0;
pos2 := CPos(\Tool:=tool0 \WObj:=wobj0);
MoveL [[400.00,250.00,309.61],[0.00592313,-1.76557E-7,0.999982,-1.12661E-6],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]], v1000, fine, tool0;
pos3 := CPos(\Tool:=tool0 \WObj:=wobj0);
MoveL [[230.00,250.00,309.61],[0.00592287,-1.26527E-7,0.999982,-1.40362E-6],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]], v1000, fine, tool0;
pos4 := CPos(\Tool:=tool0 \WObj:=wobj0);
MoveL [[230.00,0.00,309.61],[0.00592441,-2.20071E-8,0.999982,-1.40272E-7],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]], v1000, fine, tool0;
ENDPROC
But now I am unsure of how to record or store those pos data, such that I can have them sent to the Raspberry Pi controller. I’ve tried to look in the Technical Reference PDF, but can’t seem to find exactly what I’m looking for. Would greatly appreciate any help on this.
Thank you!