Skip to main content
CNC.wiki

G01 Linear Interpolation G-Code: Programming & Brand Differences

Master G01 linear interpolation on Fanuc, Siemens, and Mitsubishi CNC controls. Prevent modal G-code traps, tool collisions, and spindle crashes during setups.

Hakan Gündoğdu
Hakan Gündoğdu

CNC CARE Co-founder

Introduction

Plunging a cutting tool directly into raw stock at rapid speed occurs when a programmer fails to command G01 after a rapid positioning block, leading to a catastrophic hard collision. This failure typically shatters the machine spindle, ruins the vise jaw, and turns a costly workpiece into immediate scrap. Because linear interpolation commands are modal, omitting them during critical path transitions represents one of the most common and destructive modal G-code traps on the production floor. Operators also face severe risks when returning the tool turret to reference home using absolute coordinates; commanding a rapid movement without incremental clearance can force the tool to crash directly through the absolute workpiece face.

Technical Summary

Technical SpecificationDetails
Command CodeG01 (or G1)
Modal GroupGroup 01 (Modal motion command)
Supported BrandsFanuc, Siemens, Mitsubishi
Critical ParametersParameter 3402 (Fanuc default state), MD10704 (Siemens dry run mask), Parameter #1193 (Mitsubishi in-position check)
Main ConstraintA valid non-zero feedrate (F-address) must be defined prior to or within the first G01 motion block.

Quick Read

  • Feedrate Requirement: Program a non-zero feedrate (F-address) prior to or within the first G01 motion block to avoid immediate system alarms like Fanuc PS0011, Siemens 14800, or Mitsubishi P62.
  • Modal G-Code Awareness: Remember that G01 remains active until canceled by another Group 01 code (like G00), meaning omitted motion codes can cause slow crawl retractions or rapid plunge crashes.
  • Safe Retraction Practices: Use incremental coordinates (such as G91 G28 Z0 or G28 U0 W0) rather than absolute coordinates to prevent the tool from traveling directly through the workpiece face.
  • Dry Run Verification: Never machine material with the Dry Run (DRY) switch active, as it overrides cutting feedrates with fast manual rates, leading to broken cutters and scrap parts.
  • Lathe Dimensioning Selection: Program Fanuc lathes with absolute addresses (X/Z) or incremental addresses (U/W) directly, as utilizing G90 will trigger a canned turning cycle rather than setting absolute dimensioning.
  • Profile Cycle Constraints: Ensure that the first profile block (sequence number P) in canned turning cycles (like G71 or G72) starts with G00 or G01 to prevent system execution halts.

Basic Concepts

Linear interpolation is the primary preparatory command used to machine straight lines, contours, and 3D surfaces. When a G01 command is executed, the control system calculates the shortest path between the starting point and the target coordinates. It then coordinates the motion of multiple axes simultaneously, adjusting their individual travel speeds dynamically to ensure that the tool nose center advances at the exact cutting feedrate specified by the F-address.

This cutting motion is modally active, meaning once G01 is commanded, the control continues to execute all subsequent coordinate coordinates as linear cutting movements. This modal state remains in effect until a different Group 01 motion command—such as G00 for rapid traverse, or G02 and G03 for circular interpolation—is declared in the program. Proper management of these modal states is essential to prevent unintended tool motions.

Command Structure

To execute linear interpolation, the program block must contain the G01 command, the target coordinates for the axes, and a feedrate. The feedrate value determines how fast the tool moves along the linear path. Depending on the active feed mode, the feedrate is programmed in millimeters per minute (mm/min) or inches per minute (inch/min) under G94, or millimeters per revolution (mm/rev) or inches per revolution (inch/rev) under G95.

In addition to standard Cartesian coordinate inputs, some control systems permit polar coordinate programming. This method defines the target position using a polar angle and polar radius relative to a predetermined pole. Special block-specific options can also be appended, such as specifying custom in-position width values to verify that the axis has settled before moving to the next block.

; Milling Syntax (Standard Cartesian)
G01 X_ Y_ Z_ F_

