4 the interrupt program – Rockwell Automation 8520 9/Series CNC Lathe User Manual

Page 738

Advertising
background image

Program Interrupt

Chapter 29

29-8

You can alter the number of blocks that the control re-executes in reverse

when returning to the start position of the interrupt. The number of return

blocks is normally 4; however, it can be altered by these codes:

M-code:

Number of

Blocks Retraced:

M900

zero

M901

one

M902

two

M903

three

M904

four

These M-codes can be programmed in any block in the main program

before the interrupt program is executed. They can also be programmed

within an interrupt though the M-code will not go into effect until

execution is returned to the main program. If not programmed, the default

is 4 blocks. The default is automatically reset at the end of program

commands (M02 or M30).

The number of retrace blocks set with this M-code is the same for all

active or inactive interrupts. If an interrupt is enabled after this M-code is

programmed, it takes on the number of retrace blocks as programmed with

this M-code.

When the return from interrupt is executed (M99 in the interrupt), the

control generates a linear move to the end point of the last remembered

move for retrace. Then the moves are retraced, returning the tool to the

start point of the interrupt. This may not be the same location in the main

program if a different tool offset has been activated.

When you intend to use a program as an interrupt program, remember:

Any modal data (G-codes, feedrates, spindle speeds, coordinate system
offsets, etc.) contained in the main program are carried into the interrupt

program. Any changes made to this modal data within the interrupt will

be effective only in the interrupt program; changes are not carried back

into the main program when the interrupt is completed. This does not

include tool or tool offset data that is changed in the interrupt. Any tool

or tool offset changes will be carried back into the suspended main part

program.

29.4

The Interrupt Program

Advertising