Chapter 1 Program Composition TC-32B
2004/01/22 1 - 2 eTCOMNCPR1-1.doc
1
1.1 Types and Composition of Program
The program is divided into the main program and the subprogram.
(1) Main program
The main program is for machining one workpiece. While the main program is in use, a
subprogram can be called to use the program more efficiently.
Command M02 (or M30) to finish the main program.
Main program
N0001 G92X100;
N0002 G00Z30
:
:
:
M02;
(2) Subprogram
A subprogram is used by calling it from the main program or other subprograms.
Command M99 to finish the subprogram.
Subprogram
N0100 G91X10;
:
:
:
M99;
1.2 Composition of Block
The program is composed of several commands. One command is called a block. A block is
composed of one or more words. One block is discriminated from another block by an end of
block code (EOB).
This manual expresses the end of block code by the symbol ";".
⋅⋅⋅
;
N0001 G92X100
;
⋅⋅⋅
;
M02
;
(Note 1) The end of block code
ISO code : [LF] 0A(hexadecimal)
EIA code : [CR] 80(hexadecimal)
(Note 2) One block has maximum 128 characters.
Block
Block