; Lathe Syntax (Fanuc G-code System A Absolute) G01 X_ Z_ F_

; Lathe Syntax (Fanuc G-code System A Incremental) G01 U_ W_ F_

; Polar Programming Syntax (Siemens Native) G1 AP=... RP=... F_

Address / ParameterDescriptionSystem Context
X, Y, ZTarget coordinates for Cartesian motion axes.Universal
U, WIncremental coordinates for X and Z axes on lathe systems.Fanuc / ISO System A
FProgrammed feedrate value for the tool advance path.Universal
APPolar angle programmed in degrees for polar interpolation.Siemens Native
RPPolar radius programmed in millimeters or inches.Siemens Native
,IBlock-specific in-position width check value.Mitsubishi

Brand Applications

Fanuc

On Fanuc systems, configuring the startup state of the machine is managed by Parameter No. 3402 Bit 0, which toggles the reset default to G00 or G01. Decimals are controlled by Parameter No. 3401 Bit 0 to set calculator-type point programming.

G01 travel is executed using G01 X_ Y_ Z_ F_ for milling or absolute turning. Incremental lathe moves are programmed directly using G01 U_ W_ F_.

CategoryCode / ParameterDescription / Condition
ParameterParameter No. 3402 Bit 0Power-on default state G00 (0) or G01 (1)
ParameterParameter No. 3401 Bit 0Standard integer (0) or calculator-type decimal programming (1)
ParameterParameter No. 5145Allowable tolerance limit for non-monotonous contour paths in turning cycles
ParameterParameter No. 5000 Bit 3Restores legacy Series 16i/18i/21i path calculation on Series 30i controls (GNI)
AlarmAlarm PS0011FEED ZERO (COMMAND) - Missing or zero feedrate during G01 motion
AlarmAlarm PS0065G00/G01 IS NOT IN THE FIRST BLOCK OF SHAPE PROGRAM - Roughing cycle block P lacks G00/G01
AlarmAlarm PS0034ONLY G00/G01 ALLOWED IN STUP/EXT BLK - Non-linear motion programmed in compensation startup block
VersionSeries 16i/18i/21i vs. 30i/31i/32i-B PlusTool nose radius compensation path differences during cycle startup or cancel

Warning: Omitting G00 or G01 in the first block (P) of Fanuc canned turning cycles (such as G71/G72) will immediately trigger Alarm PS0065, halting program compilation.

Siemens

Siemens controls manage dry run velocities using MD10704, which determines the mask behavior. The zero offset suppression behaves according to the MD10760 parameter configuration.

Siemens programs linear motion using G1 X_ Y_ Z_ F_ or polar coordinates using G1 AP=... RP=... F_ relative to a pole defined by G110-G112.

CategoryCode / ParameterDescription / Condition
ParameterMD10704 (DRYRUN_MASK)Activation of dry run feedrate behavior (Values 0 to 2)
ParameterMD10760 (G53_TOOLCORR)Suppresses tool length and radius compensation for G53/G153/SUPA (Values 2 to 4)
ParameterMD22920 ($MC_EXTERN_FIXED_FEEDRATE_F1_ON)Activates fixed feedrate F1-F9 key interpretation
ParameterSD42160 ($SC_EXTERN_FIXED_FEEDRATE_F1_F9[])Stores feedrate values for F1-F9 keys (e.g. 5000 mm/min)
AlarmAlarm 14800Programmed path velocity is less than or equal to zero (missing or zero feedrate)
AlarmAlarm 61003No feed programmed in the cycle (missing feedrate in calling block)
AlarmAlarm 61805Value programmed absolute and incremental (dual coordinate system conflict)
VersionSINUMERIK 802D vs. 840D / 840D slG93 inverse-time feedrate (1/min) is not supported on SINUMERIK 802D controls
VersionSINUMERIK 802D sl vs. 840D slMulti-edge turning G50.2/G51.2 is supported only on 840D sl
VersionSINUMERIK 840DE / 840DiE vs. 810DE / 840DE slSynchronized Actions Stage 2 and Electronic Gear require advanced options licensing

