Created and Maintained by the Real World Software Developers and Machinists at www.KentechInc.com ... click here to check it out !!
Showing posts with label cnc lathe programming. Show all posts
Showing posts with label cnc lathe programming. Show all posts

Tuesday, August 12, 2014

Why Use Cutter Compensation - Follow the Crowd ??

The story has been circulating here about a support issue that was raised recently where a Kipware® conversational customer inquired about how to have KipwareT® output program coordinates using the tool center vs. using G41/G42 cutter compensation and the imaginary tool tip on the control. The conversation went something like this :

Support Staff : "Why would you want to do that? That's really not a good programming practice."

Client : "Well all our programs are written like that."

Support Staff : "OK ... but that's not a good programming practice. When we created Kipware® conversational we wanted to include best programming practice so KipwareT® outputs G41 / G42 and does all the calculations and automatically includes all start-up and cancel blocks and code ... so it creates a better program. No worries ... even if you don't know how to program it KipwareT® does it all for you."

Client : "Yes but nobody programs like that."

Really? Nobody out there programs like that? We find that hard to believe.

So ... we decided to post some of our main reasoning for considering the use of cutter compensation on the control as "Best Programming Practice". If you agree with our points ... we hope that you will consider making the change ... getting educated ... and to start creating your G code programs using G41 / G42 cutter compensation.

  1. Program Coordinates ... programming to the tool tip center means that coordinates in the program do not reflect actual part print coordinates. Coordinates are based on the tool tip center rather than on the part dimensions. You can imagine the trouble and confusion that happens when edits need to be made.
  2. Tool Interchange - Turning ... since the G code was written for a specific tool radius ... the program will only function correctly for that tool radius. Decide to use a 1/64 radius for finish when the program was written for a 1/32 radius ... re-program or re-generate the toolpath. 
  3. Tool Interchange - Milling ... I think this point probably comes into play more for milling G code than turning G code. Does your shop always have perfect .500 end mills? If so ... WHY ???? Re-grinding end mills is quite a cost saver ... but it means your end mills might be .485 or something odd. If you use G41 / G42 ... who cares? Just enter the correct offset value.
  4. Dimensional Adjustments ... Come on, this is the real world. There is no reason to keep running back and forth to the CAD/CAM guy or programming office when dimensional adjustments need to be made during production ... and they will be because cutting conditions are not theoretical, they're real !!. Cutter compensation and part / tool offsets can handle probably 99.99% of all dimensional adjustments. Use the power of the control !!
Some of the main reasons we hear for why clients don't use cutter compensation ( and none of them are valid by the way ) ...
  1. Nobody taught me. Come on ... grab a hold of your future and do some "playing" at the machine ... or read for yourself. This is a truly important programming tool ... you need to know hoe to use it if you want to go anywhere.
  2. Nobody uses it. Like our scenario above ... just keeping following the crowd ... over the cliff. If I ran that shop ... the guy that comes to me and says "I think we need to change the way we think about cutter compensation" would have more of my respect than the guy who gives me the excuse "That's the way we always did it."
"I'm not stubborn ... 
it's just that doing things your way is stupid."

After having spent more than 30+ years creating ... editing ... teaching ... G code and running shops on a day-to-day basis ... cutter compensation is one of the most mis-understood and mis-used programming feature. And also the most important tool a programmer and operator and shop foreman has at his/her disposal.

If you agree ... want to learn more ... or just want some additional reading ... below is a link to one of our previous posts that dealt with this issue also :
http://kipware.blogspot.com/2013/03/cutter-compensation-programmers-best.html

Unfortunately CAD/CAM systems have made it o easy to program with tool tip radius ... but in the real world, on the shop floor, it can be a real detriment to productivity and efficiency. We urge any CNC programmer out there who is not using cutter compensation on the control to step up and take control of your future ... get educated on cutter compensation ... and use cutter compensation in your G code. Your future will be a lot brighter ... and profitable.

Until Next Time ... Happy Chip Making ... with G41 / G42 !!

Please visit our website for the best in Real World Machine Shop Software ... 
just CLICK the pic below !!

Wednesday, July 30, 2014

Homemade Bar Puller for Your CNC Lathe - Resurrected

