3 miscellaneous function (m function) – Yaskawa YASNAC PC NC Programming Manual User Manual

Page 135

Advertising
background image

3 - 85

YASNAC PCNC Programming Manual

Chapter 3: Movement Control Commands

3.5.3

Miscellaneous Function (M Function)

The miscellaneous function is specified by a maximum of a three-digit number (Mooo) following
address M. With the exception of specific M codes, the functions of M00 to M89 codes are
defined by the machine tool builder. Therefore, for details of the M code functions, refer to the
instruction manuals published by the machine tool builder.

The M codes specific to the NC are described below.

(1) M codes Relating to Stop Operation (M00, M01, M02, M30)

When an M code relating to stop is executed, the NC stops buffering. Whether spindle rota-
tion, coolant discharge or another operation stops in response to the execution of such as M
code is determined by the machine tool builder. For details refer to the instruction manuals
published by the machine tool builder. For these M codes, a code signal is output indepen-
dently in addition to M2-digit BIN code.

M00 (Program Stop)

If M00 is specified during automatic operation is interrupted after the completion of
the commands specified with M00 in the same block the M00R signal is output. The
interrupted automatic operation can be restarted by pressing the cycle start switch.

M01 (Optional Stop)

If M01 is executed with the optional stop switch ON, the same operation as with M00
is executed. If the optional stop switch is OFF, M01 is disregarded.

M02 (End of Program)

M02 should be specified at the end of a program. When M02 is executed during auto-
matic operation, automatic operation ends after the commands specified with M02 in
the same block have been completed. The NC is reset. The state after the end of a
program varies with each machine. For details, refer to the instruction manuals pub-
lished by the machine tool builder.

M30 (End of Tape)

Normally, M30 is specified at the end of tape. When M30 is executed during auto-
matic operation, automatic operation ends after the commands specified with M30 in
the same block have been completed. The NC is reset and the tape is rewound. The
sate after the execution of M30 varies with each machine. For details, refer to the
instruction manuals published by the machine tool builder.

Advertising