Warning: Switching dimensioning systems using G70 or G71 recalculates only coordinate geometries; the active feedrate scales remain unchanged, which may result in extremely high feeds and tool breakage if a new F-address is not programmed.

Mitsubishi

Mitsubishi controls evaluate deceleration behaviors using parameter #1193, while parameter #1076 toggles absolute/incremental selection.

Mitsubishi linear interpolation uses G01 X_ Y_ Z_ a_ F_ ,I_ where an additional axis can be driven alongside a block-specific in-position check.

CategoryCode / ParameterDescription / Condition
ParameterParameter #1193 (inpos)Deceleration check selector (0: Commanded Deceleration, 1: In-position check)
ParameterParameter #1076 (AbsInc)Absolute/Incremental selection method (0: G90/G91-based, 1: Address-based)
ParameterParameter #2002 (clamp)Maximum cutting feedrate clamp for any axis
ParameterParameter #2007 (G1tL)Acceleration/deceleration time constant for G1 linear cutting feed
AlarmProgram Error P62FEEDRATE ZERO / MISSING F COMMAND - Executed G01 without an active feedrate
AlarmProgram Error P153INTERFERENCE CHECK VECTOR DELETED - Slots or profiles are narrower than the tool radius during G41/G42
VersionM80 Series vs. Main Part SystemsSub-part system activation via G122 is restricted to systems reserved under parameter #1483
VersionM80V TypeB controlsAdvanced commands like G61.4 (Spline Interpolation) or G122 (Sub Part system) trigger errors (P39, P34) in restricted modes

Warning: Attempting coordinate system preset commands like G92.1 without first canceling active offsets will result in unexpected coordinate offsets, risking travel limit overrun collisions.

Brand Comparison

Feature / AspectFanucSiemensMitsubishi
Lathe Coordinate ProgrammingUses direct absolute (X/Z) and incremental (U/W) addresses in G-code System A; G90 initiates a turning cycle.Uses G90/G91 modal G-codes for dimensioning.Parameter #1076 AbsInc toggles between address-based (1) and G-code-based (0) selection.
In-Position / Deceleration CheckControlled via global system parameters (e.g., No. 19625 look-ahead) or one-shot G-codes.Uses G60 (Exact Stop check mode) or continuous-path modes G64/G641.Supports local block-specific ,I address to set width on-the-fly, overriding parameter #1193.
Multi-Language / Mode SwitchingUses standard G-code System A, B, or C via parameter No. 3401.Dual-compiler architecture with bilingual transition codes G290 (Siemens) and G291 (ISO Dialect).Runs standard ISO code or advanced features (G122) depending on model/parameters.
Overlapping / Block BlendingRelies on system-wide look-ahead and acceleration controls.Uses continuous-path modes G64/G641 to blend blocks without deceleration.Supports Rapid Traverse Block Overlap (G0.5 P1) to smoothly transition rapid travel into cutting feed.
Roughing Cycle constraintsStrictly requires G00 or G01 in the first profile block (P), otherwise triggers Alarm PS0065.Utilizes Siemens cycles (like CYCLE95) with separate parameter specifications.Processes cycles according to model configuration.
Zero Offset / Frame SuppressionRelies on standard coordinate offset retraction controls (G53/G28).Hierarchical suppression commands: G53 (settable), G153 (basic+settable), SUPA (all offsets and frames).Uses G53 and standard retraction offsets.

Technical Analysis

Analyses of these controls show distinct functional characteristics. Fanuc lathe programming relies on a direct coordinate address layout where X/Z define absolute locations and U/W designate incremental movements. Writing G90 on a Fanuc lathe will call a rough turning cycle rather than setting an absolute dimension system. Siemens and Mitsubishi handle coordinates differently, relying on G90/G91 modes to define absolute or incremental values, with Mitsubishi providing parameter #1076 to select between the two behaviors.