We first published this tip a few years ago ... and it has become so popular and copied on many other sites and in many trade journals ... and is asked about by so many of our clients ... that we had to bring it back for a repeat post ... once again !!

Enjoy ... and profit from this simple yet super efficient plan.

----------------------------------

One of the best ways to add efficiency to your CNC lathe is to make it run unattended. Using a bar feeder or a simple bar-puller, you can make your lathe run in a more complete AUTO cycle, stopping only for the refilling of the stock and minor offset adjustments. In this article, we'll share a simple but efficient design for a bar-puller and show you a programming example of how to put it to use.

Granted, a little work is required but when put to the right use, unattended operation can really help your bottom line. For example, how about being able to leave the shop at 5:00 and still have your lathe running producing another 50-60 parts while you're home eating dinner. Or for the one man shop, how about having production being run while your on the phone getting that next deal. With the right combination of cutting conditions and unattended operation, there's no telling where you can go.

The CONCEPT
The idea behind this bar-puller is to fill the spindle with a bar length of material, then using an auto cycle perform the following sequence :
  • Grab the stock with the puller
  • Open the chuck
  • Pull the stock to the desired length
  • Close the chuck
  • Retract the puller
  • Machine the part
  • Cut-Off the part
Then simply repeat the cycle again, the number of times for repeat depends on the number of parts that can be made using the length of bar stock in the spindle.

The SET-UP
To create your bar-puller feature, you'll need a couple of other items other than the bar puller to be outlined here.

First, you'll need to cut the bar stock the length of your spindle so the stock can be slid inside your spindle and pulled by the bar puller through the chuck or collett nose in the front. NEVER, NEVER, NEVER hang any size stock outside the end of the spindle - all stock must fit inside the spindle housing and be supported with spindle liners or a support ring as outlined below.


Since the difference between the stock OD and the spindle ID is usually pretty big, you can't just put the stock in the spindle. It must be supported in the spindle to prevent the stock from rattling around. This can be done with commercially purchased spindle liners or you can make a simple spindle liner ring using the design and concept outlined here. Please note that these liners take up the "slop" between the stock size and the ID of the spindle and must be used to prevent possible whip or damage to the spindle bearings or other possible injury.

One method is to make a ring out of plastic or similar material that attaches to the end of the stock with a set screw. The OD of the ring fits snuggly into the spindle ID and the ID of the ring attaches to the OD of the stock. This ring will move along the inside of the spindle along with the stock as it gets pulled toward the chuck. Calculate the number of cycles so this ring will reach the end of it's possible stroke as the max count is reached.


The BAR PULLER
Now the homemade bar puller needs to be made. The concept behind this puller is that you can make the size required as needed for the size material you are currently working with. You can make a few at a time, leaving some finishing operations until the ID size is determined. This way you'll have maybe 70% of the puller made then you can simply finish the rest when the time approaches and the final sizes are determined.

The bar puller uses a "split" piece of aluminum or other material softer than the material you will be machining. It uses simply a piece of bar or tube that is machined with the OD to fit into an ID tool holder station in the turret, and the ID slightly smaller than the OD of the stock. You may need to turn down the front end as per the sketch below to maintain a wall thickness that is thin enough to slide over the stock when split yet strong enough to pull the bar, depending on the weight of the bar stock determined by the diameter of the stock. The puller is then split in two or three or more places using a hack saw or slitting saw and an O-Ring placed on the OD of the puller to keep the tension. This allows for the puller to split and feed over the bar stock with the O-Ring providing tension to pull the stock and for the puller to return to it's original shape when done.


The PROGRAM
In the program, the puller is mounted in the turret, in our example Tool #3. Then in the CNC programs AUTO cycle, it is fed over the bar stock, the chuck opened, the turret moved to position taking the stock with it, the chuck closed, and the machining begun.</P><P>In the example below, we are simulating a Fanuc series 10T or higher CNC control. Your M functions may be different, please consult your programming manual for your specific commands. Use this program as a guide, not a bible. The X0 is the center line and Z0 for this tool is set at the face of the stock as it sticks out of the chuck after cut off.

