G-CODEEIA/ISO · one-shot
G45

Tool position offset, extension

Machine-specific. This G-code reference is specific to the Mazak INTEGREX e-670H / e-670H-S with the MAZATROL SmoothX control (EIA/ISO programming manual H747PB0030E). G-code availability depends on fitted options, and groups and behaviour differ between Mazak models and control generations — verify against the manual for your own machine before programming with any code.
What it does

Command G45 or G46 allows the axis movement distance set previously in that block to be increased or decreased, respectively, according to the offset data. Likewise, command G47 or G48 extends or contracts the previously set distance by twice the offset stroke, respectively. G45 command G46 command Contracted thru Extended thru offset stroke only offset stroke only Internal Internal calculation calculation Starting Ending Starting Ending point point point point G47 command G48 command Extended thru twice Contracted thru twice the offset stroke the offset stroke Internal Internal calculation calculation Moving Moving stroke stroke Starting Ending Starting Ending point point point point (Program command value) (Offset stroke) (Moving stroke after offset) Offsetting in any vectorial direction can be done according to the tool radius preselected using G-codes (G38 to G42) and D-codes. This function is referred to as tool radius compensation. For turning tools, moreover, nose radius compensation can be performed according to the designated direction.

G45 is one-shot (group 00) — it is valid only in the block where it is entered.

Programming format
Programming format Function
To extend a moving stroke by the offset stroke which has been set in the offset
G45 Xx Dd
memory.
To contract a moving stroke by the offset stroke which has been set in the offset
G46 Xx Dd
memory.
To extend a moving stroke by twice the offset stroke which has been set in the
G47 Xx Dd
offset memory.
To contract a moving stroke by twice the offset stroke which has been set in the
G48 Xx Dd
offset memory.
Programming format Function Remarks
G40X_Y_ To cancal a tool radius compensation
G41X_Y_ To compensate a tool radius (to the left)
G42X_Y_ To compensate a tool radius (to the right)
G38 I_J_ To change and hold an offset vector These commands can be given in the […]
Notes & precautions
  • Use tool radius compensation commands G40, G41, or G42 if simultaneous offsetting
Source

Mazak PROGRAMMING MANUAL for EIA/ISO PROGRAM, manual H747PB0030E, section 12-4 Tool Position Offset: G45 to G48, p. 3-11, 12-24, 12-25, 12-26, 12-27, 12-28, 12-29, 12-30. Reference and explanation only — not a reproduction of the manual.

Not sure how to use it? Ask the Mazatrol assistant →