Programming examples
Example 1 - Plane defined by reference points
Programing Example
Plane defined by reference points
The following parameters are used in this example:
- Tool and machining coordinate system are rotated:
@P1=1
- The retraction distance along the Z axis is 50mm:
@P2 = 50
- The new origin is located at (140, 0, 80):
@P3=140 @P4=0 @P5=-80
- The first reference point is located at (100, 30, 25):
@P6=100 @P7=30 @P8=-25
- The second reference point is located at (100, 70, 25):
@P9=100 @P10=70 @P11=-25
- The third reference point is located at (115, 70, 50):
@P12=115 @P13=70 @P14=-50
#TRAFO ON
L CYCLE [NAME=SysPosRotationToPlane.ecy \
@P1 = 1 \
@P2 = 50 \
@P3 = 140 \
@P4 = 0 \
@P5 = -80 \
@P6 = 100 \
@P7 = 30 \
@P8 = -25 \
@P9 = 100 \
@P10 = 70 \
@P11 = -25 \
@P12 = 115 \
@P13 = 70 \
@P14 = -50 \
]
(---------------------------------)
(---- Processing the plane -----)
(---------------------------------)
#CS OFF ; Deactivate the calculated MCS
#TRAFO OFF
Example 2 - Plane defined by rotation angles
Programing Example
Plane defined by rotation angles
The following parameters are used in this example:
- Tool and machining coordinate system are rotated:
@P1=1
- The retraction distance along the Z axis is 50mm:
@P2 = 50
- The new origin is located at (140, 0, 80):
@P3=140 @P4=0 @P5=-80
- The third rotation about the X axis is 60°:
@P15=60
- The first rotation about the Z axis is 90°:
@P17=90
- The second rotation about the Y axis is 0°:
@P16=0
#TRAFO ON
L CYCLE [NAME=SysPosRotationToPlane.ecy \
@P1 = 1 \
@P2 = 50 \
@P3 = 140 \
@P4 = 0 \
@P5 = -80 \
@P15 = 60 \
@P16 = 0 \
@P17 = 90 \
]
(---------------------------------)
(---- Processing the plane -----)
(---------------------------------)
#CS OFF ; Deactivate the calculated MCS
#TRAFO OFF
M30