
Ed. Date Design Description
Date Jan.07.’04 Design. Apprv.
page
-
26/64
FANUC Series 30i-MODEL A
Real time custom macro
A-79350EN
Title
Draw
No.
Control on real time macro commands
By using a reserved word for controlling statements in an RTM command, the flow of
the RTM command can be changed or multiple statements can be controlled as a set
of statements. Four reserved words are used to control an RTM command as
indicated below.
Reserved word
name
Syntax Meaning
ZONCE // ZONCE A B If A is true, B is executed.
ZEDGE // ZEDGE A B If A becomes true, B is executed.
ZWHILE // ZWHILE A B While A is true, B is executed
repeatedly.
ZDO...ZEND // ZDO B1 B2 B3 ZEND (Multiple statements) B1, B2, and
B3 are sequentially executed.
The timing chart of an RTM command using these reserved words is indicated below.
(Multi-statement control ZDO...ZEND is excluded.)
When the condition of a each reserved word is True, it shows ‘*’.
When condition A makes transitions from True to False to True
True
False
ZONCE
*
ZEDGE
*
ZWHILE
* * *
When condition A makes transitions from False to True to False
True
False
ZONCE
*
ZEDGE
*
ZWHILE
* * * * * * *
Time
Time