
Ed. Date Design Description
Date Jan.07.’04 Design. Apprv.
page
-
3/64
FANUC Series 30i-MODEL A
Real time custom macro
A-79350EN
Title
Draw
No.
By using a real time custom macro, control on signals and peripheral axes can be
programmed.
The example below turns on and off a signal and performs operation on a peripheral
axis when machining points are passed.
The operation above is programmed using real time macro commands.
The timing is as follows. (‘**’ represents the satisfaction of the condition.)
X coordinate 30 50 80
Peripheral axis Y operation
G99.5 signal
NC statement (machining)
G90 G01 X200. F150
Real time macro command 1
//1 ZEDGE [#100101 GE 30.]
#IOG[99,5] = 1 ;
**
Real time macro command 2
//2 ZEDGE [#100101 GE 50. ]
ZDO ;
G91 G00 Y100 ;
ZEND ;
**
Real time macro command 3
//3 ZEDGE [#100101 GE 80. ]
#IOG[99,5] = 0 ;
**
Program
O0001 ;
G92 X0 ;
//1 ZEDGE [#100101 GE 30. ] #IOG[99,5] = 1 ;
//2 ZEDGE [#100101 GE 50.] ZDO ;
G91 G00 Y100 ;
ZEND ;
//3 ZEDGE [#100101GE 80. ] #IOG[99,5] = 0 ;
G90 G01 X200. F150 ;
M30 ;
During movement for machining along the X-axis in the figure above:
① When point Xa is passed, the G99.5 signal is set to 1. →Real time macro command 1
②
When point Xb is passed, positioning is started on peripheral axis Y. →Real time macro command 2
③
When point Xc is passed, the G99.5 signal is set to 0. →Real time macro command 3
Signal
ON OFF
Peripheral axis Y
X-axis machining direction
Xa=30 Xb=50 Xc=80