226 ● TC  DMC-40x0 Command Reference 
TC  
FUNCTION:  Tell Error Code 
DESCRIPTION: 
The TC command returns a number between 1 and 255.  This number is a code that reflects why a 
command was not accepted by the controller. This command is useful when the controller 
halts execution of a program at a command or when the response to a  command is a question 
mark.  The TC command will provide the user with a diagnostic tool.  After TC has been read, 
the error code is set to zero.   
ARGUMENTS:  TC n  where 
n = 0   Returns code only 
n = 1   Returns code and message 
n = ?   Returns the error code 
No argument will provide the error code for all axes 
CODE EXPLANATION  CODE EXPLANATION 
1  Unrecognized command  56  Array index invalid or out of range 
2  Command only valid from program  57  Bad function or array 
3  Command not valid in program  58  Bad command response (i.e._GNX) 
4 Operand error  59 Mismatched parentheses 
5  Input buffer full  60 
Download error - line too long or too 
many lines 
6  Number out of range  61  Duplicate or bad label 
7  Command not valid while running  62  Too many labels 
8  Command not valid when not running  63  IF statement without ENDIF 
9 Variable error  65 IN command must have a comma 
10  Empty program line or undefined label  66  Array space full 
11  Invalid label or line number  67  Too many arrays or variables 
12  Subroutine more than 16 deep  71  IN only valid in task #0 
13 
JG only valid when running in jog 
mode 
80  Record mode already running 
14  EEPROM check sum error  81  No array or source specified 
15 EEPROM write error  82 Undefined Array 
16 
IP incorrect sign during position move 
or IP given during forced deceleration 
83  Not a valid number 
17 
ED, and DL not valid while program 
running 
84 Too many elements 
18  Command not valid when contouring  90  Only A B C D valid operand 
19  Application strand already executing  98 
Binary Commands not valid in 
application program 
20  Begin not valid with motor off  99  Bad binary command number 
21  Begin not valid while running  100  Not valid when running ECAM 
22  Begin not possible due to Limit Switch  101  Improper index into ET  
(must be 0-256)