N0001 --------------- sequence number for this operation
M05 ----------------- make sure the spindle is stopped
G00 T0303 ---------- index to the bar puller station
G00 X0 Z.200 ------- rapid to a clearance point
G98 ----------------- change feed to IPM
G01 Z-.750 F20.0 --- feed onto the stock
M11 ----------------- open the chuck
G01 Z2.000 ----------feed to needed length plane
M10 ----------------- close the chuck
G01 Z3.500 ---------- feed off the stock
G00 X8.00 Z8.00 ---- rapid to index position
T0300 --------------- cancel the tool offset
G99 ------------------ return feed to IPR
M01 ----------------- optional stop

This sequence should be placed at either the top or bottom of the machining program. The best way to put the AUTO cycle into use is with the use of sub-programming. The MAIN program would be the call for the machining program including the number of times to call the program depending on the number of pieces you can make from the length of bar stock in the spindle. The SUB program would actually do the pulling and the machining. For example, in the example below, program O0001 is the MAIN program, calling the SUB program O1111 - 12 times, which actually does the pulling and the machining.

O0001 ------------ Main Program
M98 P1111 L12 -- sub program call
M30 --------------- program end
..
..
O1111 ------------- Sub Program
N0001 ------------- Bar pull sequence
--
--
--
M01
N0002 ------------- machine the part
--
--
--
M01
N0003 ------------- cut off
 --
 --
 --
M01
M99 --------------- sub program end

In the above example, the operator only presses the Cycle Start on the MAIN program. This starts a 12 piece cycle that will include the pulling out of the stock, the machining of the part, and the cut off of the part. Recalling and executing the cycle 12 times.

Happy Chip Making !!

Please visit our website for the best in Real World Machine Shop Software ... 
just CLICK the pic below !!

Wednesday, March 13, 2013

Cutter Compensation - A Programmers Best Friend


In this Making Chips post ... we would like to touch on some of the points regarding cutter compensation ... when turning ... angles and radii ... on Fanuc based CNC controls.

Many programmers shy away from cutter compensation ... primarily because they have never taken the time to fully understand both it's power nor how to use it properly. But the reality is that cutter comp is one of a programmers best friends. The most common reason goes something like this "It's just as easy to have the CAD/CAM system compensate for the TNR ( tool nose radius ) and out put the hard numbers." That is true ... but life on the shop floor makes this a bad practice. A couple of reasons why :

  1. The "numbers" in the G code don't match the "numbers" on the part ... because they are taking into account the TNR. If manual edits need to be made ... even simple edits ... this makes it much harder because the part dimensions don't match the G code numbers.
  2. Say after cutting ... the conditions warrant either a bigger or smaller TNR for better cutting conditions. If cutter comp is used ... it's a simple offset change. If not ... it's a trudge back to the CAD/CAM guy or system to re-post and make a new G code program for the revised tool and it's TNR.
  3. In milling ... let's say I broke my last perfect .250R end mill ... but I have a re-ground one that is .245R.. Again, if cutter comp is used ... it's a simple offset change. If not ... it's another trudge back to the CAD/CAM guy or system to re-post and make a new G code program for the revised tool radius.

But here we are going to stick with turning here ... and here are a couple of simple rules for when to use and when not to use cutter compensation.

  • Whenever angles or radii are involved ... you must use TNR compensation or the angles and radii will be off. Because the programmed point of the cutting tool, an imaginary sharp point, does not coincide with the actual point of the cutting tool which always has some corner radius. For this reason, when machining close tolerance angle or radius cuts, inaccurate workpieces will be produced. The amount of error is proportional to the amount of the tool nose radius.
  • Only worry about using it for finishing ... It's really not worth the effort to use it roughing ... the amount you leave for finish allowance will probably "hide" the mismatch due to the TNR.
  • You must start cutter comp with a "start up block". This block is usually the move as you approach the part ... the move distance must be greater than the radius in the TNR offset. So if your tool has a radius of .032 ... make a move at least .035 ... preferably more. 
  • Make sure that your TNR is less than any radius on the part ... don't try to jam an .032 tool into a .020 radius ... alarms will greet you somewhere along the way.
  • We'll cover some additional thoughts at the end of the post.


