User`s guide
Defining a Tool Transformation
The following program establishes a reference point from which tool transformations can be
taught.
.PROGRAM def.tool()
; ABSTRACT: Invoke a new tool transformation based on a predefined reference
; location and, optionally, teach the reference location.
AUTO $answer
TYPE /C1, "PROGRAM TO DEFINE TOOL TRANSFORMATION", /C1
ATTACH (1) ;Attach the pendant
PROMPT "Revising a previously defined tool (Y/N)? ", $answer
IF $answer <> "Y" THEN
TYPE /C1, "Move the tool tip to the selected reference ", /S
TYPE "location.", /C1, "Set 'ref.tool' equal to the ", /S
TYPE "transformation for this location.", /C2, "Press ", /S
TYPE "the REC/DONE button on the manual control pendant when ", /S
TYPE "ready to proceed. ", /S
DETACH (0) ;Release the robot to the user
WAIT PENDANT(8) ;Wait for user to press REC/DONE
button
ATTACH (0) ;Regain control of the robot
;(automatically wait for COMP mode)
TOOL ref.tool
HERE ref.loc ;Record the reference location
TYPE
END
TYPE /C1, "Install the new tool. Move its tip to the ", /S
TYPE "reference location.", /C2, "Press the REC/DONE button ", /S
TYPE "on the manual control pendant when ready to proceed. ", /S
DETACH (0) ;Release the robot to the user
WAIT PENDANT(8) ;Wait for user to press REC/DONE
button
ATTACH (0) ;Regain control of the robot
; Compute the new tool transformation, 'new.tool'
TOOL ref.tool
SET new.tool = ref.tool:INVERSE(HERE):ref.loc
TOOL new.tool ;Apply the new tool
transformation
Defining a Tool Transformation
V+Language User's Guide, v17.0
Page 346










