Delta Tau GEO BRICK LV User Manual
Turbo PMAC User Manual
Writing and Executing Motion Programs
331
You may also want to set some variables in these routines to note what plane has been specified if you
want to use this information for other routines (such as G68 rotation). Turbo PMAC’s circular
interpolation and radius compensation routines do not need such a variable.
want to use this information for other routines (such as G68 rotation). Turbo PMAC’s circular
interpolation and radius compensation routines do not need such a variable.
G40, G41, G42 – Cutter Radius Compensation
Cutter radius compensation can be turned on and off easily with the CC0, CC1, and CC2 PMAC commands,
corresponding to G40, G41, and G42, respectively. The subroutines to implement this would be:
corresponding to G40, G41, and G42, respectively. The subroutines to implement this would be:
N40000 CC0 RETURN
; Turn off cutter compensation
N41000 CC1 RETURN
; Turn on cutter compensation left
N42000 CC2 RETURN
; Turn on cutter compensation right
G90 – Absolute Move Mode
Typically, this code is implemented in PMAC through use of the ABS command. The ABS command
without a list of axes puts all axes in the coordinate system in absolute move mode. The typical
implementation would be G90000 ABS RETURN. If the G-Code dialect has G90 making the circle-
move center vectors absolute also (this is non-standard), an ABS(R) command should be added to this
routine.
without a list of axes puts all axes in the coordinate system in absolute move mode. The typical
implementation would be G90000 ABS RETURN. If the G-Code dialect has G90 making the circle-
move center vectors absolute also (this is non-standard), an ABS(R) command should be added to this
routine.
G91 – Incremental Move Mode
Typically, this code is implemented in PMAC through use of the INC command. The INC command
without a list of axes puts all axes in the coordinate system in incremental move mode. The typical
implementation would be G91000 INC RETURN. If the G-Code dialect has G90 and G91 also
affecting the mode of circle-move center vectors (non-standard), an INC(R) command should be added
to this routine.
without a list of axes puts all axes in the coordinate system in incremental move mode. The typical
implementation would be G91000 INC RETURN. If the G-Code dialect has G90 and G91 also
affecting the mode of circle-move center vectors (non-standard), an INC(R) command should be added
to this routine.
G92 – Position Set (Preload) Command
If this code is used just to set axis positions, the implementation is very simple: N92000 PSET
RETURN. With the return statement on the same line, the program would jump back to the calling line
and use the values there (e.g. X10 Y20) as arguments for the PSET command. However, if the code is
used for other things as well, such as setting maximum spindle speed, the subroutine will need to be
longer and do the setting inside the routine.
For example, if G92 is used to preload positions on the X, Y, and Z-axes, set the maximum spindle speed
(S argument), and define the distance from tool tip to spindle center (R argument), the subroutine could be:
RETURN. With the return statement on the same line, the program would jump back to the calling line
and use the values there (e.g. X10 Y20) as arguments for the PSET command. However, if the code is
used for other things as well, such as setting maximum spindle speed, the subroutine will need to be
longer and do the setting inside the routine.
For example, if G92 is used to preload positions on the X, Y, and Z-axes, set the maximum spindle speed
(S argument), and define the distance from tool tip to spindle center (R argument), the subroutine could be:
N92000 READ(X,Y,Z,S,R)
IF (Q100 & 8388608 > 0) PSET X(Q124) ; X axis preload
IF (Q100 & 16777216 > 0) PSET Y(Q125) ; Y axis preload
IF (Q100 & 33554432 > 0) PSET Z(Q126) ; Z axis preload
IF (Q100 & 262144 > 0) P92=Q119 ; Store S value
IF (Q100 & 131072 > 0) P98=M165-Q118 ; Store R value
IF (Q100 & 8388608 > 0) PSET X(Q124) ; X axis preload
IF (Q100 & 16777216 > 0) PSET Y(Q125) ; Y axis preload
IF (Q100 & 33554432 > 0) PSET Z(Q126) ; Z axis preload
IF (Q100 & 262144 > 0) P92=Q119 ; Store S value
IF (Q100 & 131072 > 0) P98=M165-Q118 ; Store R value
RETURN
The purpose of the condition in each line is to see if that argument has actually been sent to the subroutine
in the subroutine call – if it has not, nothing will be done with that parameter (see Passing Arguments
section, above). In the case of the S argument, the value is simply stored for later use by other routines,
so that a commanded spindle speed will not exceed the limit specified here. In the case of the R
argument, the routine calculates the difference between the current commanded X-axis position (M165)
and the declared radial position (R argument: Q118) to get an offset value (P98). This offset value can be
used by the spindle program to calculate a real-time radial position.
in the subroutine call – if it has not, nothing will be done with that parameter (see Passing Arguments
section, above). In the case of the S argument, the value is simply stored for later use by other routines,
so that a commanded spindle speed will not exceed the limit specified here. In the case of the R
argument, the routine calculates the difference between the current commanded X-axis position (M165)
and the declared radial position (R argument: Q118) to get an offset value (P98). This offset value can be
used by the spindle program to calculate a real-time radial position.