The Details :
The CNC control has the capability to automatically compensate for the tool nose radius thru the CUTTER COMPENSATION codes of G41 and G42. G41 is called cutter compensation left. The left side is explained as the side of the workpiece the cutting tool is on when viewed in the direction of cutter movement or the cutter is moving on the left side of the programmed path. Once commanded, G41 or G42 are modal commands and remain active until the G40 or cancel condition is obtained.

In Fanuc controls, in addition to commanding G41 or G42 direction, the programmer must also tell the control two other aspects of the cutting tool which are : (a) the amount of the tool nose radius and (b) the imaginary tool tip location. Both these values are entered in the tools geometry or wear offset table. In the offset table, the R value is the amount of the tools nose radius. If the program called T0101 in the tool command, in offset table #1, under the R column, the nose radius of the tool would be entered. The T column in the offset tables holds the imaginary tool tip location.



Cutter compensation must be programmed using what is commonly referred to as a start up block. This block, which must be a G01 type block, is used to activate the cutter compensation before the cutting tool actual contacts the workpiece. The movement amount in the start up block must always be greater than the nose radius of the tool stored in the R column of the offset table. Circular commands using G02 or G03 are not allowed on start up blocks.

G40 is used to cancel the automatic compensation of the tool nose radius. G40 should always be commanded on a G00 block as the tool moves away from the workpiece with the tool in a clearance position.

More Rules and Thoughts :
Many rules apply in the use of cutter compensation as the control is always checking the tool position so it can calculate for the tool nose radius. Three rules of thumb apply and should keep you free of the controls cutter compensation alarms :

(1) Always command a start up block before contacting the workpiece and move in the
G01 mode with a move greater than the nose radius of the tool.

(2) Use cutter compensation primarily in the finishing cut and try to eliminate it in the roughing
passes. The more moves made with G41 or G42 modal, the more likely for a
problem. To finish the part, use the start up block, finish cut the part and
command G40 when done. If additional cuts are required, use another start
up block and cancel the cutter comp each time as soon as the profile cut is
finished.

(3) Always cancel G41 or G42 using the G40 command. The best place to command G40 is
on a G00 block, at a clearance point or moving to a clearance point.

Because cutter compensation causes the control to perform some powerful calculations and is a complex command, you should also consult your controls instruction manual for further info on G41 or G42.

Happy Chip Making !!

Check out our Real World World machine shop software at www.KentechInc.com
Conversational CAD/CAM
Quoting & Estimating
G Code Conversion
CNC Training
.... and MORE !!!

Monday, January 14, 2013

A Homemade Bar Puller for Your CNC Lathe

We first published this tip a few years ago ... and it has become so popular and copied on many other sites and in many trade journals ... that we decided to help it live on forever by re-publishing here in our blog.

Enjoy ... and profit from this simple yet super efficient plan.

----------------------------------


One of the best ways to add efficiency to your CNC lathe is to make it run unattended. Using a bar feeder or a simple bar-puller, you can make your lathe run in a more complete AUTO cycle, stopping only for the refilling of the stock and minor offset adjustments. In this article, we'll share a simple but efficient design for a bar-puller and show you a programming example of how to put it to use.

Granted, a little work is required but when put to the right use, unattended operation can really help your bottom line. For example, how about being able to leave the shop at 5:00 and still have your lathe running producing another 50-60 parts while you're home eating dinner. Or for the one man shop, how about having production being run while your on the phone getting that next deal. With the right combination of cutting conditions and unattended operation, there's no telling where you can go.

The CONCEPT
The idea behind this bar-puller is to fill the spindle with a bar length of material, then using an auto cycle perform the following sequence :

  • Grab the stock with the puller
  • Open the chuck
  • Pull the stock to the desired length
  • Close the chuck
  • Retract the puller
  • Machine the part
  • Cut-Off the part

Then simply repeat the cycle again, the number of times for repeat depends on the number of parts that can be made using the length of bar stock in the spindle.

The SET-UP
To create your bar-puller feature, you'll need a couple of other items other than the bar puller to be outlined here.

First, you'll need to cut the bar stock the length of your spindle so the stock can be slid inside your spindle and pulled by the bar puller through the chuck or collett nose in the front. NEVER, NEVER, NEVER hang any size stock outside the end of the spindle - all stock must fit inside the spindle housing and be supported with spindle liners or a support ring as outlined below.


