
3.EXECUTION MACRO FUNCTION B-63943EN-2/01
- 60 -
User program
Compile parameter (No.9013)=81
O9010 ;
:
M300 P100 L2 ;
:
M99 ;
Compile parameter
(No.9033)=300
O0001 ;
:
G81 X10.0 Z-10.0 ;
:
M30
Mm P p L l ;
m : Call M code
P : Program number of a execution program to be called
l : Repetition count (1 by default)
1 to 999999999
Execution macro
O0100 ;
:
:
M99 ;
3.2.18 Subprogram Call for User Program
A user program is called as a subprogram using the M code specified
for compile parameter (No. 9033).
Format
Nesting and local variables
Each subprogram call for a user program is assumed to call a custom
macro as a subprogram using M98 and is counted among custom
macro nesting levels.
The local variables at the calling execution macro are passed,
regardless of the state of bit 3 (LCLLV) of compile parameter (No.
9163).
Limitation
1 If an M code exceeding 99999999 is set, the call is invalidated.
(The M code is output as an ordinary M code.)
2 Usually, when a called user program calls another program, the
G65/G66/G66.1/M98 command only can be specified. The
restriction to be applied to bit 6 (GMP) of parameter (No. 6008)
differs from the restriction to be applied to bit 2 (PCDC) of
compile parameter (No. 9163).