6 Programming
6.6.3. Example "SyncSpot" with coordinated synchronized movement
3HAC021272-001 Revision: H
76
© Copyri
ght
200
4-2008 ABB.
All rights reserved.
ENDPROC
PROC SyncMove()
MoveJ p21, v1000, fine, grip1;
SyncMoveOn sync1, motion_tasks;
MoveL p22\ID:=10, v300, fine, grip1;
MoveL p23\ID:=20, v300, fine, grip1;
SyncMoveOff sync2;
UNDO
SyncMoveUndo;
ENDPROC
ENDMODULE
T_READHANDLE task program
MODULE module3
PERS tooldata grip1 := ...
PROC main()
...
ReadHandleRobPos;
...
ENDPROC
PROC ReadHandleRobPos()
VAR robtarget phandle;
WHILE TRUE DO
WaitTime 0.5;
phandle := CRobT(\Tool:=grip1 \WObj:=wobj0);
TPWrite "Handle robot position: "\Pos:=phandle.trans;
ENDWHILE
ENDPROC
ENDMODULE
T_READPROC task program
MODULE module4
PERS wobjdata wobj_handlerob :=
[ FALSE, FALSE, "ROB_2",
[ [0, 0, 0], [1, 0, 0 ,0] ],
[ [-10, 0.5, 7], [1, 0, 0, 0] ] ];
PERS tooldata gun1 := ...
PROC main()
...
ReadProcRobPos;
...
ENDPROC
Continued
Continues on next page