This chapter contains information on debugging programs, Anilam Crusader II Error Codes, dry running programs, and running programs.
The problem with CNC programs is that they do exactly what the programmer tells them to...whether or not the programmed action is correct or not. Untested CNC programs typically have bugs (AKA unintentional, undocumented programmatic features of varying consequence). As CNC devices incorporate high speed rotating metallic cutters or pieceparts moving quickly between metal fixtures and clamps, a CNC bug can quickly metamorphose from an inconvenient error into a potentially deadly airborne missile. Be real careful. Until a program has been completely debugged, tested and proved, the programmer/operator should use extreme caution and refrain from using the actual tooling and cutters.
Good computer programming practices include breaking complex programs into smaller and easily tested components or functions. After all of the program's components have been individually developed and tested, they can be assembled into the final program and subjected to a final round of testing. The EIA-274 standard supports three important types of programming "functions": user developed subroutines and pre-programmed X & Y-axis canned cycles and Z-axis canned cycles. Incorporating canned cycles into a program whenever possible and segmenting the program into easily understandable functional subroutines will help minimize both the number of bugs and speed the debugging process.
It is strongly recommended that the programmer/operator team should follow an orderly and stepwise procedure of increasing complexity (and danger) during the debugging and testing phases of program development:
Often during debugging operations, an error is encountered; the controller will then stop, enunciate the error condition with a loud "SQUAWK!," and display a code for the encountered error condition. Please consult the Anilam Crusader II Error Codes (in PDF format) to troubleshoot and rectify.
Follow the steps below to dry-run CNC code:


.
to execute each block one-block-at-a-time.
then the
button to begin your run.
button.
To continue operation, press
.Copyright © 2003-2008 George C. Stanton & Bill Hemphill
All Rights Reserved
Last updated on Sept. 2, 2008 by Bill Hemphill