Chapter 2 G Commands
29
Ⅰ
Programming
Chapter 2 G Codes
2.1 Summary
G code consists of code address G and its following code value, used for defining the motion
mode of tool relative to the workpiece, defining the coordinates and so on. Refer to G codes as Fig.
2-1.
Note 1: The leading zero of the code value can be omitted. Example: G02 is equivalent to G2, G01 to G1.
Note 2: The leading zero following the code value cannot be omitted. Example: G20 and G2 are different G
codes in the different group; G12.1 is legal but G12.10 is illegal.
Note 3: The code value can be up to 8-bit digit. Example: G00000002 is correct and valid, equivalent to G02.
Note 4: Except for G12.1/G13.1/G7.1/G50.2/G51.2/G50.4/G50.5/G50.6/G51.4/G51.5/G51.6/G54.1, other G code
cannot be with the decimal point, otherwise, the alarm occurs. For example: G20.0, G00.0, G18.are
illegal.
2.1.1 G code Classification
G codes are divided into: modal G code and non-modal G code.
After a G code is executed, its defined function or state remains valid till other G code is specified
in the same group, this G code is called the modal. After the modal G code is executed, before its
defined function or state is changed, the G code is not input again when the following block executes
the G word.
After a G code is executed, its defined function or state is valid once, its word must be input again
when it is executed, and so the G code is called the non-modal.
Example 1: G01 and G00 are modal.
G01 X_
;
Z
_
;
G01 is valid in the range
X_
;
G00 Z_;
X_; G00 is valid in the range
G01 X_;
Example 2: G04 is non-modal.
O0002
;
G0 X50 Z5
;
(
Rapid traverse to X50 Z5
)
G04 X4
;
(
Delay 4s
)
G04 X5
;
(
Delay 5s again
,
G04 is non-modal and must be input again
)
M30
;
Table 2-1 G code list
Summary of Contents for GSK988TA
Page 6: ...GSK988TA GSK988TA1 GSK988TB Turning Center CNC System User Manual Programming Operation VI ...
Page 19: ...1 Ⅰ Programming PROGRAMMING ...
Page 227: ...209 Ⅱ Operation OPERATION ...
Page 369: ...Chater 10 Machining Example 351 Ⅱ Operation ...
Page 371: ...353 Appendix ...
Page 465: ...Appendix 1 Parameters 447 Appendix ...
Page 479: ...Appendix 3 Interface Explanation 461 Appendix ...
Page 527: ...Appendix 5 Installation Layout 509 Appendix ...