To subscribe: Simply email us (firstname.lastname@example.org) and let us know you'd like to be added to our distribution list.
To unsubscribe: Respond to this email, typing REMOVE in the subject. Please accept our apologies if we have disturbed you.
Product Corner: Two new software products
We're proud to announce that we have two new software offerings to help CNC-users:
NCPlot - tool path plotting and much more!
Don't think of NCPlot as just a tool path plotter. This outstanding program provides all the resources you need to develop and verify G code programs from scratch. You can even verify custom macro B programs!
NCPlot's well designed display screen is made up of two main viewing areas, the Text Editor (on the left) and the Plotting Viewport (on the right). You can manipulate the size of each viewing area at any time with a vertical sliding bar. So if you're typing in a program, move the sliding bar to the right to expose more of the Text Editor. If you're verifying a program, move the sliding bar to the left to expose more of the Plotting Viewport. Program menus located at the top of the screen provide access to all program functions and toolbar icons provide instant access to the most commonly used functions.
The Plotting Viewport is interactive with the Text Editor. After you make an addition or change in the Text Editor, you simply click one button (Refresh Plot) to see what your change has done in the Plotting Viewport. What a great way to check your work as you create a program!
NCPlot also allows you to plot custom macro B programs. But not only can you plot them, NCPlot provides a feature that allows you to convert custom macro executions into G code programs. This is a very handy feature, especially if you have some machines that don't have custom macro B.
The feature DXF to G code allows you to convert DXF drawings into G code tool path. So if you have an electronic drawing of the contour you need to machine, creating the tool path in G code is just a few clicks away.
In similar fashion, the feature Text to G code allows you to convert any text you type into G code.
Price: $299.00 (special student pricing available)
You've got to learn more about this amazing program!
Machinist ToolBox - Answers to your machining questions are just a few clicks away!
Need to solve a right triangle? An oblique triangle? How about determining the appropriate height of gage blocks for a sine bar? Need a speed or feedrate for that material you've never machined before? These are but a few ways that Machinist ToolBox can help you. It's loaded with conversion methods, machining data, reference information, and G code generating functions to help you with your machining questions.
Main menus include:
Instructor note: Now is the time to train!
Improving the proficiency of your personnel will outperform any other single improvement you can make in your CNC environment. Do you want less scrap? Well-trained CNC operators don't make mistakes that scrap parts. Do you want more efficient setups? Well-trained setup people don't waste time trying to figure out how setups are supposed to be made. Do you want your CNC programs to run faster? Well-trained programmers take full advantage of the latest in time-saving technology. And in general, do you want higher profits? Well-trained people will dramatically outperform poorly trained people.
While everyone will freely agree with the statements just made, it's amazing how many excuses are given for not involving people to training courses. Two common excuses are related to how well the company is currently doing. If times are slow, "we can't afford the cost of the training program". If times are good, "every person is too busy for us to let anyone take time out for a course". The reality of the matter is that it's always the right time to train. When times are slow, it's the perfect time to train people because there is ample time - and they'll perform better when times pick up. When times are good, it's also the perfect time to train people because you can now easily afford the cost.
When it comes right down to it, it's simply a matter of choice. Either you choose to help your people to improve or you choose not to help them improve. Given the benefits that can be reaped by improving proficiency, this should be a very easy choice indeed.
I've heard more than one manager say "If I train my people, they may leave the company for better paying jobs." Well, if you don't train your people, there is still no guarantee that they'll stay with you - and how much can a poorly trained workforce really help your company? If your company is not competitive with its wages and benefits, you're going to have problems attracting and keeping the best people regardless of how much training you provide.
You're company has committed large resources to be in business. Just consider the total value of your company. Include land, buildings, machine tools, computers, personnel costs, and all other company assets. Now consider the amount per year you spend to ensure that your people - the very people who control your company's destiny - fully understand their responsibilities. And I'm not talking about just making do. I'm talking about having people that are fully versed with the tasks that they are assigned to do, and can perform them in as efficient a manner as possible. If you expect to stay in business, you can't afford not to maintain and improve the proficiency of your workers.
G code primer: Running a special series of commands in a program
There may be times when you need to have the machine execute a series of commands that are related to your program, but not necessarily part of the program. Consider, for example, a series of commands that are only needed during setup. One such series of commands is related to boring jaws on a CNC turning center.
You may have developed a special set of jaw boring commands in order to help the setup person bore jaws. These commands need only be executed once - during the setup. Yet you may not want to have two separate programs - one to bore jaws and another to machine the part. Doing so might cause confusion and the setup person would have to load two separate programs.
You can keep the jaw boring commands in with the machining program with this technique: Place the commands at the end of the program and after the program ending word (M30 or M02). During normal program execution (during the production run), the control will execute the end of program word and rewind the memory without seeing or executing the special series of commands.
Begin the special series of commands with a rememberable sequence number. I like N999. Include the commands you need followed by another end of program word (again, M30 or M02, whichever you use to end programs).
Here is an example. In this example, we're using the technique to enter some fixture offsets.
When the setup person wants to run the special sequence (in this case to set the fixture offsets), they will - in the EDIT mode - scan to N999. They'll execute the program from this point (in the AUTO or MEMORY mode). The machine will set all the fixture offsets and then, when it sees the second M30, will rewind to the beginning of the program and stop. It won't see the N999 sequence again unless the setup person scans to it in EDIT mode.
Again, this technique is very helpful whenever you want to have the machine execute a series of commands that is related to your program, but not actually part of it.
Do note that you may have a problem with program loading. Most machines are set to stop loading programs when an M02, M30, or M99 is read. In this case, the machine will stop reading the program before the N999 sequence can be loaded. A parameter controls when the machine will stop loading programs - at M02/M30/M99 or when an end of file terminator (the percent sign - %) is read. If you intend to use this technique, the parameter must be set, of course, to the latter. See the Parameter Preference article in this issue of The Optional Stop to learn how to change this parameter.
Macro maven: Special calculation programs
As you know, with custom macro B you have a computer programming language built right into your CNC control. And along with many CNC related features, custom macro B gives you the ability to do some pretty amazing things. Almost all of the applications we've shown for custom macro have been CNC-intensive. That is, custom macro commands are usually included in CNC programs that actually machine workpieces.
But what about using custom macro B for more computer-programming-like applications? Applications that may not be related (at least not directly) to CNC programs that machine workpieces. While I freely admit that you won't be able to bring the pizzazz of Virtual Basic to your CNC control, you may be surprised at how may good and workable applications you can come up with.
Start by studying your setup people and operators - and watch for times they use a calculator. With simple operations like addition and subtraction, and especially when the formulae they are applying are simple, maybe a custom macro won't help much. But when you spot a more complicated calculation - and when people don't know the related formulae - you have found a great application for custom macro B.
Input and output
Any computer program requires input from the user. It takes the input, does the programmed calculations, and provides answers (output). Most computers, of course will print the output - right on the screen or to a printer.
Unfortunately, custom macro be cannot "print" output in a very friendly manner. And of course, you don't have a printer connected to your CNC machine tool's control (though keep in mind that you can "print" to any serial device through the communications port with DPRNT commands). So we must find another way to provide the output to the setup person or operator. I recommend using the Stop With Message command that will place a short message on the screen that tells the setup person or operator where to look for the answer. And I recommend that you place the answers in common variables (#100 series variables). Consider, for example, this simple application that converts an inch value to a metric value:
Admittedly this application is pretty simple, but it nicely stresses how to specify input values and how to get output. To convert an inch value to a metric value, the user must specify the inch value (1.5 in our case). To do this, they must edit the third command in this program.
When a person runs this program, the metric equivalent will be placed in #100. I recommend using the same output location (#100) for every application so the user will always know where to look for the answer. The stop with message command (#3006 command) tells the user to look in #100 to find the answer.
Again this is a simple application. Even so, any time a person wants to convert from inch to metric, this program will keep them from having to look up the conversion factor (25.4).
When you think about it, you will probably come up with many times when you can apply this technique. But you won't want to create a separate program for every application. Doing so will be cumbersome - and the setup person or operator may spend as much time trying to find the appropriate program as they would looking up the needed formula.
I recommend keeping all of your calculation applications in one program, separating each application with a blank space and an M30. Consider this example:
Notice that the program begins with a kind of table-of-contents. Make it as easy as possible for the person to find the needed calculation. In our example, there are only three different calculations being done and this kind of documentation may not be necessary. But for longer programs, this can really help. With our technique, a person can easily scan to the sequence number (N word) that begins each calculation.
Each separate calculation begins with a blank line (semi-colon by itself) and a sequence number. Then the input command/s. Then the calculation, storing the answer in #100. Then a stop-with-message command to specify where the answer can be found. Finally an M30 ends each calculation routine.
What did you come up with?
As I said, you'll probably come up with countless applications for this technique - and I'll be very interested in what you've done. Please email me at email@example.com with your ideas. I'll publish them in a future issue of The Optional Stop newsletter so everyone can benefit from your ideas.
Safety first: The right way to activate a program in production
Setup people who get a machine ready to run production know that just about anything can happen the first time they execute a program. If certain control panel functions are not properly set, the machine will not behave as expected.
For example, if the dry run switch is on, rapid motions will (usually) be slowed while cutting motions will be accelerated. If the feedrate override switch is not set to 100%, machining will not occur as intended. And if an offset (tool length, cutter radius, fixture, or geometry) has not been correctly measured and entered, the results could be disastrous. These are but a few of the problems a setup person can have when running programs - new programs and even programs that have been run before.
Though setup people get pretty good at handling problems, CNC operators may not possess the same skills. In most cases, a CNC operator will only take over once a setup person has made the machine ready for production.
I offer two simple and somewhat obvious suggestions. Though they're obvious, I'm surprised at how many operators don't follow them. They're guaranteed to save a crash some day.
My first recommendation is to get everyone that runs a CNC machine in the habit of having a finger ready to press the feed hold button every time they press the cycle start button. Feed hold, of course, will immediately halt axis motion as soon as it is pressed - which is just what the doctor ordered if something is wrong. But of course, this button can only be pressed once it is located. If the machine is moving (at rapid) in the wrong direction, it is unlikely that anyone can find the feed hold button in time to stop the machine before a crash - unless they're ready to press it the instant the cycle is activated.
Unfortunately, running production on a CNC machine can be rather mundane - and boring. This is especially true with long running jobs that have been properly processed and programmed. Operators can be lulled into a false sense of security if they run hundreds (or thousands) of cycles without mishap.
So my second recommendation is to get everyone in the habit of watching the first tool's motion until it begins cutting. An operator won't know if something is wrong if they don't watch the machine! Extra care should be given after an off shift, a break, lunch, or any time the operator isn't running a cycle immediately after the previous one. A control panel button or switch could have been changed during this period without their knowing it.
Parameter preference: Specifying when to stop loading a programWhile this is a reprint from the Fall 2006 issue, it is appropriate for this issue since - in the Macro Maven article - we discuss a method for performing multiple calculations from within one program. This technique requires that you set the machine so that it will not stop loading a program when the control sees an M30.
In most cases, a setup person must load but one program at a time. This program contains all the information necessary to machine the workpiece they are setting up. There are times, however, when more than one program is related to a job. Consider, for example, the programmer that uses several subprograms in conjunction with a main program to minimize the program's overall length and simplify programming.
Most machine tool builders set up their machines so that when an M02, M30, or M99 is detected in a program being loaded, the machine will terminate the program loading process. And again, this is just fine if you are only loading one program. But if you must load several programs, the programs must be divided into separate files and the program loading procedure must be repeated for each program. This can be somewhat tedious.
A parameter controls when the machine will terminate the program loading process - and as stated - most machine tool builders set the parameter to make the machine stop reading at M02, M30, or M99. But you can modify this parameter so that it will continue loading programs until an end of file delimiter character is detected. For Fanuc controls, the end of file delimiter character is a percent sign (%).
As with almost all parameters, the parameter number that controls this function will vary from one control model to another. For a 16 series Fanuc control, it happens to be parameter number 3201, bit number six. If this bit is set to a zero (0) - as most machine tool builders set it - the machine will terminate the program loading process when an M02, M30, or M99 is detected. But if you set this bit to a one (1), the machine will continue loading programs until it detects the end of file delimiter character (%).
This allows you to store all the programs (main and sub) associated with a job in one file. The format must look like this:
The order of programs (main versus sub) have no special meaning - they can be in any order. What is important is that all the programs are contained in one file and that the percent sign begins and ends the file.
What about saving multiple programs?
The technique just shown may not be very helpful if you did not have the additional ability to save multiple programs back to your DNC system in one file. What good would it do you to have all the programs related to a job in one file on your computer if the first time you had to re-save them from the machine they had to be split up into multiple files?
During the program saving (output) process, most Fanuc controls allow you to specify multiple programs. The trick is that you must separate them with a comma (,). To save programs O0001, O1001, O1002, and O1003, for example, place the mode switch to edit, press the program key, type
and press the soft key under punch.