Since the difference between the stock OD and the spindle ID is usually pretty big, you can't just put the stock in the spindle. It must be supported in the spindle to prevent the stock from rattling around. This can be done with commercially purchased spindle liners or you can make a simple spindle liner ring using the design and concept outlined here. Please note that these liners take up the "slop" between the stock size and the ID of the spindle and must be used to prevent possible whip or damage to the spindle bearings or other possible injury.

One method is to make a ring out of plastic or similar material that attaches to the end of the stock with a set screw. The OD of the ring fits snuggly into the spindle ID and the ID of the ring attaches to the OD of the stock. This ring will move along the inside of the spindle along with the stock as it gets pulled toward the chuck. Calculate the number of cycles so this ring will reach the end of it's possible stroke as the max count is reached.



The BAR PULLER
Now the homemade bar puller needs to be made. The concept behind this puller is that you can make the size required as needed for the size material you are currently working with. You can make a few at a time, leaving some finishing operations until the ID size is determined. This way you'll have maybe 70% of the puller made then you can simply finish the rest when the time approaches and the final sizes are determined.

The bar puller uses a "split" piece of aluminum or other material softer than the material you will be machining. It uses simply a piece of bar or tube that is machined with the OD to fit into an ID tool holder station in the turret, and the ID slightly smaller than the OD of the stock. You may need to turn down the front end as per the sketch below to maintain a wall thickness that is thin enough to slide over the stock when split yet strong enough to pull the bar, depending on the weight of the bar stock determined by the diameter of the stock. The puller is then split in two or three or more places using a hack saw or slitting saw and an O-Ring placed on the OD of the puller to keep the tension. This allows for the puller to split and feed over the bar stock with the O-Ring providing tension to pull the stock and for the puller to return to it's original shape when done.


The PROGRAM
In the program, the puller is mounted in the turret, in our example Tool #3. Then in the CNC programs AUTO cycle, it is fed over the bar stock, the chuck opened, the turret moved to position taking the stock with it, the chuck closed, and the machining begun.</P><P>In the example below, we are simulating a Fanuc series 10T or higher CNC control. Your M functions may be different, please consult your programming manual for your specific commands. Use this program as a guide, not a bible. The X0 is the center line and Z0 for this tool is set at the face of the stock as it sticks out of the chuck after cut off.

N0001 --------------- sequence number for this operation
M05 ----------------- make sure the spindle is stopped
G00 T0303 ---------- index to the bar puller station
G00 X0 Z.200 ------- rapid to a clearance point
G98 ----------------- change feed to IPM
G01 Z-.750 F20.0 --- feed onto the stock
M11 ----------------- open the chuck
G01 Z2.000 ----------feed to needed length plane
M10 ----------------- close the chuck
G01 Z3.500 ---------- feed off the stock
G00 X8.00 Z8.00 ---- rapid to index position
T0300 --------------- cancel the tool offset
G99 ------------------ return feed to IPR
M01 ----------------- optional stop

This sequence should be placed at either the top or bottom of the machining program. The best way to put the AUTO cycle into use is with the use of sub-programming. The MAIN program would be the call for the machining program including the number of times to call the program depending on the number of pieces you can make from the length of bar stock in the spindle. The SUB program would actually do the pulling and the machining. For example, in the example below, program O0001 is the MAIN program, calling the SUB program O1111 - 12 times, which actually does the pulling and the machining.

O0001 ------------ Main Program
M98 P1111 L12 -- sub program call
M30 --------------- program end
..
..
O1111 ------------- Sub Program
N0001 ------------- Bar pull sequence
--
--
--
M01
N0002 ------------- machine the part
--
--
--
M01
N0003 ------------- cut off
 --
 --
 --
M01
M99 --------------- sub program end

In the above example, the operator only presses the Cycle Start on the MAIN program. This starts a 12 piece cycle that will include the pulling out of the stock, the machining of the part, and the cut off of the part. Recalling and executing the cycle 12 times.

Happy Chip Making !!

Check out our Real World World machine shop software at www.KentechInc.com
Conversational CAD/CAM
Quoting & Estimating
G Code Conversion
CNC Training
.... and MORE !!!