Rockwell Automation 8520-GUM 9/Series CNC Grinder Operation and Programming Manual Documentation Set User Manual

Page 694

Advertising
background image

Paramacros

Chapter 20

20-50

Use this format when calling a paramacro using the G65 command:

G65 P_ L_ A_ B_;

Where:

Determines:

P

the program number of the called macro. P ranges from 1 - 99999.

L

the number of times the macro is executed. L ranges from 1 - 9999, and can be
expressed as any valid parametric expression. If not specified, the control uses a
default value of 1.

A-Z

Optional argument statements. May be programmed using any letter from A to Z
excluding G, L, N, O, or P. Used to assign numeric values to parameters in the
paramacro. Arguments may be specified as any valid parametric expression.

The G65 command is non-modal. The macro is executed only at the time
the control executes the G65 block. The control calls the macro specified
by the G65 block as programmed by the P word.

This macro is executed until the control reaches an M99 macro return
code. The macro then returns to the next unexecuted sequential block in
the calling program unless the macro has not been repeated the number of
times as determined by the L word. If this is the case, the macro
re-executes.

You can define the L word or any optional argument statements in a G65
block using any valid parametric expression. For example:

G65 P1002 L[#1+1] A[12*6] B[SIN[#101]];

Use this format when calling a paramacro using the G66 command:

G66 P_ L_ A_ B_;

Where:

Determines:

P

the program number of the called macro. P ranges from 1 - 99999.

L

the number of times the macro is executed after each motion block that follows the
G66. L ranges from 1 - 9999, and can be expressed as any valid parametric
expression. If not specified, the control uses a default value of 1.

A-Z

Optional argument statements. May be programmed using any letter from A to Z
excluding G, L, N, O, or P. Used to assign numeric values to parameters in the
paramacro. Arguments may be specified as any valid parametric expression.

The G66 command is modal and remains in effect until canceled with a G67
block. The macro programmed by the P word in the G66 block is not
executed when the G66 block is read. The control delays macro execution
to any block following the G66 command that contains a motion command.

When the control encounters a motion block (even if this block is
contained in a different macro) following the G66 block, it executes the

20.6.1
Non-Modal Paramacro Call
(G65)

20.6.2
Modal Paramacro Call (G66)

Advertising