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

Page 290

Advertising
background image

Introduction to Programming

Chapter 10

10-12

All program blocks must have an end of block statement as the last
character in the block. This character tells the control how to separate data
into blocks. The control uses the “;” to mark the end of a block.

To specify an end of block character “;” at the keyboard, use the [EOB]
key on the operator panel. If editing part programs off line (see chapter 6),
the end of block character should not be entered when blocks are keyed in.
The control automatically inserts end of block ; when you download the
program.

When the same series of blocks are repeated more than once, we
recommend that you program them using a subprogram.

The key difference between a subprogram and a G65 paramacro is that a
paramacro always gets a new set of local parameters; a subprogram uses
the same set of local parameters that the main program used. See chapter
20 for details on paramacros and local parameters.

This section explains the following:

main and subprograms

subprogram calls

To make jumps, loops, or calculations within an executing program or
subprogram, use any of the paramacro features as described in chapter 20.

You can call a subprogram in an MDI command, however, an MDI
command cannot contain an M99 code.

ATTENTION: Any edits that you made to a subprogram or
paramacro program (as described on page 7-6) that has already
been called for automatic execution are ignored until the calling
program is disabled and reactivated. Subprograms and
paramacros are called for automatic execution the instant that
the calling program is selected as active (as described on page
7-6).

10.2.5
End of Block Statement

10.3
Using Subprograms

Advertising