Documente Academic
Documente Profesional
Documente Cultură
Today, computer numerical control (CNC) machines are found almost everywhere, from small job shops in rural communities to Fortune 500 companies in large urban areas. Truly, there is hardly a facet of manufacturing that is not in some way touched by what these innovative machine tools can do. Everyone involved in the manufacturing environment should be well aware of what is possible with these sophisticated machine tools. The design engineer, for example, must possess enough knowledge of CNC to perfect dimensioning and tolerancing techniques for workpieces to be machined on CNC machines. The tool engineer must understand CNC in order to design fixtures and cutting tools for use with CNC machines. Quality control people should understand the CNC machine tools used within their company in order to plan quality control and statistical process control accordingly. Production control personnel should be abreast of their company's CNC technology in order to make realistic production schedules. Managers, foremen, and team leaders should understand CNC well enough to communicate intelligently with fellow workers. And it goes without saying that CNC programmers, setup people, operators, and others working directly with the CNC equipment must have an extremely good understanding of this technology. In this text, we will explore the basics of CNC, showing you much of what is involved with using these sophisticated machine tools. Our primary goal will be to teach you how to learn about CNC. For readers who will eventually be working directly with CNC machine tools, we will show you the basics of each major CNC function. Additionally, we will make suggestions as to how you can learn more about each CNC function as it applies to your particular CNC machine(s). At the completion of this presentation, you should have a good understanding of how and why CNC functions as it does and know those things you must learn more about in order to work with any style of CNC machine tool. For readers who are not going to be working directly with CNC equipment in the near future, our secondary goal will be to give you a good working knowledge of CNC technology. At the completion of this presentation, you should be quite comfortable with the fundamentals of CNC and be able to communicate intelligently with others in your company about your equipment. To proceed in an organized manner, we will use a "key concepts" approach to all presentations. All important functions of CNC are organized into ten key concepts. Think of it this way. If you can understand these ten basic principles, you are well on your way to becoming proficient with CNC. While our main focus will be on the two most popular forms of CNC machine tools (machining centers and turning centers), these ten key concepts can be applied to virtually any kind of CNC machine. With so many types of CNC machine tools in existence, it is next to impossible for this presentation to be extremely specific about any one particular type. The key concepts allow us to view the main features of CNC in more general terms, stressing why things are handled the way they are even more than the specific techniques used with any one particular CNC machine tool. With this broad background, you should be able to easily zero in on any kind of CNC machine tool you will be working with. As yet a third goal, this presentation should help instructors of CNC. The key concepts approach we show has been proven time and time again during live presentations in CNC courses. This method of presentation will help instructors organize CNC into extremely logical and easy-to-understand lessons. Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
The first benefit offered by all forms of CNC machine tools is improved automation. The operator intervention related to producing workpieces can be reduced or eliminated. Many CNC machines can run unattended during their entire machining cycle, freeing the operator to do other tasks. This gives the CNC user several side benefits including reduced operator fatigue, fewer mistakes caused by human error, and consistent and predictable machining time for each workpiece. Since the machine will be running under program control, the skill level required of the CNC operator (related to basic machining practice) is also reduced as compared to a machinist producing workpieces with conventional machine tools. The second major benefit of CNC technology is consistent and accurate workpieces. Today's CNC machines boast almost unbelievable accuracy and repeatibility specifications. This means that once a program is verified, two, ten, or one thousand identical workpieces can be easily produced with precision and consistency. A third benefit offered by most forms of CNC machine tools is flexibility. Since these machines are run from programs, running a different workpiece is almost as easy as loading a different program. Once a program has been verified and executed for one production run, it can be easily recalled the next time the workpiece is to be run. This leads to yet another benefit, fast change-overs. Since these machines are very easy to set up and run, and since programs can be easily loaded, they allow very short setup time. This is imperative with today's just-in-time production requirements.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
Figure 1. A conventional machine's slide is moved by an operator turning the handwheel. Accurate positioning is accomplished by the operator counting the number of revolutions made on the handwheel, plus the graduations on the dial.
actuated by servomotors under control of the CNC, and guided by the part program. Generally speaking, the motion type (rapid, linear, and circular), the axes to move, the amount of motion
and the motion rate (feed rate) are programmable with almost all CNC machine tools. Figure 1 (above) shows the motion control of a conventional machine tool. Figure 2 (below) shows the makeup of a linear axis of a CNC machine. A CNC command executed within the control (commonly through a program) tells the drive motor
to rotate a precise number of times. The rotation of the drive motor in turn rotates the ballscrew. And the ballscrew drives the linear axis. A feedback device at the opposite end of the ballscrew allows the control to confirm that the commanded number of rotations has taken place. Though a rather crude analogy, the same basic linear motion can be found on a common table vise. As you rotate the vise crank, you rotate a leadscrew that, in turn, drives the movable jaw on the vise. By comparison, a linear axis on a CNC machine tool is extremely precise. The number of revolutions of the axis drive motor precisely controls the amount of linear motion along the axis.
One very common application for the rectangular coordinate system is graphing. Almost everyone has had to make or interpret a graph. Since the need to utilize graphs is so commonplace, and since it closely resembles what is required to cause axis motion on a CNC machine, let's review the basics of graphing. Figure 3 (at left) is a graph of a company's productivity for last year. As with any twodimensional graph, this graph has two base lines. Each base line is used to represent something. What the base line represents is broken into increments. Also, each base line has limits. In our productivity example, the horizontal base line is being used to represent time. For this base line, the time increment is in months. Notice this base line has limitsit starts with January and ends with December. The vertical base line represents productivity. Productivity is broken into ten percent increments and starts at zero percent productivity and ends with one hundred percent productivity. The person making the graph would look up the company's productivity for January of last year and at the productivity position on the graph for January, a point is plotted. This would Figure 3. Graph illustrates the use of base lines, the increments used for each base line, and the origin point used when graphing. then be repeated for February, March, and each month of the year. Once all points are plotted, a line or curve can be drawn through each of the points to make it more clear as to how the company did last year.
Let's take what we now know about graphs and relate it to CNC axis motion. Instead of plotting theoretical points to represent conceptual ideas, the CNC programmer is going to be plotting physical end points for axis motions. Each linear axis of the machine tool can be thought of as like a base line of the graph. Like graph base lines, axes are broken into increments. But instead of being broken into increments of conceptual ideas like time and productivity, each linear axis of a CNC machine's rectangular coordinate system is broken into increments of measurement. In the inch mode, the smallest increment may be 0.0001 inch. In the metric mode, the smallest increment may be 0.001 millimeter. (By the way, for rotary axis the increment is 0.001 degrees.) Just like the graph, each axis within the CNC machine's coordinate system must start somewhere. With the graph, the horizontal base line started at January and the vertical base line started at zero-percent productivity. This place where the vertical and horizontal base lines come together is called the origin point of the graph. For CNC purposes, this origin point is commonly called the program zero point (also called work zero, part zero, or program origin). Figure 4 (at right) shows how axis motions are commonly commanded on CNC machines. For this example, the two axes we happen to be showing are labelled as X and Y, but keep in mind that program zero can be applied to any axis. Though the name of each axis will change from one CNC machine type to another (other common names include Z, A, B, C, U, V, and W), this example should work nicely to show you how axis motion can be commanded. As you can see, the lower left hand corner of the workpiece has been made to correspond to the zero position for each axis. That is, the lower left-hand corner of the workpiece is the program zero point. Prior to writing the program, the programmer determines the position of the program zero point. Typically, the program zero point is chosen as the point where all dimensions begin.
With this technique, if the programmer wishes the tool to be sent to a position one inch to the right of the program zero point, X1.0 is commanded. If the programmer wishes the tool to move to a position one inch above the program zero point, Y1.0 is commanded. The control will automatically determine how many times to rotate each axis drive motor and ballscrew to make the axis reach the commanded destination point. This lets the programmer command axis motion in a very logical manner. With the examples given so far, all points happened to be up and to the right of the program zero point. This area up and to the right of the program zero point is called a quadrant (in this case, quadrant number one). It is not uncommon on CNC machines that end points needed within the program fall in other quadrants. When this happens, at least one of the coordinates must be specified as minus. Figure 5 (below) shows the relationship of the four quadrants as well as the plus and minus representations required for each. Figure 6 (below) shows one common application of when end points fall in all four quadrants and negative coordinates must be specified. Figure 4. Rectangular coordinate system for X-Y plane. The program zero point establishes the point of reference for motion commands in a CNC program. This allows the programmer to specify movements from a common location. If program zero is chosen wisely, usually coordinates needed for the program can be taken directly from the print.
Be careful when making motion commands. Beginners have the tendency to think incrementally. If working in the absolute mode (as beginners should), the programmer should always be asking "To what position should the tool be moved?" This position is relative to program zero, not from the tool's current position. Figure 7 (below) shows two identical series of movements, one in the incremental mode and the other in the absolute mode.
point of each motion command. As you have seen, doing this requires an understanding of the rectangular coordinate system. However, there are other concerns about how a motion will take place. For example, the type of motion (rapid, straight line, circular, etc.), and motion rate (feed rate) will also be of concern to the programmer. We'll discuss these other considerations during key concept number three.
by-step instructions. Say, for example, you have some visitors coming in from out of town to visit your company. You need to write down instructions to get from the local airport to your company. To do so, you must first be able to visualize the path from the airport to your company. You will then, in sequential order, write down one instruction at a time. The person following your instructions will perform the first step and then go on to the next until he or she reaches your facility. In similar manner, a manual CNC programmer must be able to visualize the machining operations that are to be performed during the execution of the program. Then, in step-by-step order, the programmer will give a set of commands that makes the machine behave accordingly. Though slightly off the subject at hand, we wish to make a strong point about visualization. Just as the person developing travel directions must be able to visualize the path taken, so must the CNC programmer be able to visualize the movements the CNC machine will be making before a program can be successfully developed. Without this visualization ability, the programmer will not be able to develop the movements in the program correctly. This is one reason why machinists make the best CNC programmers. An experienced machinist should be able to easily visualize any machining operation taking place. Just as each concise travel instruction will be made up of one sentence, so will each instruction given within a CNC program be made up of one command. Just as the travel instruction sentence is made up of words (in English), so is the CNC command made up of CNC words (in CNC language). The person following your set of travel instructions will execute them explicitly. If you make a mistake with your set of instructions, the person will get lost on the way to your company. In similar fashion, the CNC machine will execute a CNC program explicitly. If there is a mistake in the program, the CNC machine will not behave correctly. At right is a short example program that drills two holes in a workpiece on a CNC machining center. Keep in mind that we are not stressing the actual commands in this program (though the messages in parentheses should make it relatively clear as to what is happening in each command). Instead, we are stressing the structure of a CNC program and the fact that it will be executed sequentially. While the words and commands in this program probably do not make much sense to you (yet), remember that we are stressing the sequential order by which the CNC program will be executed. The control will first read, interpret and execute the very first command in the program. Only then will it go on to the next command. Read, interpret, execute. Then on to the next command. The control will continue to execute the program in order for the balance of the program. Again, notice the similarity to giving any set of step-by-step instructions.
O0001 (Program number) N005 G54 G90 S400 M03 (Select coordinate system, absolute mode, and turn spindle on CW at 400 RPM) N10 G00 X1. Y1. (Rapid to XY location of first hole) N015 G43 H01 Z.1 M08 (Instate tool length compensation, rapid in Z to clearance position above surface to drill, turn on coolant) N020 G01 Z-1.25 F3.5 (Feed into first hole at
Z - Z-axis designation R - Radius designation F - Feedrate designation S - Spindle speed designation H - Tool length offset designation D - Tool radius offset designation T - Tool Designation M - Miscellaneous function As you can see, many of the letter addresses are chosen in a logical manner (T for tool, S for spindle, F for feed rate, etc.). A few require memorizing. There are two letter addresses (G and M) which allow special functions to be designated. The preparatory function (G) specifies is commonly used to set modes. We already introduced absolute mode, which is specified by G90 and incremental mode, specified by G91. These are but two of the preparatory functions used. You must reference your control manufacturer's manual to find the list of functions for your machine. Like preparatory functions, miscellaneous functions (M words) allow a variety of special functions. Miscellaneous functions are typically used as programmable switches (like spindle on/off, coolant on/off, and so on). They are also used to allow programming of many other programmable functions of the CNC machine tool. To a beginner, all of this may seem like CNC programming requires a great deal of memorization. But rest assured that there are only about 30-40 different words used with CNC programming. If you can think of learning CNC manual programming as like learning a foreign language that has only 40 words, it shouldn't seem too difficult.
3.5 inches per minute) N025 G00 Z.1 (Rapid back out of hole) N030 X2. (Rapid to second hole) N035 G01 Z-1.25 (Feed into second hole) N040 G00 Z.1 M09 (Rapid out of second hole, turn off coolant) N045 G91 G28 Z0 (Return to reference position in Z) N050 M30 (End of program command)
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
If you already know basic machining practice as it relates to the CNC machine you will be working with, you already know what it is you want the machine to do. Mike Lynch President, CNC Concepts, Inc.
A CNC user must understand the makeup of the CNC machine tool being used. While this may sound like a basic statement, a CNC user must be able to view the machine from two distinctly different perspectives. Here in key concept number two, we will be viewing the machine from a programmer's perspective. Much later, in key concept number seven, we will look at the machine from an operator's point of view.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Machine Components
While you do not have to be a machine designer to work with CNC equipment, it is important to know how your CNC machine is constructed. This will help you to gage the limits of what is possible with your machine. Just as the race car driver should understand the basics of suspension systems, breaking systems, and the workings of internal combustion engines (among other things) in order to get the most out of a given car, so must the CNC programmer understand the basic workings of the CNC machine in order to get the most from it.
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
For a universal style, slant-bed turning center, for example, the programmer should know the bed, way system, headstock and spindle, turret construction, tailstock, and workholding device. Information regarding the machine's construction, including assembly drawings, is usually published right in the machine tool builder's manual. As you read the manual, here are some of the machine capacity and construction questions to which you should find answers.
Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone
1. What is the machine's maximum RPM? Visit MMS' CAD/CAM Software Zone 2. How many spindle speed ranges does the machine have and what are the cut-off points for each range? Link a Friend to This Page Via E-mail 3. What is the spindle and axis drive motor horsepower? 4. What is the maximum travel distance in each axis? 5. How many tools can the machine hold? 6. What way construction does the machine incorporate (usually square ways, dovetail, and/or linear bearing ways). 7. What is the machine's rapid rate (fastest traverse rate)? 8. What is the machine's fastest cutting feed rate? These are but a few of the questions you should be asking yourself as you begin working with any new CNC machine. Truly, the more you know about your machine's capacity and construction, the easier it will be to get comfortable with the machine.
Programmable functions
The programmer must also know what functions of the CNC machine are programmable (as well as the related commands). With low cost CNC equipment, oftentimes many machine functions must be manually activated. With some CNC milling machines, for example, about the only programmable function is axis motion. Spindle speed and direction, coolant and tool changes may have to be activated manually by the operator. With full blown CNC equipment, on the other hand, almost everything is programmable and the operator may only be required to load and remove workpieces. Once the cycle is activated, the operator is freed to do other functions.
Reference the machine tool builder's manual to find out what functions of your machine are programmable. To give you some examples of how many programmable functions are handled, following are a few of the most common programmable functions along with their related programming words. Spindle Control. An "S" word is used to specify the spindle speed (in RPM for machining centers). An M03 is used to turn the spindle on in a clockwise (forward) manner. M04 turns the spindle on in a counter clockwise manner. M05 turns the spindle off. Note that turning centers also have a feature called constant surface speed which allows spindle speed to be specified in surface feet per minute (or meters per minute). Automatic Tool Changer (Machining Center). A "T" word is used to tell the machine which tool station is to be placed in the spindle. On most machines, an M06 tells the machine to actually make the tool change. Tool Change (On Turning Centers). A four digit "T" word is used to command tool changes on most turning centers. The first two digits of the T word specify the turret station number and the second two digits specify the offset number to be used with the tool. T0101, for example, specifies tool station number one with offset number one. Coolant Control. M08 is used to turn on flood coolant. If available, M07 is used to turn on mist coolant. M09 turns off the coolant. Automatic Pallet Changer. An M60 command is commonly used to make pallet changes.
G G
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
Effectively commanding motion on most CNC machines requires more than describing how the CNC machine determines the end point position for each motion. Mike Lynch President, CNC Concepts, Inc.
During key concept number one, we discussed how end points for axis motion are commanded utilizing the rectangular coordinate system. During that presentation, however, we were only concerned with describing how the CNC machine determines the end point position for each motion. To effectively command motion on most CNC machines requires more than that for positioning movements. CNC control manufacturers try to make it as easy as possible to make movement commands within the program. For those styles of motion that are commonly needed, they give the CNC user various types of interpolation.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Understanding Interpolation
Say for example, you wish to move only one linear axis in a command. You want to move the X axis to a position one inch to the right of program zero. In this case, the command X1. would be given (assuming the absolute mode is instated). The machine would move along a perfectly straight line during this movement (since only one axis is moving). Now let's say you wish to include a Y axis movement to a position one inch above program zero in Y (with the X movement). We'll say you are trying to machine a tapered or chamfered surface of your workpiece in this command. For the control to move along a perfectly straight line to get to the programmed end point, it must perfectly synchronize the X and Y axis movements. Also, if machining is to occur during the motion, a motion rate (feed rate) must also be specified. This requires linear interpolation. During linear interpolation commands, the control will precisely and automatically calculate a series of very tiny single axis departures, keeping the tool as close to the programmed linear path as possible. With today's CNC machine tools, it will appear that the machine is forming a perfectly straight line motion. However, Figure 1 (at right) shows what the CNC control is actually doing during linear interpolation. In similar fashion, many applications for CNC machine tools require that the machine be able to form circular motions. Applications for circular motions include forming radii on turned workpieces between faces and turns, and milling radii on contours on machining centers. This kind of motion requires circular interpolation. As with linear interpolation, the control will do its best to generate as Figure 1. Actual motion generated with linear interpolation. Notice the series of very tiny single axis movements. The step size is equal to the machine's resolution, usually 0.0001 inch or 0.001mm.
Key Concept #2
Know Your Machine
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
close to a circular path as possible. Figure 2 (below) shows what happens during circular interpolation. Depending on the machine's application, you may find that you have other interpolation types available. Again, CNC control manufacturers try to make it as easy as possible to program their controls. For example, many machining center users perform thread milling operations on their machines. During thread milling, the machine must move in a circular manner along two axes (usually X and Y) at the same time a third axis (usually Z) moves in a linear manner. This allows the helix of the thread to be properly machined. This motion resembles a spiraling motion
(though the radius of the spiral remains constant). Knowing that their customers need this type of motion for thread milling, CNC machining center control manufacturers offer the feature called helical interpolation. Yet another type of interpolation may be required on turning centers that have live tooling. For turning centers that can rotate tools (like end mills) in the turret and have a C axis to rotate the workpiece held in the chuck, polar coordinate interpolation can be used to mill contours around the periphery of the workpiece. Polar coordinate interpolation allows the programmer to "flatten out" the rotary axis, treating it as a linear axis for the purpose of making motion commands.
This motion type is used to command motion at the machine's fastest possible rate. It is used to minimize non-productive time during the machining cycle. Common uses for rapid motion include positioning the tool to and from cutting positions, moving to clear clamps and other obstructions, and in general, any non-cutting motion during the program. You must check in the machine tool builder's manual to determine a machine's rapid rate. Usually this rate is extremely fast (some machines boast rapid rates of well over 1000 ipm!), meaning the operator must be cautious when verifying rapid motion commands. Fortunately, there is a way for the operator to override the rapid rate during program verification. The command almost all CNC machines use to initiate rapid motion is G00. Within the G00 command, the end point for the motion is given. Control manufacturers vary with regard to what actually happens if more than one axis is included in the rapid motion command. With most controls, the machine will move as fast as possible in all axes commanded. In this case, one axis will probably reach its destination point before the others. With this kind of rapid command, straight line movement will not occur during rapid and the programmer must be very careful if there are obstructions to avoid. With other controls, straight line motion will occur, even during rapid motion commands.
Circular Motion
This motion type causes the machine to make movements in the form of a circular path. As discussed earlier during our presentation of circular interpolation, this motion type is used to generate radii during machining. All feed rate related points made during our discussion of straight line motion still apply. Two G codes are used with circular motion. G02 is commonly used to specify clockwise motion while G03 is used to specify counter clockwise motion. To evaluate which to use, you simply view the movement from the same perspective the machine will view the motion. For example, if making a circular motion in XY on a machining center, simply view the motion from the spindle's vantage point. If making a circular motion in XZ on a turning center, simply view the motion from above the spindle. In most cases, this is as simple as viewing the print from above.
Additionally, circular motion requires that, by one means or another, the programmer specify the radius of the arc to be generated. With newer CNC controls this is handled by an "R" word that simply states the radius. With older controls, directional vectors (specified by I, J, and K) tell the control the location of the arc's center point. Since controls vary with regard to how directional vectors are programmed, and since the R word is becoming more and more popular for radius designation, our examples will show the use of the R word. If you wish to learn more about directional vectors, refer to your control manufacturer's manual. MMS
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
Though applied for different reasons on different machine types, all forms of compensation allow the CNC user to allow for unpredictable conditions related to tooling. Mike Lynch President, CNC Concepts, Inc.
All types of CNC machine tools require some form(s) of compensation. Though applied for different reasons on different machine types, all forms of compensation allow the CNC user to allow for unpredictable conditions related to tooling. Before discussing how compensation applies to CNC usage, let's look at compensation in general terms. Compensation is used in many facets of everyday life. Consider, for example, how a marksman firing a rifle compensates for the distance to the target. The marksman analogy is amazingly similar to what happens with many forms of compensation on CNC equipment, so let's discuss it further. Say a marksman is standing 50 yards from a target. By one means or another, he would adjust the sight on the rifle to allow for the distance. But until the first shot is fired, the marksman would not know for sure whether the initial sight adjustment was perfectly correct. Once the first shot is fired and the marksman sees the resulting hole location, the sight might have to be fine tuned to adjust for minor imperfections with the initial adjustment. In similar fashion, the CNC user will be faced with several situations when it will be impossible to predict exactly the result of certain tooling related problems. So one form or another of compensation will have to be used to handle the problem. But just as the marksman may have to fine tune after the initial shot, so may the CNC user have to fine tune the initial compensation entry. More on how and why in a little while.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #9
Key Sequences Of Operation
Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
Offsets can be used for several purposes, depending on the style of machine tool and type of compensation being used. Here are some of the more common applications for offsets. To specify each tool's length. For machining center applications, it would be very difficult for the programmer to predict the precise length of each tool used in the program. For this reason, the tool length compensation feature allows the programmer to ignore each tool's length as the program is written. At the time of setup, the setup person measures the length of each tool and inputs the tool length value into the corresponding offset.
To specify the radius of the cutting tool. When milling on the periphery of the cutter, it can be cumbersome and difficult for the programmer to create tool path based on the size of the milling cutter being used. Also, if the cutter size must change (possibly due to resharpening), it would be impractical to change the program based on the new cutter size. For this reason, the cutter radius compensation feature allows the programmer to ignore the cutter size as the program is written. The setup person inputs the size of each milling cutter into its corresponding tool offset. Similarly, turning centers have a feature called tool nose radius compensation. With this feature, an offset is used to specify the radius of the very tip of the turning or boring tool. To assign program zero. Machining centers that have fixture offsets (also called coordinate system shifting) allow the user to specify the position of the program zero point within offsets, keeping the assignment of program zero separate from the program. Many turning centers also allow the assignment of program zero with offsets (this feature is commonly called geometry offsets). To allow sizing on turning centers. Tool offsets are used on all turning centers to allow the operator to hold size with tools used within their programs. This allows the operator to adjust for imperfections with tool placement during setup. It also allows the operator to compensate for wear during each tool's life.
Organizing Offsets
With some CNC controls, the organization of offsets is very obvious. Some machining center controls, for example, automatically make the offset number correspond to the tool station number. With this kind of machine, when tool station number one is commanded, the control will automatically invoke offset number one. Within offset number one, the operator can store a tool length value as well as a tool radius value. Figure 1 (below) shows the offset table for this kind of machining center. But, not all controls make it this simple. In some, each offset contains only one value and the offset number has no real relationship to the tool station number. In this case, the programmer must cautiously organize which offsets are used with each tool.
Figure 1. Offset tables in CNCs allow users to compensate for unpredictable conditions related to tooling. The table at right provides an offset position for both tool length and diameter. With a simpler table (middle) that only allows one entry per offset, the programmer must make it quite clear as to the function of each entry. On a popular turning center control, four values can be entered for each offset (at left).
For example, the tool length compensation offset numbers can be made the same as tool station numbers. Cutter radius compensation offset numbers can be made equal to the tool station number plus a constant value larger than the number of tools the machine can hold. If the machine can hold 25 tools, tool station number one could be made to use offset number one to store its length compensation value and offset number thirty-one could be used to store its cutter radius compensation value. With this method of offset organization, the programmer and operator are constantly in sync. Figure 1 (above) shows an offset table for this kind of machining center. The offset table on most turning centers incorporates at least two values per offset. Generally speaking, the programmer will instate the offset number corresponding to the tool station number for each tool offset used. That is, tool number one will use (only) offset number one, tool two will use offset two, and so on. Typically the tool nose radius (R column of the offset table) and the tool type (the T column of the offset table) can be specified within the turning center's offset table. Figure 1 (above) also shows this sort of offset table for a popular turning center control.
Types of compensation
Now let's discuss the compensation types in a little more detail. Keep in mind that while the actual use of these functions can vary dramatically from one machine to the next, the basic reasoning behind each compensation type remains remarkably similar. With an understanding of why the compensation type is required, and with an elementary understanding of how it is applied to one specific control, you should be able to adapt to any variations that you come across.
corresponding offset. This, of course, means the tool must first be measured. If tool length compensation is used wisely, the tool can be measured off line (in a tool length measurement gage) to minimize setup time. Figure 2 (at right) shows one popular method of determining the tool length compensation value. With this method, the value is simply the length of the tool. A popular command to instate tool length compensation is G43. Within the G43 command, the programmer includes an H word that specifies the number of the offset containing the tool's length value. Here is an example program that utilizes tool length compensation with two tools. The program simply drills two holes (one with each tool). Notice that tool length compensation is being instated in lines N015 and N055. Program O0001 (Program number) N005 T01 M06 (Place tool number one in the spindle) N010 G54 G90 S400 M03 T02 (Select coordinate system, absolute mode, start spindle CW at 400 RPM, get tool number two ready) N010 G00 X1.0 Y1.0 (Rapid to first XY position) N015 G43 H01 Z.1 M08 (Instate tool length compensation on first Z move, turn on coolant) N020 G01 Z-1.5 F4. (Drill hole) N025 G00 Z.1 M09 (Rapid out of hole, turn off coolant) N030 G91 G28 Z0 M19 (Return to tool change position, orient spindle) N035 M01 (Optional stop) N040 T02 M06 (Place tool number two in spindle) N045 G54 G90 S400 M03 T01 (Select coordinate system, absolute mode, start spindle at 400 RPM, get tool number one ready) N050 G00 X2. Y1. (Rapid to first XY position) N055 G43 H02 Z.1 M08 (Instate tool length compensation on tool's first Z move, turn on coolant) N060 G01 Z-1.2 F5.5 (Drill hole) N065 G00 Z.1 M08 (Rapid out of hole, turn off coolant) N070 G91 G28 Z0 M19 (Return to tool change position, orient spindle) N075 M30 (End of program) As stated, this feature varies dramatically in use from one control model to the next. You must reference your control manufacturer's programming manual to learn more about how tool length compensation applies to your particular machining center. Figure 2. With tool length compensation, the tool's length compensation value is stored separate from the program. Many CNC controls allow the length of the tool to be used as the offset value.
For critical surfaces or when the effects of tool pressure are unpredictable, the operator can even trial cut the workpiece under the influence of an offset slightly larger than the measured value to ensure that some excess stock will be left. After machining, the operator can measure the surface to determine precisely how much offset change is necessary to machine the workpiece to size.
Easy Sizing
As with tool length compensation, the operator can use the cutter radius compensation offset to help with sizing. If the contour is not coming out to size (possibly due to tool pressure), an offset can be changed to allow for the imperfection.
machining and ask yourself if the cutter is on the left or right side of the surface being machined. If on the left, use G41. If on the right, use G42. Figure 3 shows some examples that should help you understand how to determine whether to use G41 or G42 to instate. Once cutter radius compensation is properly instated, the cutter will be kept on the same side of all surfaces until the G40 command to cancel compensation. Figure 4 (below) shows the drawing to be used for our example program. In line N025, cutter radius compensation is being instated. From this point on, work surface coordinates can be used for the cutter path. The tool will be kept away from all surfaces by the value stored in offset number thirtyone. Program O0001 (Program number) N005 G54 G90 S350 M03 (Select coordinate system, absolute mode, start spindle CW at 350 RPM) N010 G00 X-.6 Y-.6 (Rapid to point 1) N015 G43 H01 Z.1 M08 (Instate tool length compensation, move to clearance position in Z, turn on coolant) N020 G01 Z-.25 F30. (Fast feed to work surface) N025 G42 D31 Y.25 F4. (Instate cutter compensation to point 2) N030 X4.25 (Feed to point 3) N035 G03 X4.75 Y.75 R.5 (Circular move to point 4) N040 G01 Y2.25 (Feed to point 5) N045 G03 X4.25 Y2.75 R.5 (Circular move to point 6) N050 G01 X.75 (Feed to point 7) N055 G03 X.25 Y2.25 R.5 (Circular move to point 8) N060 G01 Y.75 (Feed to point 9) N065 G03 X.75 Y.25 R.5 (Circular move to point 10) N070 G00 Z.1 M09 (Rapid away in Z, turn off coolant) N075 G40 (Cancel cutter radius compensation) N080 G91 G28 Z0 (Return to reference position in Z) N100 M30 (End of program) Figure 4. Sample part for cutter radius compensation.
Figure 3. Drawings show how to determine whether to use G41 or G42 to instate cutter radius compensation.
Fixture Offsets
Just as tool length and cutter radius compensation allow the programmer to forget about cutting tools as the program is written, fixture offsets allow the programmer to forget about the workholding setup. As you know from key concept number one, the programmer will be calculating all coordinates for the program from the program zero point. The CNC control must be told the location of program zero in order to make positioning movements properly. And this must be done before the program can be run. One very convenient way to specify position of the program zero point is with fixture offsets. Within the fixture offset, the setup person will store the distance between the machine's reference position and the program zero point for each axis. This usually requires that a measurement be taken to determine the required distances.
CNC controls vary dramatically with regard to the words used to instate the fixture offset. Some controls allow only one program zero point to be assigned per program and no special CNC command is needed to instate the fixture offset. This kind of control simply assumes the values have been stored correctly. Other controls allow multiple program zero points to be specified (with multiple fixture offsets). These controls require that the programmer specify which fixture offset to use. One popular control uses the set of G codes ranging from G54 through G59 for this purpose. G54 instates fixture offset number one, G55 instates fixture offset number two, and so on through G59. Any axis coordinates specified will be taken from the current program zero position. With this kind of control, the setup person must know which fixture offsets are being used in the program in order to store the measured values into the correct locations.
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
Simplicity and consistency are the hallmarks of good programming.
As stated in key concept number one, the CNC control will execute a part program exactly as it is written so all commands necessary to make the machine do the required operations must be sequenced in the proper order. And of course, part of learning how to program is understanding the program structure a CNC machine requires. One of the main reasons to strictly format CNC programs has to do with making it easy to write your first few programs. When writing your first program, the related commands will by no means be memorized. However, if you have good example formats to go by, those first few programs will be much easier. It's like driving a car. It is unlikely that any driver can recite from memory all road signs used to direct traffic. However, when a driver sees a road sign, it is quite likely he will recognize its meaning. In the same way, it is unlikely that even an experienced CNC programmer can recite every word used with CNC programming. But when even a relative newcomer to CNC sees a command, it is likely its meaning will be remembered. One of our intentions with program formatting is to keep you from having to memorize all commands needed for programming. Instead, you will be looking at an example and simply recollecting the function of each command. A second reason for strict program formatting is consistency. Once you have a format that works, use it. If you use the same format (or structure) for all programs you write, you will be able to repeat past successes. If all programmers in your company use the same format for a given CNC machine, each programmer will be easily able to work on another's program. The third (and most important) reason for strictly formatting programs is related to multiple tool jobs. Almost all CNC machining center and turning center programs require more than one tool in the program. For this kind of program, there will be many times when it will be necessary to rerun only one tool in the program a second, third, or fourth time. Say, for example, you have a machining center program that uses ten tools. After running a workpiece, you determine that the fifth tool in the program did not go quite deep enough. After fixing the problem (changing tool offset or Z position in the program), you will need to run the fifth tool again. However, you would not want to run the entire program just to get to tool number five. Doing so would be a waste of time and may actually cause unwanted problems with workpiece ac-curacy and finish. Instead, you will want to be able to run only tool five a second time. To do so will require that all information necessary to get the machine running (just like at the beginning of the program) is included at the beginning of tool five. If the programmer makes certain assumptions related to modal information from a previous tool, it may not be possible to run tool number five by itself (without editing the program). Here is an example of a time when the programmer must include some redundant information at the beginning of a tool in order to provide the operator the ability to rerun the tool. As in our previous ten-tool example, we still wish to run tool number five a second time. Say that tools four and five both happen to run at 500 rpm. Say the last tool in the program (tool number ten) runs at 1500 rpm. Spindle speed is modal. While writing the program, say the programmer decides to leave out the S500 word at the beginning of tool five, expecting it to carry over from tool four. Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
If the program is run in the normal (sequential) manner, everything will work just fine. But when the operator attempts to rerun tool number five it will start at the same spindle speed as the last tool in the program (1500 rpm), not 500 rpm! To alleviate this problem, the programmer must include all information necessary to begin the tool, even if it means including some redundant information. In essence, the programmer must treat each tool as a miniprogram that can run separate from the rest of the program. When you think about it, this actually simplifies the programming task, allowing the programmer to break a seemingly complicated multitool program into smaller and easier-to-handle pieces.
How Do You Come Up With Program Format Information For Your Machine?
The best way is to take an example program that is currently running successfully and break it up in the manner shown above. When doing this, analyze just what each tool is doing to determine the various types of format. Ensure that each tool contains all information needed to run independently. If you are working from scratch with a new CNC machine and have no examples to go by, contact your machine tool builder to gain an understanding of how your programs should be formatted. You may also find examples given within your machine tool builder's programming manual.
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
Presented here are three methods of developing CNC programs, manual programming, conversational (shop-floor) programming, and CAM system programming. Mike Lynch President, CNC Concepts, Inc.
To this point, we have exclusively stressed manual programming techniques at G-code level in order to ensure your understanding of basic CNC features. In this key concept, however, we will explore the various methods of creating CNC programs. We will give applications for each method to determine which is best for a given company. While we do tend to get a little opinionated in this section, you should at least understand the basic criteria for deciding among the programming alternatives. We will discuss three methods of developing CNC programs, manual programming, conversational (shop-floor) programming, and CAM system programming. Keep in mind that no one of these alternatives is right for all companies. Each has its niche in the manufacturing industry.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Manual Programming
As you have seen, manual programming tends to be somewhat tedious. Admittedly, the words and commands involved with manual programming can be somewhat cryptic. However, all CNC programmers should have a good understanding of manual programming techniques regardless of whether or not they are used. We relate this to performing arithmetic calculations longhand as opposed to on an electronic calculator. Math teachers unanimously agree that students must understand how to perform arithmetic calculations manually. Once the student possesses a firm understanding of how to perform calculations manually, a calculator can be used to expedite the calculation procedure. For the right application, manual programming may be the best programming alternative. There are still a great number of companies who exclusively employ manual programming techniques. If, for example, only a few machine tools are used, and if the work performed by the company is relatively simple, a good manual programmer will probably be able to outperform even a very good CAM system programmer. Or say a company dedicates the use of their CNC equipment to a limited number of jobs. Once these jobs are programmed, there will never be a need to create more programs. This is another time when manual programming may make the best programming alternative.
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone
Even if a CAM system is used, there will be times when the CNC program (at G-code level) must be changed to correct mistakes during the verification of the program. Also, there will usually be an opportunity to optimize programs after running of the first few workpieces. If the programmer must use the CAM system to perform these very elementary changes to the CNC program, a great deal of production time can be wasted.
Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
Conversational controls vary substantially from one manufacturer to the next. In most cases, they can essentially be thought of as a single-purpose CAM system, and thus do provide a convenient means to generate part programs for a single machine. Be forewarned, though, that some of these controls, particularly older models, can only be programmed conversationally at the machine, which means you can't utilize other means such as offline programming with a CAM system. However, most newer models can operate either in a conversational mode or accept externally generated G-code programs.
General Information
Information required of the programmer in this step includes documentation information like part name, part number, date, and program file name. The programmer may also be required to set up the graphic display size for scaling purposes. The workpiece material and rough stock shape may also be
required.
All current model CNC controls come with an RS-232-C communications (serial) port. All current model personal computers come with a serial communications port. By connecting a properly configured cable to the computer and CNC , the user can command that transmissions of CNC programs take place. Some form of communications software is required within the computer to allow transmissions. After invoking this software, the user can specify whether a CNC program is to be sent or received to or from the CNC. Note that most CAM systems come with this form of communications software to allow program transfer. Moreover, there are a number of vendors who specialize in these communications networksusually referred to as "DNC systems." Once transferred to the computer, the communications software will automatically store the program on the computer's hard drive (or floppy diskette). Once the program is transferred to the CNC, the program will be ready for activation within the control itself.
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
This perspective for a good programmer is a practical one, since the CNC operator must understand the machine's basic components, its directions of motion, and all buttons and switches available on the machine tool itself. Mike Lynch President, CNC Concepts, Inc.
To this point, we have been discussing CNC from a programmer's viewpoint. We are now going to switch the emphasis to looking at CNC from an operator's viewpoint. Our first operation-related key concept parallels key concept number one, understanding the machine tool itself. However, a CNC operator must be much more intimate with the CNC machine tool than the CNC programmer. He or she must, of course, understand the machine's basic components, its directions of motion, and all buttons and switches available on the machine tool itself. Keep in mind that this presentation is intended to simply acquaint you with common machine functions. You must reference your machine tool builder's manual for more specific information related to the buttons and switches on your machine. Just what the operator of a CNC machine will be expected to do will vary from company to company. While there are exceptions to this general statement, larger manufacturing companies tend to segment the responsibilities related to their manufacturing. One person will set up tooling. Another will make the workholding setup on the CNC machine tool. Yet another will verify the program. Once the program is deemed correct and safe, it is turned over to the CNC operator who runs the workpieces to be produced. In this case, the opera-tor's responsibility may be limited to simply loading and checking workpieces and making the necessary offset changes to keep workpieces on size. Smaller companies cannot afford the luxury of having so many people involved with any one job and thus tend to expect more of each person. These companies may expect the operator of a CNC machine to do all functions related to the machining of a workpiece including writing the program, setting up the tooling, making the work-holding setup, verifying the program, and running the production. The more the operator is expected to do, the better their knowledge level should be. In any event, knowing more than may be required can never hurt. The more the operator knows, the better the CNC environment. The Two Most Basic Operation Panels Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
Do not let the control panel intimidate you. As we go on, you will find that the CNC machine's buttons and switches are quite logical and aptly named. While it may take some memorizing, once you are exposed to a CNC machine on a regular basis, we think you will agree that operation is not difficult to master. There are two distinctly different operator panels for most CNC machine tools. The control panel is designed and built by the control manufacturer, and the machine panel is designed and built by the machine tool builder.
While there are some exceptions, the control panel is primarily used to manipulate data through the display screen and can be thought of as the keyboard of a personal computer. The machine panel is used to make physical adjustments as to how the machine tool behaves. The control panel can be used to enter programs into memory. While there are faster ways to do this through the communications port, many CNC users enter their programs in this manner. Once entered, the control panel can be used to edit or modify a program stored in the control's memory. The display screen will constantly show the program being entered or modified, much the same as the display screen of a personal computer when using a word processor. Tool offsets are also entered and modified by using the control panel. Once the operator selects the offset mode, the display screen will show the table of offsets, all of which can then be adjusted. Yet another use of the control panel is to access all functions of the display screen. Axis position, control diagnostics and parameters, and other data are manipulated in this manner. By comparison, buttons and switches on the machine panel are used to activate machine functions. For example, the machine panel is used to manually jog the axes of the machine. Some form of joystick or combination of push buttons can be used to make the desired axis motion. Almost all CNC machine tools even have a handwheel on the machine panel that can be used in much the same way as the handwheels on manually operated machine tools. For most machines, the machine panel can be used to manually turn the spindle on and off. Some machines even have a rheostat that allows the operator to manipulate the speed of the spindle. The machine panel also includes many conditional switches that control how the machine behaves during automatic operation. Features like single block, dry run, and optional stop are among those controlled by these conditional switches (more on these features a little later). Buttons And Switches Found On The Control Panel As mentioned, many of the same keys found on a typical personal computer are also found on the CNC machine's control panel. Following are the most important functions along with a brief description of their use.
G
Power Buttons. To avoid surges, most CNC machines have at least two different power buttons, one for power to the control and another for power to the machine tool itself. The control panel power button must be pressed first, and activates the control screen and control panel. Once the control is on, then the machine power can be turned on. Machine power is usually labelled as hydraulic on or machine ready. Display Screen Control Keys. You can think of these keys as like the channel selector on a television set. They allow the operator to select which function of the display screen he or she wants to view. Position Button. This selector button allows the operator to look at the machine's position display. In this mode, the display screen shows pertinent information about where the machine is currently positioned. Program Button. This display screen selector button allows the operator to monitor the active program in the control's memory. This key is pressed when editing CNC programs and when monitoring programs in automatic operation. Offset Button. This display screen selector button allows the user to display and manipulate the tool offsets. Along with the cursor control buttons, the operator can use this button to find and change offsets in memory. Letter Keys. This keypad allows alphabetical character entry. Some CNC control panels allow only those alpha keys (N, G, X, and so on) needed for CNC programming on the keyboard. On others, the full character set (A through Z) is available. Knowing a CNC's buttons and Number Keys. These keys allow numeric entry. Normally located close to the letter keypad, most CNC switches unlocks the mystery of controls have number keys positioned in much the same way as on the keypad of an electronic its operation. Photo courtesy of calculator. Cincinnati Milacron. The Input Key. This key is pressed to actually enter data. Examples of when this key is pressed include entering offsets and setting parameters. Cursor Control Keys. The display screen of the CNC control will often show a prompt cursor that indicates the current entry position. The prompt cursor usually appears as a blinking square or underlined character. It is at the current position of the cursor that data will be entered. Cursor control keys (usually in the form of arrows) allow the operator to position the cursor to the desired location on the display screen. Program Editing Keys. There are many times when a program stored in the control's memory must be altered. The most common example is during the verification of a new program. These keys allow program entry and modification. Reset Button. On most controls, this button usually serves three basic functions. First, while editing CNC programs, this key will return the cursor to the beginning of the program. Second, this key will clear the look-ahead buffer and stop execution of the program. This is required when it is determined that there is something wrong in the program and you wish to stop. However, it can be dangerous to press this key during a program's execution in other cases. If the program is executed immediately after the reset key is pressed, the control will have forgotten the commands in the look-ahead buffer. In effect, this will cause several commands to be skipped. The control will pick up and continue running, but severe problems could arise due to the missing commands. When in automatic operation, be careful with this key. Third, when in alarm state, this key will cancel the alarm once the problem has been solved.
switch of a CNC machine must be positioned correctly before any function can be activated. For example, if the operator wishes to make a manual movement by jogging the machine with a handwheel, the mode switch must be positioned in a manual mode. If the mode switch is not in the correct position, usually the worst that can happen is that the machine will not respond to the operator's command. H Edit Mode. The edit mode allows an operator to enter and modify CNC programs through the keyboard and display screen in much the same way a word processor is used on a personal computer. The edit mode is also used to scan within the active program to a position at which the cycle is to be started. For example, the operator may wish to skip to the beginning of the third tool and execute the program from that point. The edit mode is used to get there. H Memory or Auto. This is one the modes from which a program can be executed. The operator is allowed to begin the automatic cycle, executing the active program from within the control's memory. H Tape Mode. This mode is similar to Auto or Memory, except the program is executed from a tape on the tape reader, not from within the control's memory. It only applies, of course, to machines so equipped. H Manual Data Input Mode. This mode switch position allows the operator to enter program commands through the keyboard. Machine tool builders do their best to place sufficient buttons and switches on the machine to allow easy operation. However, given the almost limitless possibilities with a CNC machine, it is next to impossible to give a button or switch for every machine function. For this reason, control manufacturers provide a way for the operator to make CNC commands manually, in the Manual Data Input mode. H Manual or Jog Mode. In this mode, the CNC machine behaves like a man-ual machine tool. This mode activates many of the machine panel's buttons and switches related to machine functions. For example, almost all CNC machines incorporate a handwheel for manually moving each axis. Most CNC machines also have a jog function, allowing axis motion to be caused by a joystick or push button. Most have a button to turn the spindle on and off, as well as a rheostat to control spindle speed. All of these functions are activated manually, through the Manual or Jog mode. Cycle Button. This button is used to activate the program currently in the control memory, causing the machine to go into automatic cycle. Feed Hold. This button allows the operator to halt axis motion temporarily. The cycle start button can be used to reactivate the cycle. Note that all other functions of the machine (coolant, spindle, etc.) will continue to operate. Think of this button as your first panic button. If you are verifying a program, you should always have a finger on this button. If you suspect any mishap, press feed hold, then check for mistakes. If a problem is found, you will take the program out of cycle (by pressing the reset key), fix the problem, and start over. If a mistake is not found and you wish to continue, you can do so by pressing cycle start. G Feed Rate Override. This multiple position switch allows the operator to change the programmed feed rate during cutting commands (G01, G02, G03, etc.). Notice we said feed rate. Under normal conditions, this switch has no control over rapid motion. The feed rate override switch is usually segmented in 10 percent increments that range from 0 percent through 200 percent. This means the operator can slow down programmed feed rates to nothing, stopping motion in feed rate movements, and increase the feed rate to double the programmed value. G Rapid Traverse Override. This switch is used to slow the rapid motion rate. It can come in two different forms. In one form, it is a simple on/off switch. When on, all rapid motion is slowed to 25 percent of the normal rapid rate. In its second and more useful form, rapid override is a four position switch and can be adjusted to 5 percent, 25 percent, 50 percent, and 100 percent of the normal rapid rate. It makes sense to use rapid override during program verification to assure that rapid movements toward the workpiece are correct. G Emergency Stop. This button will turn power off to the machine tool. Usually, power to the control remains. G Conditional Switches. These on/off switches control how the machine behaves during automatic and manual operation. They can be toggle switches, locking push buttons, or even set through the display screen and keyboard. Though the location and style of these switches vary, their meaning and usage stays amazingly similar from one type of CNC machine to the next. These switches are very important. If one or another is improperly set, the machine may not perform as expected. The operator should get in the habit of checking each of these switches before the CNC program is executed.
G G G
Dry Run. This conditional switch is most used with the verification of new programs. When this switch is on, it gives the operator control of the motion rate at which the machine will traverse. This is extremely helpful during rapid motions. The rapid rate of current CNC machines is very fast, ranging from 100 inches per minute to 800 inches per minute or more. At these extremely fast rates, the operator will not be able to stop the machine in time in case of a mishap. Single Block. This conditional switch can be used to force the control to execute one command of the program at a time. When turned on, the control will stop at the completion of each command. To execute the next command, the operator must push the cycle start button. This switch is most helpful during program verification. With a new program, the operator will cautiously check each motion the machine makes, one at a time. Machine Lock. This conditional switch keeps all axes of the machine from moving. Many other functions of the machine will continue to operate. For example, the turret will still index, the spindle will still run, coolant will still come on, etc. But axis motion will not occur. Machine lock can be used during automatic operation and manual operation. If a motion of any kind is commanded, the position displays on the display screen will act as if the machine is moving, but in reality, no motion occurs. Optional Block Skip (Also Called Block Delete). This conditional switch works in conjunction with slash codes (/) in the program. If the control reads a slash code at the beginning of any CNC command in the program, it will look to the position of the optional block skip switch. If the switch is on, the control will ignore the command in which the slash code is included. If the optional block skip switch is off, the control will execute the command. Optional Stop. This conditional switch works in conjunction with an M01 code in the program. When the control reads an M01 and the optional stop switch is on, the control will halt the execution of the program. The operator must press the cycle start button to reactivate the program. If the optional stop switch is off, the control will ignore the M01 and continue executing the program.
Manual Controls
The machine panel for all CNC machining centers will also include several buttons and switches related to manual control of the machine tool's functions. These buttons and switches vary dramatically from one builder to the next. Common manual functions include spindle control, coolant control, manual tool change control, and control of axis movements.
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
This concept introduces the three basic modes of operation, presents examples of when they are used, explores more about the mode switch, and categorizes each position of the mode switch into one of the three basic modes. Mike Lynch President, CNC Concepts, Inc.
During key concept number seven, we discussed the mode switch found on the machine panel. We said this switch was the heart of the CNC machine and that the operator must first look at this switch before any function can be performed. The most common mistake on the operator's part is having the mode switch in the wrong position. Also during key concept number seven, you found that the mode switch has several positions. However, during this key concept, you will find that there are really only three basic modes of operation. Here we will introduce the three modes and give examples of when they are used. We will also discuss more about the mode switch, categorizing each position of the mode switch into one of the three basic modes.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Manual Mode
In the manual mode, the CNC machine behaves like a standard or conventional machine. A CNC machining center behaves like a manual milling machine. A CNC turning center behaves like an engine lathe. The physical positions of the mode switch that are included as manual modes include manual or jog, handwheel, and reference return. With the manual mode, the operator of a CNC machine is allowed to press buttons, turn handwheels, and activate switches in order to attain the desired machine function. The activation of each button or switch in the manual mode has an immediate response. For example, if the correct mode switch position is selected and if the correct button is pressed, the spindle will start. If a switch is turned on, the coolant will come on. If a joystick is held in one direction or another, the corresponding machine axis will move. Note that those things that cannot be done in the manual mode must be done in the manual data input mode, the second mode of operation.
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
With the edit position of the mode switch, a program is entered or modified. With the MDI position of the mode switch CNC commands are entered and executed. Second, both provide manual capabilities that can also be done in a more automatic way. In edit mode, an operator can enter CNC programs into the control memory. This can also be accomplished by loading the program from some outside device, such as a computer or tape reader. In MDI mode, CNC commands are entered through the keyboard and display screen manually and can be executed once. If the command must be executed a second
time, the operator must enter the MDI command a second time. However, if the same command is included in a program, it can be executed automatically, over and over without having to be re-typed.
Edit Mode
If you have ever worked with a word processor, you will find the use of the edit mode of a CNC control familiar and easy to work with. In this mode, the operator is allowed to do two basic things. He can enter CNC programs into the control memory and modify current programs. Almost all CNC controls allow the operator to store multiple programs. Programs are typically organized by program number (commonly the O word). The operator will be allowed to call up the desired program from within the control's memory, making it the active program. All true CNC controls give the user the ability to do at least three basic things in the edit mode. The operator can insert new information into the program, alter the current information in the program, and delete information from the program. Some CNC controls also allow the operator to do global editing, meaning they can cut and paste, and find and replace data. Along with these basic features, the operator will be allowed to search or scan the program for key information. For example, the control can quickly search to the next occurrence of any programming word. If the programmer used sequence numbers (N words) the operator could use the sequence number of an incorrect command as the word used to search.
Tape Mode
At one time, the tape mode was the only way to activate programs. But with the advent of the computer, the need for the tape mode switch has decreased. In fact, many CNC controls do not even come with the ability to run programs from the tape reader. While they may equip the control with a tape reader, its sole purpose is to load programs into the control's memory. For those CNC controls that still allow programs to be executed from the tape mode, there are only two occasions when this is helpful. Both involve programs that are too long to fit into the control's memory. First, a program can be run directly from the tape reader (if the control allows this function). However, the tape reader also has a limitation in the length of program it can run. For those extremely long programs, some CNC controls allow programs to be run from an outside device like a personal computer. With this technique,
the control is fooled into thinking it is running a program from the tape reader, but in reality it is running a program being transmitted through the control's communications port. To accomplish this, the mode switch position is set to the tape mode while the program is executed. But the control's parameters are set in a way that tell the control to run from the communications port. The main application for this technique is for three dimensional sculpturing CNC programs generated from a CAM system. With these programs, very tiny motions are generated to machine elaborate contoured shapes. Direct numerical control (DNC) is the term used to describe this technique of running programs from an external computer. Keep in mind that this is an extremely necessary feature for certain applications, like machining dies and molds. The tape position of the mode switch has two severe limitations. First, the operator will only be allowed to see one or two commands of the program at a time on the display screen. In memory mode, the operator will be allowed to monitor a whole page of the program. This is most helpful during the program's verification, when the operator wishes to check the commands coming up. The second limitation of the tape mode is that modification of the program is not possible from within the CNC control. This means the program must be perfect before it can be run. If changes must be made, they must be made away from the CNC control. When programs are stored in the control's memory, it is easy to make changes right at the control.
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
Feature Article
This concept examines the sequences of operation of a CNC machine by way of reference material related to key operational procedures. Mike Lynch President, CNC Concepts, Inc.
Experienced operators would agree that running any CNC machine tool is little more than following a series of basic procedures. From powering the machine up in the morning to turning it off at night, the operator will be following these sequences in a step-by-step manner. From the beginning operator's standpoint, half the battle of learning how to operate a CNC machine is simply knowing when each procedure is required. Then, it will be a simple matter to follow the basic sequence to attain the machine's desired function. For example, if an operator wishes to load a program into the control memory, there are a series of switches and buttons that must be activated in the proper order. If the operator wishes to change an offset, a specific procedure must be followed. While the actual buttons and switches will vary depending on the control model, once the operator has documented the most important sequences, it is relatively easy to make the machine function in the desired manner. Too many companies that utilize CNC expect their operators to memorize all key procedures needed to run the machine. We strongly recommend that the CNC user develop an operation handbook in order to help operators become comfortable with each CNC machine tool (one per machine). This will give the operator the step-by-step procedures needed for critical machine operations.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Key Concept #9
Key Sequences Of Operation
Visit MMS' Machining Centers Zone Visit MMS' CNC & DNC Zone Visit MMS' CAD/CAM Software Zone Link a Friend to This Page Via E-mail Print this article
Manual Sequences
G G G G G G
To To To To To To
start machine do a manual reference return manually start spindle manually jog axes use the handwheel to cause axis motion manually load tools into spindle
G G G G G G
To To To To To To
manually load tools into magazine manually turn on coolant make axis displays read zero or any number enter tool offsets (length and radius) manually turn on mirror image manually select inch or metric mode.
To To To To
to to to to
To To To To
load programs into memory by tape load programs into memory by RS-232 port load programs into memory through keyboard punch programs from memory to tape punch or computer.
To To To To To To To
display a directory of the programs in memory delete a whole program from memory search other programs in memory search to words inside a program alter words in memory delete words and commands in memory insert words and commands in memory.
Setup Sequences
G G
To verify programs To run verified programs in production To run from the beginning of any tool.
MMS MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.
| Home | Article Archive | Latest Issue | Talk To Us | Previous Page (or Use Back Button) | | Online Tools & Calculators | Subscribe To MMS' OTW Infoletter |
For the most part, CNC controls will follow the instructions given in a program to the letter. With the exception of basic syntax (program formatting) mistakes, the CNC control will rarely be able to tell if a mistake has been made. While verifying any new program, the operator must be ready for anything. If, for example, the programmer made a mistake which tells the control to drive a tool at rapid into the workpiece, the control will follow the commands causing what is commonly referred to as a crash. With a manually prepared program, just about anything could be wrong. The manual programmer might have meant to type X but instead typed Z. In this case, the resulting motion the machine makes will be totally unexpected. Literally every command in a manually prepared program may have a mistake and should be treated as suspect. If a computer-aided manufacturing (CAM) system was used to prepare the CNC program, the basic syntax of the program will usually be correct. The basic motion commands the control is given should also be correct. However, even CAM generated programs will not be perfect. While they tend to be more correct than manually generated programs, problems could still exist with feeds, speeds, workholding, depth of cut, and so on. Conversationally generated CNC programs should be treated with the same respect as CAM generated programs. Keep in mind that even perfect programs will behave poorly if mistakes are made during setup such as with tool length measurements or the program zero measurement. We cannot overstress the need for safe procedures when working with CNC equipment. While we are not trying to scare the beginner, we want to instill a high level of respect for this very powerful and potentially dangerous equipment.
CNC Intro
Back To The CNC Key Concepts Introduction Page
Key Concept #1
The Fundamentals Of CNC
Key Concept #2
Know Your Machine
Key Concept #3
CNC Motion Types
Key Concept #4
Forms Of Compensation
Key Concept #5
Program Formatting
Key Concept #6
Methods For CNC Programming
Key Concept #7
Know The Machine
Key Concept #8
Modes Of Machine Operation
Safety Priorities
There are three levels of priority that you should always adhere to when working with any machine tool.
Key Concept #9
Key Sequences Of Operation
Operator Safety. Every step should be taken to ensure the safety of the person operating the CNC machine. As we give the actual procedures to verifying CNC Visit MMS' CNC & DNC Zone programs a little later, you will see that each procedure stresses operator safety. As the beginner gains experience, the tendency will be to short cut these procedures in Visit MMS' CAD/CAM Software Zone order to save some time. But if the recommended verification procedures are not followed, the operator is opening the door to a very dangerous situation. Link a Friend to This Page Via E-mail Machine Tool Safety. The second level of safety priority is the CNC machining center itself. Each operator must do his best to ensure that no damage to the machine can occur. CNC machine operation time is very expensive. When a CNC machine goes Print this article down for any reason, the actual cost of repairing the machine is usually very little compared to the lost production time. There is no excuse for a crash on the CNC machine due to operator or programmer mistakes. If the verification procedures we give are followed, you'll run much less risk of placing the machine in dangerous situations. Workpiece Safety. The third priority to CNC machine safety is making all workpieces to size. The cost of rough stock to be machined varies dramatically based on the user's application. In some cases, for very small parts being machined from completely rough stock, the cost of the material coming to the CNC machine may be as little as ten cents per part. In this case, the company may be willing to sacrifice several workpieces in order to verify the program. However, there are also times when the cost of the rough material coming to the CNC machine is very high. Possibly the material itself is very expensive, and/or previous operations might have been performed on the workpiece prior to the CNC machine operation. The user may have several hundred dollars (or more) invested in each workpiece prior to the CNC machine operation. In this case, the company cannot afford to lose even one workpiece during the program's verification. It is never necessary to scrap the first
workpiece on any CNC machine. If the verification procedures we give are followed, the workpiece will come out with excess stock after each cut. Following the given techniques will allow the operator to sneak up on all critical dimensions being machined.
Typical Mistakes
Before discussing the actual techniques to verify programs, let's first examine the kinds of mistakes the programmer tends to make that will cause a program to fail. Knowing these common mistakes will help you diagnose problems as they occur. Syntax Mistakes. A control will not even be able to execute the command with a syntax mistake. For example, the programmer may have meant to type a G code as G01, but by mistake typed G101. Most CNC controls do not even have a G101 command. With this kind of mistake, the control will go into alarm state the moment the erroneous command is read. If the machine is moving through its motions, the motions will stop and the program will halt. The display screen generally will show a message related to the cause of the problem. Syntax mistakes are usually silly mistakes the manual programmer makes while writing or typing the program. They are easy to diagnose because it is likely that as soon as the programmer sees the command generating the alarm, the mistake will be very obvious. Motion Mistakes. This kind of mistake can be a little more difficult to diagnose. While motion mistakes may still be silly mistakes on the programmer's part (transposing numbers or axis letter addresses for example), generally they are caused by incorrect coordinate calculations. For example, maybe the programmer misinterpreted the dimensions on a drawing and came up with incorrect coordinate values for the tool to move through. In this case, the control would follow the program's instructions without generating an alarm. But the tool path would not be correct. Other mistakes in this category include forgetting to instate or cancel tool offsets, reversing clockwise and counter clockwise commands, and improper mode selection for incremental versus absolute. This kind of mistake can be very serious if not found prior to machining. In many cases, it means the program is telling the control to, at best, not machine properly, or at worst, crash the tool into the workpiece, workholding device, or machine. Set-up Mistakes. Even a perfectly written CNC program will behave poorly if mistakes are made during setup. In most cases, the operator will have some measurements to make related to the setup and numbers to enter into the control before the program can be executed. For example, almost all CNC machining centers require that program zero be measured at the machine. Once this measurement is made, either the program must be modified, or the program zero values must be entered into fixture offsets (depending on how program zero is assigned). If these numbers are incorrectly measured or if mistakes are made during their entry, the control will not truly know where the program zero point is. All motions the program commands will be incorrect. In similar manner, tool lengths and diameters (for milling cutters) must be measured and entered correctly. If mistakes are made in this regard, the control will not truly know the length or diameter (radius) of each tool. Mistakes Of Omission. Most beginning manual programmers have the tendency to leave things out of the program. They forget to program a decimal point or they forget to turn on the coolant. They forget to program the feed rate. And so on. Knowing that you are prone to these mistakes of omission should help as you begin verifying programs.
operator must be very careful indeed. At this time, the workholding setup has been made, but no workpiece is in position. To execute this procedure, the operator will turn off the machine lock switch, turn down the dry run motion rate switch (typically jog feed rate) to its lowest position, and set the rapid override switch to its slowest motion rate. When the cycle is activated, the operator must have a finger ready to press the feed hold button. With the jog feed rate switch set to its lowest position, the axes will barely creep along. As the operator increases the setting on this switch, the axes will move faster. The operator will increase the motion rate to a comfortable setting. As each tool comes close to the workpiece or workholding device, the dry run motion rate can be turned down. If the operator is worried and wants to check something, the feed hold button can be pressed to temporarily stop the cycle. After pausing, pressing the cycle start button gets the machine moving again. If the operator wishes to cancel the cycle due to a motion mistake in the program, after pressing feed hold, the reset key can be pressed, the machine can be sent back to its reference point, and the problem can be corrected. Aside from severe problems, the operator must also check for less serious problems. For example, the operator must check that the spindle is rotating in the correct direction for each tool and that basic motions the program generates appear to be correct. In many cases, the operator will not be quite sure the program is correct after doing only one free flowing dry run. The first time the program is executed in this way, the operator may be so concerned with serious mistakes that could cause damage to the machine, they pay little attention to the details of each movement. For this reason, many times the free flowing dry run must be repeated several times until the operator is satisfied that the motions are correct. It is possible that the free flowing dry run will cause the machine to go into alarm state even though a machine lock dry run has been completed. Axis overtravels and problems related to offsets and other forms of compensation are among the things that can generate alarms in such a case.
the operator gets worried. He or she is concerned that the tool may not stop before it hits the workpiece, so feed hold is pressed to stop motion. At this point, the operator can check the distance to go. This distance can be compared to the tool's actual position relative to the workpiece.
Conclusion
While the verification procedures we have given may seem like a great deal of work, we urge the beginner to use them. While it does take time it can easily be justified when compared to the possible consequences. Without verification procedures, CNC machining centers are very dangerous to operate. Even if no operator injury occurs during a crash, the time and expense during machine repair easily justifies being cautious while new programs are checked out. It is common that a beginning operator is very cautious with the unfamiliar CNC machine. But after gaining experience, the operator becomes a little over confident. Then the operator starts short cutting the verification procedures. This is where problems begin. We liken this to a person learning how to snow ski. At first, the beginning skier is very concerned about hurting himself. No tricks or hot dogging are attempted. But after gaining confidence, the skier may attempt to do more than they are capable of. This is how legs get broken. The same can be said for the beginning CNC operator. As you gain confidence, you may be tempted to forego a procedure you would have done as a beginner. Watch out!
MMS Online is a trademark of Gardner Publications, Inc, copyright 1997-2006. MMS Online and all contents are properties of Gardner Publications, Inc. All Rights Reserved.