Siemens features a unique dynamic axis routing capability through the FGROUP command. Unlike Fanuc and Mitsubishi, which apply cutting feedrates strictly along standard linear geometries, Siemens allows up to eight axes, including rotary axes, to be grouped so that the programmed F-value governs their composite tangential travel. Siemens also implements a hierarchical frame suppression system (G53, G153, and SUPA) that allows selective bypass of coordinate systems and active tool compensations. The dual-compiler structure selected via G290 and G291 also enables Siemens controls to interpret standard ISO programs while executing native Sinumerik subroutines.

Program Examples

Fanuc Example

; Fanuc Milling Absolute
G90 G01 X150.0 Y100.0 Z-5.0 F300.0;
; Fanuc Lathe Absolute
G01 X40.0 Z-25.0 F0.2;
; Fanuc Lathe Incremental
G01 U-10.0 W-15.0 F0.15;

dry run: Verification on Fanuc controls shows absolute milling travel to X150.0, Y100.0, and Z-5.0 at a cutting feed of 300.0 mm/min. Lathe System A blocks move to absolute diameter X40.0 and length Z-25.0 at a feed of 0.2 mm/rev, followed by an incremental move of -10.0 in diameter and -15.0 in length at 0.15 mm/rev.

Siemens Example

; Siemens Native Cartesian Milling
G17 G94 G1 X150.0 Y100.0 Z-5.0 F500.0 M3 S1000;
; Siemens Native Polar Milling
G111 X50.0 Y50.0 G17 G1 AP=45.0 RP=100.0 F150.0;
; Siemens ISO Dialect Mode Switch and Move
G291;
G90 G01 X80.0 W-42.0 F0.3;

dry run: Verification on Siemens controls shows native Cartesian travel in the XY plane (G17) to absolute coordinates X150.0, Y100.0, and Z-5.0 at 500.0 mm/min with the spindle turning clockwise at 1000 RPM. The polar block defines a pole at X50.0, Y50.0, executing linear interpolation at 150.0 mm/min to an angle of 45 degrees (AP) and radius of 100.0 mm (RP). The final blocks switch compiler mode to ISO Dialect (G291) to perform absolute X80.0 and incremental W-42.0 positioning at 0.3 mm/rev.

Mitsubishi Example

; Mitsubishi Absolute Linear Move
G90 G01 X50.0 Z20.0 F300.0;
; Mitsubishi Incremental Move with In-Position Check
G91 G01 X-10.0 Z-5.0 F150.0 ,I1000;
; Mitsubishi Milling Plane Selection
G17 G01 X100.0 Y100.0 F500.0;

dry run: Verification on Mitsubishi controls shows absolute linear motion to X50.0 and Z20.0 at 300.0 mm/min. The incremental block commands a relative move of -10.0 in X and -5.0 in Z at 150.0 mm/min with a custom block-specific in-position width check parameter of 1000 (,I1000). The final milling block drives axes in the XY plane (G17) to absolute X100.0 and Y100.0 at 500.0 mm/min.

Error Analysis

BrandAlarm CodeTrigger ConditionOperator SymptomRoot Cause / Fix
FanucAlarm PS0011Programmed feedrate is missing or set to zero.Execution stops immediately upon G01 block activation with a "FEED ZERO" message.Define a non-zero feedrate using the F-address prior to or inside the active G01 block.
FanucAlarm PS0065Roughing profile sequence block lacks G00/G01.The machine halts compile state at the canned cycle call block.Insert G00 or G01 as the modal motion code in the start block (P) of the roughing profile contour.
FanucAlarm PS0034Circular interpolation called during compensation startup/cancel.Program execution halts with "ONLY G00/G01 ALLOWED IN STUP/EXT BLK".Change circular motion commands to G00 rapid or G01 linear motion in the compensation start (G41/G42) and cancel (G40) blocks.
SiemensAlarm 14800F0 is programmed or no active feedrate is set modally in the channel.The channel stops execution with a path velocity error.Set a positive, non-zero feedrate in the active block or enable the fixed feedrates option.
SiemensAlarm 61003Missing feedrate in calling block before a standard cycle.Standard cycle execution halts immediately before machining begins.Program a modal feedrate F-address prior to executing standard drilling, milling, or turning cycles.
SiemensAlarm 61805Dual absolute and incremental coordinates specified in the same block.Cycle verification halts execution with coordinate mismatches.Verify intermediate coordinates and program them using only one dimension system in the block.
MitsubishiProgram Error P62G01/G02/G03/G33/G34 executed for the first time without an active feedrate.Machine halts with "FEEDRATE ZERO / MISSING F COMMAND" message.Ensure a valid F-address feedrate value is specified in the current or preceding motion block.
MitsubishiProgram Error P153Slots or profiles are narrower than the tool radius during tool compensation.Tool path processing halts with "INTERFERENCE CHECK VECTOR DELETED" warning.Increase profile widths or adjust the tool radius offset value in the offset table.

