Fanuc Series 15i/150i-MA (Programming) Operators Manual

B-63324EN/03 PROGRAMMING 17.CUSTOM MACRO
- 673 -
Fig.17.14.2 (c) Custom macro interrupt signal
- Return from a custom macro interrupt
To return control from a custom macro interrupt to the interrupted
program, specify M99. A sequence number in the interrupted program
can also be specified using address Q( or P). If this is specified, the
program is searched from the beginning for the specified sequence
number. Control is returned to the first sequence number found.
When a custom macro interrupt program is being executed, no
interrupts are generated. To enable another interrupt, execute M99.
When M99 is specified alone, it is executed before the preceding
commands terminate. Therefore, a custom macro interrupt is enabled
for the last command of the interrupt program. If this is inconvenient,
custom macro interrupts should be controlled by specifying M96 and
M97 in the program.
When a custom macro interrupt is being executed, no other custom
macro interrupts are generated; when an interrupt is generated,
additional interrupts are inhibited automatically. Executing M99
makes it possible for another custom macro interrupt to occur. M99
specified alone in a block is executed before the previous block
terminates. In the following example, an interrupt is enabled for the
Gxx block of O1234. When the signal is input, O1234 is executed
again. O5678 is controlled by M96 and M97. In this case, an interrupt
is not enabled for O5678 (enabled after control is returned to O1000).
Interrupt signal (UINT)
1
0
Status-triggered
scheme
Edge-triggered
scheme
Interrupt
execution
Interrupt
execution
Interrupt
execution
Interrupt
execution
Interrupt
execution
NOTE
To specify the sequence number to be returned with
M99, Q is used. To maintain compatibility with
existing programs, however, P can be used instead.
In the following explanation, Q is used.

Leave a Reply

Your email address will not be published. Required fields are marked *