Peter Smid

CNC Tips and Techniques


Скачать книгу

letters O is used instead of the digit 0. These Os are the illegal characters that somehow find their way into the program. For example, the letter Y is not available on a two-axis CNC lathe. Fortunately, the control system will identify these errors.

      Logical Errors

      Watch very carefully for logical errors because the control system has no means to discover them. For example, a missing decimal point or a negative sign will give a totally new meaning to the programmed dimension. X1 is not the same as X1.0, and Z1.0 is not the same as Z-1.0.

      Program Errors

      Program errors that are fairly frequent are often those that can cause severe collisions. Making a tool change inside of a hole is one such error. Others include wrong tool or offset selection, excessive spindle speed or feedrate, selection of tool change position, and many others.

      Offset Errors

      This area is a fertile ground for many frustrations. In my experience, errors relating to the tool nose radius are at the top of this group. If a tool nose radius error is detected by the control system, the cause of this error is always the same — the programmed radius cannot fit into the area provided. This group also represents errors that may be the hardest to identify. Always check the offset settings. If the settings are correct, the program itself is at fault. This error often occurs when the tool nose radius is larger than an inside arc of the contour. It also occurs because of insufficient clearances. Because the most common tool nose radii are 1/64 (0.4 mm), 1/32 (0.8 mm) and 3/64 (1.2 mm), always provide a clearance that is at least twice the largest radius. Typically, 0.100 inches or 2.5 mm is sufficient as the minimum clearance. Keep in mind that this is per side, not on diameter.

      Setup Errors

      Setup errors are strictly the domain of the CNC lathe operator. Check all tools by running the program while the chuck is empty. Are there sufficient clearances? Can the tools index safely? Is the tailstock out of the way? Provide a sufficient grip of the workpiece in the chuck, then watch for the boring bar to exit from a hole safely. Running the first part in a dry run and single block modes may save the day.

      Correcting Errors

      This area deserves special mention. Many operators fail to identify the actual cause of an error. For example, if a drill does not provide the expected depth, is the programmed depth correct? Is the offset set correctly? Is it even possible that the drill was pushed slightly into the holder? Identifying the real cause of a problem is the first step towards its elimination.

      I hope by reviewing some of the common errors found in many programs for CNC lathes that you can look at your own programs and see them in a much different light.

Why Should I Know Manual Programming? February 2004, updated February 2013

      In older days, most CNC programs were developed manually, using simple common and everyday aids — pocket calculator, pencil, paper, and the proverbial five-pound eraser. Combine this human effort with punched tapes and some extra hardware, and you have what seems today a history long past. The tape is gone today, and even though many programmers still sharpen their pencils and purchase new erasers, the times have clearly changed in favor of computer-based programming, or CAM programming. True, CNC programming using personal computers started in the mid-1980s, but initial costs, the state of computer technology, long learning curves, and a lack of features prevented their wide usage for some time.

      Using CNC software to make part programs is not a novelty. Feature rich software from a number of vendors offer the whole gamut of options — from entry level 2D to sophisticated 3D, solids, multi-axis machining, and multi-tasking — all available for desktop and laptop computers. Public and private institutions offer many training programs in this area, often in addition to standard CNC programming courses.

      This brings up the ever more important question that many students ask: “Why should I know manual programming, when I am learning Mastercam?” Of course, there is software available other than Mastercam, but the question raises a good point. I wish I had a dollar for every time this question pops up in conversation or during a training session. So what gives?

      Every CNC programmer has to possess certain skills. One skill I consider the most important is the ability to machine a part. Deciding on the best setup, selecting the most suitable tools, and creating safe and efficient machining operations is the core skill of any successful CNC programmer. The actual method of programming has nothing to do with it. Computers cannot make intelligent decisions.

      Although the part program, in the form of a file or printed copy, is designed for a particular CNC system, we — the programmers and machine operators — have to be able to understand it.

      Let me go through five main reasons for this statement:

      Reason 1 — Myths about Post-Processors

      Most CAM software comes with pre-configured postprocessors in the form of standard text files. These files are intended to be customized by the end user. There is no way for any software vendor to cover all possible combinations that exist between machine tools and control systems. In addition, vendors cannot predict the individual preferences of each user. As a postprocessor is used to format the final output of the part program, you still have to know what that output should be.

      Reason 2 — At the Control with No Control

      When the program runs at the CNC machine, you can watch it scroll by on the control display screen. Do you understand what all the letters and numbers mean? What do you do when there is an error in the program? CNC operators who can make minor (and sometimes even major) changes to the program are much valued by their employers. Some operators do not mind just pushing the buttons, but if you want a certain level of control and responsibility, you have to be able to understand the program itself.

      Reason 3 — Programmer / Operator as an Opportunity

      Small shops and job shops often do not have the luxury of employing a full time CNC programmer. As important as such a person would be to the company, many owners and managers opt for a qualified CNC operator who can also prepare the part programs, then run them. This programmer/operator concept has many benefits for both the employer and the employee. Combine Reasons 1 and 2, and you have a Reason 3.

      Reason 4 — Do You MDI?

      Any operator who sets up a CNC machine has to perform many pre-machining activities, for example, make tool changes, set tools, activate the spindle, orient it, move the table by a certain distance, check a position, and so on. Even with many switches on the panel, one of the best methods is to use the Manual Data Input feature of the control — the MDI. This feature allows you to input and execute data at the control on a temporary basis. The data is always provided in the program format of that control. You cannot use the MDI feature if you do not understand at least the basics of manual programming.

      Reason 5 — Learning from others

      A part program printed on paper does not teach programming or machining methods, yet there is so much to learn from programs that have already been verified. How many of us started our careers by adapting existing programs to our own? A part program that works well offers tremendous opportunity for study and learning. Of course, one has to be able to read such programs — to interpret them — and that means being able to understand the G-codes and M-functions, the program format and structure, offsets, modes, and the many addresses and their subtle meanings.

      Of course, one has to be willing to learn. When you just look at a part program, without understanding it, without being able to interpret it, do you care? Does it bother you? Do you feel you want to know more? If the answer is “yes”, you are on the way of becoming a better programmer or operator — a true professional. But that is reason number six, and I only promised five.

Running the First Part — Economically, That Is March 2004, updated February 2013

      Machining