Application Note

Plunging the tool directly through the absolute Z0 face of a workpiece occurs when returning the turret to reference home using absolute coordinate commands (such as G90 G28 Z0). This motion results in a hard collision that shatters the machine spindle, damages the clamping chuck or fixture clamp, and ruins the vise jaw. Safe tool retraction requires incremental coordinates (G91 G28 Z0 for milling or G28 U0 W0 for lathe systems). To avoid collision errors during setups, operators must carefully verify physical tool offsets and work coordinate presets. Presetting coordinate systems (such as G92.1 on Mitsubishi systems) without first canceling active tool radius compensation (G40) and tool length compensation (G49) creates incorrect reference shifts, pushing the turret beyond travel limits and causing tools to crash directly into workpiece chucks.

Related Command Network

  • G00 Rapid Traverse Positioning: Cancels G01 linear motion, shifting axes at maximum rapid traverse speed.
  • G10 Parameter Management: Standardizes programming coordinate offsets and parameter writes directly inside G-code programs.
  • Parameter 1851 Backlash Compensation: Adjusts machine axis movements to compensate for physical play during direction reversals under linear cuts.
  • G02 / G03 Circular Interpolation CW/CCW: Cancels linear interpolation, driving axes in circular arcs.
  • G60 Exact Stop Check Mode: Forces the control system to decelerate and verify the axis positions at the end of each G01 path block before beginning the next movement.

Conclusion

Safeguarding CNC machinery during G01 linear cutting requires a disciplined approach to modal command verification, active coordinate offsets, and correct feedrate parameters. Ensuring that every first-article setup begins with a slow-feed verification and single-block execution allows operators to intercept modal coordinate traps before tool contact is made.

FAQ

Why does my machine execute G01 motion at rapid traverse speed?

This is commonly caused by having the Dry Run Feedrate (DRY) switch active on the operator panel, which overrides G01 programmed feedrates with high manual positioning feeds. Verify that the DRY switch is deactivated prior to running any cutting passes and use manual feedrate overrides to check distances-to-go on new programs.

What causes the Alarm PS0011 "FEED ZERO" on Fanuc controls?

The control triggers this alarm when G01 is active but no feedrate has been programmed since system power-on, or if F is set to zero. To resolve this, always specify a valid non-zero feedrate (F-address) inside or before the first G01 motion block in your G-code programs.

How do I prevent tool nose compensation crashes at acute corners?

Cutter compensation start-up blocks (G41 or G42) can cause interference when programmed inside spaces narrower than the tool radius, triggering alarm codes like PS0041 or P153. To prevent this, program the tool compensation startup outside the workpiece boundaries and verify that corner radii exceed the physical tool radius.

Still not resolved?

Ask our AI assistant about this topic in natural language. Grounded in verified sources, no hallucinations.

Ask AI Assistant
Hakan Gündoğdu
Hakan Gündoğdu
  • CNC CARE Co-Founder (May 2025 - Present)
  • Mitsubishi Electric NC Sales & Service Section Manager (2008 - 2025)
  • Reis CNC Service Engineer (2003 - 2008)
  • Ören Kalıp CNC Mold Line Team Leader (1999 - 2002)

With over 25 years of experience working in all areas of the CNC machine industry, I continue my activities as a co-founder of CNC CARE, where we offer brand-independent consulting, engineering, and original spare parts services.

Related Articles

Other articles on this topic