- GCode and Part Programs
- O Codes (subroutines) and NGCGUI
- Metric Lathe subroutines - G71, G72, etc etc
Metric Lathe subroutines - G71, G72, etc etc
I have been busily converting the template files and subs I have used for some time into ngcgui subs.
I have taken a modular, lego block, approach to this, intending that the user strings a series of subs together to build the full program.
Whilst I have titled this Metric lathe subs, the only metric setting is G21 in <start>
The subs do not make any assumptions or add any clearances etc. internally, other than those provided through the gui,
so they will work in any unit base
The main feature of these subs, is the ability to enter a finished profile path in terms of G01, G02 and G03 X, Z and R codes and the g71 / g72 routines will read it, work out deepest cuts required ( X and Z respectively), offset the start point by the required amount and then cut the profile in a decrementing series of loops until finished ( or finishing) dimensions are reached.
The main limiting factor is the tool profile.
All is explained fully in the README with the files.
You need to understand the ngcgui from a users perspective, to make the best of these routines. Please read Deweys notes.
The easiest way to use these subs, is to write a simple program which just traces the profile you want and load in Axis.
If the plot is what you want, copy it into the fields of the <path> sub(s)
The loop will start after a move to X[diameter + clearance] Z[startZ] and will return to these points after each loop,
so these need to be correctly entered in <start> and your code needs to finish at co-ordinates where this can be reached without collision.
Only 2 subs can be duplicated as new instances ( <moveto> and <toolchange> )
The cutting subs are for the most part split into roughing and finishing routines to allow a toolchange to be inserted between.
Usual caveats, not warranted fit for any purpose, check the plot and run in simulation first.
Programs based solely upon subs can be very difficult to debug or to spot potential problems easily.
Hope someone finds them useful.
(File now in later post)
Please Log in or Create an account to join the conversation.
I made a zip of the wrong directory and omitted 4 crucial helper subs.
.zip file as above now contains all files, please download again.
PS
Found another gotcha
<toolchange> had commented out M6Tn sequence for running in sim and wasn't reinstated, now corrected.
Please Log in or Create an account to join the conversation.
If turning a profile which incorporates a large taper, from a billet whose diameter is considerably greater than the finished diameter
( I was turning a large stub arbour on a R8 tapered shank from a 45mm diam. billet)
the built in limiting of fresh air cuts will lead to gouging when the large end of the taper gets down below the 'fresh air' limit because the taper will be considerably steeper than the finished angle.
Have removed the code from o710 helper sub and amended the g71 code to use whichever X value is larger for retraction, as the tool will be now starting well above the [diam+clearance] value.
Zip updated.
Please Log in or Create an account to join the conversation.
first thanks for your responses in other threads.
Friend I have a doubt, G71 can be used for internal diameters? g71 but I need to apply for ID?
friend which is how to apply or install your subroutines to my linuxcnc?
I tried but it seems that I'm not doing well. you could guide me.
thanks.
Jorge
Colombia
Please Log in or Create an account to join the conversation.
No the G71 - 72 routines are only for external profile cutting.Friend I have a doubt, G71 can be used for internal diameters? g71 but I need to apply for ID?
You can write your own or adapt mine, the internal taper routine will get you started, it is simply a matter of reversing the direction of the incremented cut on the X axis.
(and of course reversing the calculation logic accordingly)
You need to read up on ngcguifriend which is how to apply or install your subroutines to my linuxcnc?
JT has 3 sticky threads in this section which discuss how to
www.linuxcnc.org/index.php/english/forum...broutines-and-ngcgui
When you have read these, the README and __inifile_additions in my .zip will make sense
regards
Please Log in or Create an account to join the conversation.
I never run a program in linuxcnc.
but I have a question. when you build a program with subroutines, and one is going to give an accurate measure, and you have to repeat a cut, can run only linuxcnc that step, without having to run the entire program.
2.5.1 Linuxcnc
in his "tool table". How do you compensate for wear of the tool?
Try installing the patch fanuc with git, but git linuxcnc not respond well.
thanks.
Please Log in or Create an account to join the conversation.
That may be the root of your problems, it must be hard to understand something as an intellectual entity without actually using it.I never run a program in linuxcnc.
With these subroutines you can run the G71f (or G72f) routine on its own. That will allow you to repeat the finish cut to final dimensions.but I have a question. when you build a program with subroutines, and one is going to give an accurate measure, and you have to repeat a cut, can run only linuxcnc that step, without having to run the entire program.
Nothing to do with this thread, try posting here2.5.1 Linuxcnc
in his "tool table". How do you compensate for wear of the tool?
Try installing the patch fanuc with git, but git linuxcnc not respond well.
www.linuxcnc.org/index.php/english/forum...t-patch?limitstart=0
regards
Please Log in or Create an account to join the conversation.
Thanks,
Wes
Please Log in or Create an account to join the conversation.
I changed servers, this link got orphaned.
The file size limits have changed so I can post it here now instead.
No chance of imperial sorry, I don't use it and the industry in the UK has not used imperial really since the mid 70's.
They should not be too hard to convert, the only 'metric' thing about them really is the default gcodes in the startup lines and the default values in the ngcgui fields.
regards
Please Log in or Create an account to join the conversation.
greetings, you can use the "run at line" with subroutines, I read that it is not recommended, there will be a form that can be used?
Thanks.
Jorge
Please Log in or Create an account to join the conversation.
- GCode and Part Programs
- O Codes (subroutines) and NGCGUI
- Metric Lathe subroutines - G71, G72, etc etc