
axismd.ai
FANUC Controller
Program/G-code · Intermediate · 5-30 minutes
Fanuc 161 - Illegal command in constant cutting
Alarm 161 occurs when an incompatible G-code command is programmed while constant surface speed (G96) or constant pitch threading mode is active. The control cannot execute certain commands like canned cycles, tool nose radius compensation, or specific positioning moves while these constant control modes are engaged.
Fanuc 161 - Illegal command in constant cutting
ILLEGAL COMMAND IN CONSTANT CUTTING
Fanuc PS program alarm 161: ILLEGAL COMMAND IN CONSTANT CUTTING. This alarm is triggered by an illegal or incorrectly formatted command in the part program, or a programming condition that the Fanuc control cannot execute.
Root Cause Summary
Alarm 161 occurs when an incompatible G-code command is programmed while constant surface speed (G96) or constant pitch threading mode is active. The control cannot execute certain commands like canned cycles, tool nose radius compensation, or specific positioning moves while these constant control modes are engaged.
Safety
Causes and Fixes
Locate the N-block number in the alarm message and examine the program line where the alarm occurred.
Check if G96 (constant surface speed) is active in the current program modal state before the alarm line.
Identify if the alarm line contains G70-G76 canned cycles, G41/G42 compensation, or other restricted commands.
Insert G97 (constant spindle speed mode) before the incompatible command, then reactivate G96 after the operation if needed.
Ensure appropriate spindle speed is specified with G97 to prevent spindle overspeed or stalling.
Seeing Multiple Alarms?
Seeing another alarm with this one? Enter the code.
AxisMD logs alarms against your actual machines, tracks patterns, and gives AI context your manual doesn't have.
Start freeWas this guide helpful?
Always verify with your machine manual or a certified technician before performing service procedures.