Siemens SINUMERIK G26 Upper Working Area & Spindle Speed Limit
Master the Siemens SINUMERIK G26 command for upper working area and spindle speed limits. Learn syntax, parameters like SD 43420, and alarms to avoid crashes.
Introduction
An unrestricted spindle speed or out-of-bounds axis movement can trigger a catastrophic hard collision where a tool turret crashes directly into a chuck, vise jaw, or workpiece clamp. When Constant Surface Speed (G96) is active, a control automatically accelerates the spindle as the tool nose approaches the workpiece center. Without a programmed maximum speed limit, the resulting excessive velocity can cause a heavy workpiece to fly out of the chuck jaws, leading to shattered tool spindles, a ruined scrap part, and severe machine downtime. Using the Siemens SINUMERIK G26 command establishes a critical virtual software boundary and upper spindle speed limit, enabling the controller to instantly halt axis movement or restrict RPM to protect valuable shop floor assets.
Technical Summary
| Technical Attribute | Specification |
|---|---|
| Command Code | G26 |
| Modal Group | Group 03 / Modal |
| Applicable Brands | Siemens SINUMERIK |
| Critical Parameters | SD 43420 ($SA_WORKAREA_LIMIT_PLUS), SD 43400 ($SA_WORKAREA_PLUS_ENABLE) |
| Main Constraint | G26 axis limits must be written in a separate NC block. Spindle speed limits overwrite setting data permanently and persist after reset or program end. |
Quick Read
- Active Watchdog Monitoring: Establish the upper working area boundary with X, Y, or Z coordinate values to prevent geometry or channel axes from exceeding safe limits in the basic coordinate system (BCS).
- Multi-Spindle Clamping: Define maximum spindle speeds in RPM using S, S1, or S2 parameters, restricting up to three independent spindles within a single G-code block.
- Parameter-Driven Control: Enable or disable axis-specific positive boundaries by setting the setting data parameter SD 43400 ($SA_WORKAREA_PLUS_ENABLE) to 1 or 0.
- Permanent Boundary Memory: Recognize that programming G26 permanently overwrites the control's setting data, maintaining the limit even after a program reset or system reboot.
- Layout Safety Constraint: Program G26 coordinate limitations in a dedicated, separate NC block without motion commands to prevent syntax and execution errors.
- Dynamic Speed Prevention: Cooperate G26 limits with G96 Constant Surface Speed and LIMS commands to avoid excessive rotational velocities when machining close to the spindle centerline.
Basic Concepts
Implementing G26 upper working area limitations has a profound practical programming effect on machine safety and asset protection. By establishing an upper working area limit, the parts program defines a virtual software boundary. If a programming error occurs, or if manual jog controls drive the axes past these coordinates, the controller instantly interrupts the program and halts movement. This acts as a vital safeguard for high-value machine components such as the tool turret and active toolholder reference points. By defining a safety envelope, the programmer prevents a catastrophic hard collision where the turret or cutting tool crashes directly into a chuck, vise jaw, workpiece clamp, or measuring station, saving the shop from destroyed tool spindles, a ruined scrap part, or a machine-stopping alarm code.
To define a complete safety zone, the G26 upper working-area limit is frequently paired with the g25-lower-working-area limit command. Together, these boundaries create a safe operational corridor for CNC machines. By utilizing this dual boundary setup, operators can ensure that the axes do not drift into dangerous zones during automated runs.
Programmers and operators must remain highly vigilant regarding how working area limits interact with tooling parameters and constant surface speed (G96) cycles. Because tool length and radius compensation are evaluated against the G26 boundaries, changing tool offsets or tool geometry in the control's offset memory can cause the actual tool tip to violate G26 boundaries sooner than expected, triggering an abrupt stoppage. Additionally, when Constant Surface Speed (G96) is active, the control automatically accelerates the spindle as the tool nose on the turret approaches the workpiece center (X0) to maintain a constant cutting rate. If the maximum spindle speed is not restricted using LIMS or G26, the spindle can quickly accelerate to the maximum speed of the gear stage. This excessive velocity can exceed the physical safety limitations of the holding fixtures, causing the workpiece to fly out of the chuck jaws or clamps, resulting in tool breakage, a violent hard collision, and a ruined scrap part.
Command Structure
The G26 command structure is divided into two distinct configurations depending on the intended limiting function. When coordinate words such as X, Y, or Z are specified, the command functions as an axis travel limitation. These coordinate values represent physical boundaries in the basic coordinate system (BCS) and apply to either geometry or channel axes. The controller evaluates these limits in real-time, matching them against active tool geometry offset data to determine if a collision condition exists.
Alternatively, when spindle speed addresses are used, the command functions to limit the maximum speed of active spindles. Siemens SINUMERIK allows multiple spindles to be configured simultaneously in a single NC block. The master spindle is addressed with a plain S, while secondary spindles are identified with address extensions. Programmed maximum speed limitations under G26 are assigned as positive real values ranging from 0.1 rpm to 9999 9999.9 rpm.
Syntax for Axis Limitation:
G26 X... Y... Z... ;Syntax for Spindle Speed Limitation:
G26 S... S1=... S2=... ;Parameter Specifications:
| Parameter / Address | System Identifier | Description | Value Range |
|---|---|---|---|
| X, Y, Z | Geometry Axes Coordinates | Target upper limit values defined in the basic coordinate system (BCS). | Coordinate range of the machine |
| S | Master Spindle | Sets the maximum speed limit in RPM for the master spindle. | 0.1 to 9999 9999.9 rpm |
| S1, S2 | Additional Spindles | Sets the maximum speed limit in RPM for configured secondary spindles. | 0.1 to 9999 9999.9 rpm |
| Working-area limit plus | SD 43420 $SA_WORKAREA_LIMIT_PLUS | Axis-specific setting data defining the upper working area boundary in the positive axis direction. | Numeric coordinate |
| Working-area limit active plus | SD 43400 $SA_WORKAREA_PLUS_ENABLE | Axis-specific setting data that enables (1 / TRUE) or disables (0 / FALSE) the active upper working area limit. | 0 or 1 |
| Geo axis change mode | MD 10604 $MN_WALIM_GEOAX_CHANGE_MODE | Determines whether an active working area limitation is retained (1) or deactivated (0) during geometry axis switchover. | 0 or 1 |
| SD reset save tab | MD 10710 $MN_PROG_SD_RESET_SAVE_TAB | NCK machine data determining if programmed setting data limits (like G26) remain effective after a control RESET or power cycle. | Configured table |
| G-code reset values | MD 20150 $MC_GCODE_RESET_VALUES | Index 3 dictates the default G-code reset position of G-code Group 3. | Configured G-code |
Brand Applications
Siemens SINUMERIK
In Siemens SINUMERIK controls, the G26 command utilizes setting data SD 43420 ($SA_WORKAREA_LIMIT_PLUS) to store the physical upper limit of each axis. To enable this limit in the positive axis direction, the controller requires setting data SD 43400 ($SA_WORKAREA_PLUS_ENABLE) to be configured as active.
To program this safety zone, the code must be written as G26 X... Y... Z... ; in a separate NC block. When controlling spindle speeds, the format changes to G26 S... S1=... S2=... ; to specify up to three independent spindle boundaries. The limits remain stored in setting data after the program finishes or a reset is executed.
| System Category | Identifier / Command | Application Detail |
|---|---|---|
| Parameters | SD 43420 $SA_WORKAREA_LIMIT_PLUS | Defines the axis travel boundary in the positive direction. |
| Parameters | SD 43400 $SA_WORKAREA_PLUS_ENABLE | Enables (1) or disables (0) the positive direction limit. |
| Parameters | MD 10604 $MN_WALIM_GEOAX_CHANGE_MODE | Determines if working area limits remain active (1) or are deactivated (0) during geometry axis switchovers. |
| Parameters | MD 10710 $MN_PROG_SD_RESET_SAVE_TAB | Controls whether programmed G26 setting data remains effective after reset or power cycle. |
| Parameters | MD 20150 $MC_GCODE_RESET_VALUES | Defines the G-code group states at boot-up or reset. Index 3 defines Group 3 status. |
| Alarms | Alarm 22280 | Programmed run-in path too short during G33 thread cutting. |
| Alarms | Alarm 16748 | Programmed spindle speed is outside active gear stage limits during G331 tapping. |
| Alarms | Alarm 14800 | Programmed path velocity is less than or equal to zero. |
| Alarms | Alarm 61816 | Axes do not lie exactly on the machine reference point during G27 check. |
| Versions | SINUMERIK 802D sl | Parameters MD 10604 and MD 20150 are write-protected and cannot be modified. |
| Versions | SINUMERIK 802D | Inverse-time feedrate command G93 is not implemented. |
Warning: Programmed limits under G26 will permanently overwrite system setting data. If an operator does not explicitly redefine these values or turn them off with WALIMOF, the software travel limits will remain active, causing unexpected axis travel alarms during subsequent setup operations or tool changes.
Brand Comparison
| SINUMERIK Model / Series | Machine Data Editability (MD 10604 & MD 20150) | G93 Inverse-Time Feedrate Support | Upper Limit Boundary Retention (G26) |
|---|---|---|---|
| SINUMERIK 840D sl | Fully customizable; parameters can be edited by authorized users. | Supported (standard high-end implementation). | Retained or reset according to MD 10710 configuration. |
| SINUMERIK 802D sl | Write-protected; MD 10604 and MD 10710 cannot be modified. | Supported. | Permanently active but locked to factory defaults. |
| SINUMERIK 802D | Write-protected; MD 10604 and MD 10710 cannot be modified. | Not supported (G93 inverse-time feedrate is missing). | Permanently active but locked to factory defaults. |
Technical Analysis
The functional and administrative differences between Siemens SINUMERIK control series dictate how safety limits are managed. On high-end controls like the SINUMERIK 840D sl, machine tool builders and end-users have the flexibility to edit machine data parameters like MD 10604 and MD 20150. This editability is crucial for customizing behavior during geometry axis switches, ensuring that the G26 working area limit is either retained or deactivated according to specific shop safety protocols. In contrast, on the mid-range SINUMERIK 802D sl, these parameters are write-protected. This protection locks the control to factory defaults, preventing users from altering how the safety limits behave when axes are interchanged or reset.
Feedrate behavior varies across models. High-end controls like the SINUMERIK 840D sl implement advanced motion features like the G93 inverse-time feedrate command. The basic SINUMERIK 802D does not support G93. This lack of support limits the execution of complex multi-axis toolpaths that require coordinated feed rates based on time rather than distance. Operators must carefully analyze control series capabilities when writing programs that rely on these features, making sure to avoid programming unsupported commands or attempting to modify locked system parameters.
Program Examples
The following example defines the upper working area boundaries for the X and Z axes. The coordinate limits must be programmed in a separate block prior to any motion commands.
G26 X80.0 Z330.0 ; Defines the upper working area limitation for X and Z axes in a separate block
WALIMON ; Universally activates the working area limitations programmed with G25 and G26dry run verification:
To perform a dry run of the axis travel limits, run the program with the spindle stopped and without a workpiece. Before boundary verification, commanding a non-modal positioning check like g09-exact-stop-non-modal ensures the axis stops precisely at the limit without rounding errors. Jog the Z-axis in the positive direction toward the Z330.0 boundary. As the tool turret reaches the defined Z330.0 boundary, verify that the controller triggers a software overtravel alarm and halts axis movement immediately, preventing any carriage collision.
The following example configures spindle speed limits for multiple spindles in a single block:
G26 S1400 S2=350 S3=600 ; Sets upper spindle speed limitations for three independent spindlesdry run verification:
To verify the spindle speed limits in a dry run, activate the master spindle using M03 and gradually increase the spindle speed override. Attempt to command a spindle speed higher than 1400 RPM. Verify that the spindle speed caps at exactly 1400 RPM and does not accelerate further. Repeat this procedure for secondary spindles S2 and S3, ensuring they cap at 350 RPM and 600 RPM respectively, without triggering gear stage errors.
Error Analysis
| Alarm Code | Trigger Condition | Operator Symptom | Root Cause / Resolution |
|---|---|---|---|
| Siemens Alarm 22280 | Programmed run-in/run-out path too short during thread cutting. | The machine halts with the error message "Programmed run-in path too short" during G33 cycle execution. | Increase the run-in or run-out parameters (DITS/DITE) or reduce the axis feed acceleration rates. |
| Siemens Alarm 16748 | Programmed spindle speed is outside active gear stage limits during tapping. | Tapping cycle G331 terminates immediately, and the spindle ceases rotation. | Select a gear stage that matches the programmed spindle speed, or modify the spindle speed S in the block. |
| Siemens Alarm 14800 | Path velocity is less than or equal to zero. | The controller generates the alarm "Channel %1 Set %2 programmed path velocity is less than or equal to zero" and halts interpolation. | Specify a positive feedrate F in the program or activate the fixed feedrates functionality before motion. |
| Siemens Alarm 61816 | Axes do not lie exactly on the reference point during check. | The referencing check G27 fails, causing the machine to halt block execution. | Perform a manual or automated reference point return (homing procedure) for the affected axes. |
Application Note
A violent hard collision and a ruined scrap part will occur if an operator modifies tool length offsets or tool geometry in the control's offset memory without updating G26 travel boundaries. Because the Siemens controller evaluates tool length and radius compensation against the active G26 software safety envelope, changing offsets can cause the tool tip to violate the boundary earlier than expected during program execution. To avoid sudden program interrupts, tool offsets must be verified prior to running the program. When constant surface speed (G96) is active, the turret nose approaching the workpiece center (X0) will drive the spindle to its maximum gear stage speed if no LIMS or G26 limits are programmed. If the spindle speed is unrestricted, centrifugal forces can cause the workpiece to fly out of the chuck jaws or clamps, resulting in tool breakage and severe machine damage.
Related Command Network
- G25: Defines the lower working area limitation or lower spindle speed limitation to protect tool holders from crashing into the lower envelope boundaries.
WALIMON/WALIMOF: Universally activates or deactivates the working area limitation for all validated geometry and channel axes.LIMS: Restricts the maximum spindle speed of the master spindle specifically during G96 constant surface speed operations.G96/G97: Activates and deselects the constant surface speed mode, which automatically adjusts spindle speed based on the cutting diameter.- G11: Cancels programmable data inputs, restoring default coordinate configurations after temporary limits are programmed.
Conclusion
Safeguarding a CNC machine tool against overtravel and spindle overspeed requires proactive use of software boundaries. Configuring G26 ensures that both axes and spindle rotation operate within strict safety envelopes, protecting spindles, turrets, and fixtures. Programming this command in separate blocks and verifying tool offset modifications will maintain continuous machining cycles and prevent mechanical damage on the shop floor.
FAQ
How does Siemens G26 differ from the Fanuc G26 command?
Siemens G26 serves as an axis travel limit and spindle speed ceiling, whereas Fanuc uses G26 exclusively for spindle speed fluctuation detection. Operators transitioning to Siemens must write G26 limits in dedicated blocks and verify setting data retention, as the Siemens limit persists after resetting the control.
Why did my SINUMERIK control deactivate the working area limit after an axis switchover?
An active working area limit is deactivated during geometry axis switchovers if parameter MD 10604 is set to 0. Change the value of MD 10604 to 1 to retain active limits during axis interchange, and check the status of setting data SD 43400 to confirm that the limits remain enabled.
What is the difference between LIMS and G26 for limiting spindle speeds?
LIMS limits the spindle speed dynamically during constant surface speed (G96) operations, while G26 acts as a permanent, absolute maximum spindle speed ceiling stored in the controller's setting data. Always program G26 first to set the absolute spindle safety limit, then use LIMS to throttle speeds during fine-facing passes near the center axis.
Still not resolved?
Ask our AI assistant about this topic in natural language. Grounded in verified sources, no hallucinations.

- 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
G27 Reference Position Return Check: CNC Guide for Multi-Brand Systems
Master the CNC G27 reference position return check on Fanuc, Siemens, and Mitsubishi controls. Learn parameters like MD 34100 and fix Alarm 61816.
G26 Spindle Speed Fluctuation Detection ON: CNC Programming Guide
Learn how to configure G26 on Fanuc, Siemens, and Mitsubishi CNC controls to prevent spindle speed fluctuations, set travel limits, and avoid tool crashes.
G25 Lower Working Area and Spindle Speed Limit: Siemens CNC
Master G25 lower working area and spindle speed limits on Siemens SINUMERIK controls. Avoid chuck collisions and configure safety parameter SD 43430.
G25 Spindle Speed Fluctuation Detection OFF: CNC Programming Guide
Learn how to program G25, G163, and G26 spindle speed fluctuation detection OFF commands on Fanuc, Siemens, and Mitsubishi CNC controls to prevent machine crashes.