FANUC codes
FANUCProgram/G-codeIntermediate20-45 minutes

199

Fanuc Alarm 199 - MACRO WORD UNDEFINED

SYSTEM ALARM 199

Fanuc alarm 199: SYSTEM ALARM 199. This alarm indicates a fault condition detected by the Fanuc control. Refer to the alarm number and name to identify the specific system or function involved.

Root Cause Summary

Fanuc Alarm 199 MACRO WORD UNDEFINED occurs when a custom macro program (G65/G66 or macro call) references a macro variable or system variable that does not exist or is not properly defined. This typically happens with incorrect variable syntax, use of reserved but unavailable system variables, or attempted access to variables outside the allowable range for the specific control model.

Causes and Fixes

  1. 1

    Press EDIT mode and review the custom macro program line indicated in the alarm detail. Identify the exact variable number being referenced (e.g., #500, #3001).

  2. 2

    Verify variable syntax is correct: local variables #1-#33, common variables #100-#149 (often requires parameter 6001 bit 0=1 for expansion to #500-#999), system variables #1000+. Check for typos like ##500 or #[undefined].

  3. 3

    Navigate to SYSTEM > PARAM and check parameter 6001 (macro variable memory type). Bit 0=1 enables common variables #100-#999. If using extended variables, verify parameter 6032 (number of sets of common variables) is configured.

    Changing parameter 6001 requires control power cycle and may clear existing macro variable values.

  4. 4

    Cross-reference the system variable number against your specific control series documentation (0i/16i/18i use different system variable sets than 30i/31i/32i). Replace undefined system variables with supported alternatives or local variables.

DIY Feasiblehigh confidence

Call a technician if:

  • ·Multiple macro programs affected simultaneously
  • ·Parameter corruption suspected
  • ·System variable access consistently failing

Prevention

  • Always initialize macro variables before use
  • Use consistent macro programming standards
  • Regularly backup macro programs to CF card
  • Document all custom macro variable assignments

Common Mistakes

  • Forgetting to initialize variables in subroutines
  • Using undefined system variables for specific control series
  • Missing ENDIF statements in conditional blocks
  • Calling non-existent macro programs

Related Alarms

Seeing Multiple Alarms?

Seeing another alarm with this one? Enter the code.

Get machine-aware diagnosis

AxisMD logs alarms against your actual machines, tracks patterns, and gives AI context your manual doesn't have.

Start free

Was this guide helpful?

Always verify with your machine manual or a certified technician before performing service procedures.