ADTECH9 Series CNC Programming Manual
Between G661 and G67, every instruction segment will call the specified macro subroutine
unconditionally.
Format:
G661 P_ L_ <argument>;
P_
:subroutine
L_
: repeat times
Details:
In G661 mode, all the read codes except O, N and G codes of every segment will be used as arguments.
In G661 instruction segment, all the bit addresses are considered as the arguments of G661.
For example
G661P0002N100G01G90X100.Y200.F400R1000,
G01 instruction isn’t executed, and all bit addresses are considered as the arguments of G661.
4.4
Variable
Function and purpose:
Variable is a useful function of macro. Four types of variables are available, which are local variable, global
non-retentive variable, global retentive variable and system variable. These variables make the writing of
macro very convenient and universal.
Using multiple variables:
➢
Macro calls variable, and the variable can be specified by multiple or expression. As below:
#1
=
10
#10
=
20
#20
=
30
#5
=
#[#[#1]];
According to #1=10,#[#[#1]]=#[#10]
According to #10=20,#[#10]=#20
Therefore, #5=#20 or #5=30
#10=5
#10=20
#20=30
#5=1000
#[#[#1]]=#5
According to #1=10,#[#[#1]]=#[#10]
According to #10=20,#[#10]=#20
Therefore, #20=#5 or #20=1000
➢
Example of specifying multiple variables:
Summary of Contents for CNC9640
Page 1: ...ADTECH9 Series CNC Programming Manual ...
Page 21: ...ADTECH9 Series CNC Programming Manual Workpiece Coordinate System Diagram ...
Page 44: ...ADTECH9 Series CNC Programming Manual 2 Occasions that inner corner rotates ...
Page 45: ...ADTECH9 Series CNC Programming Manual ...
Page 62: ...ADTECH9 Series CNC Programming Manual Manual insertion ...
Page 65: ...ADTECH9 Series CNC Programming Manual Tool radius compensation start and axis Z cut in action ...
Page 117: ...ADTECH9 Series CNC Programming Manual ...
Page 118: ...ADTECH9 Series CNC Programming Manual ...
Page 142: ...ADTECH9 Series CNC Programming Manual ...
Page 143: ...ADTECH9 Series CNC Programming Manual ...