Lathe OD Turning
06 Oct 2010 10:07 #4532
by Rick G
Replied by Rick G on topic Re:OD Turning Subroutine
Thanks John, hope to try this weekend.
Rick
Rick
Please Log in or Create an account to join the conversation.
12 Dec 2010 12:26 #5980
by Rick G
Replied by Rick G on topic Re:OD Turning Subroutine
Hello John,
Thanks for posting your subs. I was using your od sub the other day and I wondered if it could be modified to use existing part files. Perhaps to run the same part from different stock sizes.
The below assumes a G92 to set work piece.
I made the part file testrun.ngc a sub by adding the 0<testrun> sub and o<testrun> endsub to it.
Below is untested, and a possible starting point, what do you think?
; 100717:10.32 john thornton
; adapt for ngcgui format by:
; 1. making a subroutine with positional parms
; 2. shorten some names for visibility in gui
;; modify to use existing part file
;; final diameter is smallest diameter of smallest section of part
o<od4> sub
#<Material_Dia> = #1 (=2.000 Material Diameter)
#<Final_Dia> = #2 (=1.500 Final Diameter)
#<Depth_Cut> = #3 (=0.010 Depth of Cut)
#<Final_Cut> = #4 (=0.000 Final Cut)
#<SurfaceSpeed> = #5 (=100 Surface Speed)
#<FeedRate> = #6 (=2 Feed Rate)
#<Max_RPM> = #7 (=1500 Max Spindle RPM)
#<Z_EndOfCut> = #8 (=-0.5 End of Cut)
#<Z_StartOfCut> = #9 (=0.100 Start of Cut)
#<RToolNumber> = #10 (=3 Roughing Tool)
#<FToolNumber> = #11 (=3 Finishing Tool)
#<Coolant> = #12 (=8 Flood=8, Off=9)
;;
#<Cut-Depth> = #13 (=1.000 Deepest Cut)
#<Mat_plus> = #14 (=3.000 Material Plus)
T#<RToolNumber> M6
G43 G7 G96 D#<Max_RPM> S#<SurfaceSpeed>
;G7
F#6
M3 M#<Coolant>
;; add depth of deepest cut to Material diam
#14=[#13+#<Material_Dia>]
G0 X#14 Z#<Z_StartOfCut>
o100 while [#14 gt #<Material_Dia>]
O101 if [[#14-#<Depth_Cut>] gt #<Final_Dia>]
#14=[#14-#<Depth_Cut>]
O101 else
#14=#<Material_Dia>
O101 endif
;;reset cord system
G10 L2P1 X#14
;; go to sub program
o<testrun> call
G0 X#14
G0 Z#<Z_StartOfCut>
o100 endwhile
M5 M9
G0 Z#<Z_StartOfCut>
G49
o<od4> endsub
The testrun program could be ....
o<testrun> sub
G0 X2.00
G0 Z0.00
G1 X1.5
G1 Z-.5
G1 X1.75
G1 Z-.75
G1 X2.00 Z-1.25
o<testrun> endsub
Thanks for posting your subs. I was using your od sub the other day and I wondered if it could be modified to use existing part files. Perhaps to run the same part from different stock sizes.
The below assumes a G92 to set work piece.
I made the part file testrun.ngc a sub by adding the 0<testrun> sub and o<testrun> endsub to it.
Below is untested, and a possible starting point, what do you think?
; 100717:10.32 john thornton
; adapt for ngcgui format by:
; 1. making a subroutine with positional parms
; 2. shorten some names for visibility in gui
;; modify to use existing part file
;; final diameter is smallest diameter of smallest section of part
o<od4> sub
#<Material_Dia> = #1 (=2.000 Material Diameter)
#<Final_Dia> = #2 (=1.500 Final Diameter)
#<Depth_Cut> = #3 (=0.010 Depth of Cut)
#<Final_Cut> = #4 (=0.000 Final Cut)
#<SurfaceSpeed> = #5 (=100 Surface Speed)
#<FeedRate> = #6 (=2 Feed Rate)
#<Max_RPM> = #7 (=1500 Max Spindle RPM)
#<Z_EndOfCut> = #8 (=-0.5 End of Cut)
#<Z_StartOfCut> = #9 (=0.100 Start of Cut)
#<RToolNumber> = #10 (=3 Roughing Tool)
#<FToolNumber> = #11 (=3 Finishing Tool)
#<Coolant> = #12 (=8 Flood=8, Off=9)
;;
#<Cut-Depth> = #13 (=1.000 Deepest Cut)
#<Mat_plus> = #14 (=3.000 Material Plus)
T#<RToolNumber> M6
G43 G7 G96 D#<Max_RPM> S#<SurfaceSpeed>
;G7
F#6
M3 M#<Coolant>
;; add depth of deepest cut to Material diam
#14=[#13+#<Material_Dia>]
G0 X#14 Z#<Z_StartOfCut>
o100 while [#14 gt #<Material_Dia>]
O101 if [[#14-#<Depth_Cut>] gt #<Final_Dia>]
#14=[#14-#<Depth_Cut>]
O101 else
#14=#<Material_Dia>
O101 endif
;;reset cord system
G10 L2P1 X#14
;; go to sub program
o<testrun> call
G0 X#14
G0 Z#<Z_StartOfCut>
o100 endwhile
M5 M9
G0 Z#<Z_StartOfCut>
G49
o<od4> endsub
The testrun program could be ....
o<testrun> sub
G0 X2.00
G0 Z0.00
G1 X1.5
G1 Z-.5
G1 X1.75
G1 Z-.75
G1 X2.00 Z-1.25
o<testrun> endsub
Please Log in or Create an account to join the conversation.
12 Dec 2010 13:11 #5981
by BigJohnT
Replied by BigJohnT on topic Re:OD Turning Subroutine
Hi Rick,
I'm not sure what you doing here exactly... it is early in the morning for me.
If you have Dewey's gui embedded into Axis you can just press any axis key and it enters the current value. So you jog up to a start point then press the axis key and it enters the value.
John
I'm not sure what you doing here exactly... it is early in the morning for me.
If you have Dewey's gui embedded into Axis you can just press any axis key and it enters the current value. So you jog up to a start point then press the axis key and it enters the value.
John
Please Log in or Create an account to join the conversation.
12 Dec 2010 13:26 #5982
by Rick G
Replied by Rick G on topic Re:OD Turning Subroutine
John,
Sort of a G71 with a gui?
If I have a finish path for a part that I want to run I am setting a start position to work down to it by the entered maximum cut per pass.
I am re setting the machine position with G10 each pass until done. Been up about 4 hours now.
Rick G
Sort of a G71 with a gui?
If I have a finish path for a part that I want to run I am setting a start position to work down to it by the entered maximum cut per pass.
I am re setting the machine position with G10 each pass until done. Been up about 4 hours now.
Rick G
Please Log in or Create an account to join the conversation.
12 Dec 2010 13:55 #5983
by BigJohnT
Replied by BigJohnT on topic Re:OD Turning Subroutine
Been up 3 here lol.
I think I understand... if you have a profile you cut the profile at the start OD then increment it in by "depth" until the last pass is at final depth?
Is G71 a roughing routine or something like that?
John
I think I understand... if you have a profile you cut the profile at the start OD then increment it in by "depth" until the last pass is at final depth?
Is G71 a roughing routine or something like that?
John
Please Log in or Create an account to join the conversation.
12 Dec 2010 14:06 #5984
by Rick G
Replied by Rick G on topic Re:OD Turning Subroutine
Exactly.
Does the same thing as your od sub but a more complex shape is possible that is contained in another sub.
I believe G71 is a roughing routine in other interfaces and I believe someone might be working on it for EMC.
Rick
Does the same thing as your od sub but a more complex shape is possible that is contained in another sub.
I believe G71 is a roughing routine in other interfaces and I believe someone might be working on it for EMC.
Rick
Please Log in or Create an account to join the conversation.
12 Dec 2010 14:19 #5985
by BigJohnT
Replied by BigJohnT on topic Re:OD Turning Subroutine
I just did some googling on G70/71 and I think something like that is possible and desirable to have. So instead of the OD turning part another subroutine with the profile is in the middle...
G71 subroutine for roughing using cutter comp and G92 offsets for X leaving a uniform amount of material for finishing and calling the "profile" subroutine for the path to follow.
G70 subroutine for finishing using cutter comp and calling "profile" subroutine with the finish tool.
If you embed Dewey's GUI into axis you can combine subroutines to form a complete g-code file. So you can go to the G71 Tab and fill out the blanks and insert it then go to the G70 tab and do the same. Then "finalize" and run.
Is this what you had in mind?
and I thought today would be slow and easy...
John
G71 subroutine for roughing using cutter comp and G92 offsets for X leaving a uniform amount of material for finishing and calling the "profile" subroutine for the path to follow.
G70 subroutine for finishing using cutter comp and calling "profile" subroutine with the finish tool.
If you embed Dewey's GUI into axis you can combine subroutines to form a complete g-code file. So you can go to the G71 Tab and fill out the blanks and insert it then go to the G70 tab and do the same. Then "finalize" and run.
Is this what you had in mind?
and I thought today would be slow and easy...
John
Please Log in or Create an account to join the conversation.
12 Dec 2010 14:45 #5986
by Rick G
Replied by Rick G on topic Re:OD Turning Subroutine
That makes sense, I did not even look at the finish run but that would be perfect.
I have not embedded Dewey's GUI yet as the machine that runs the lathe has no web access, but will soon.
As a matter of fact I am building a new shop here and am going to take advantage of the mild temp to run some wires an insulation today. When done I will have much better access for all the machines.
If you get a chance can you try the files I sent you?
Rick
I have not embedded Dewey's GUI yet as the machine that runs the lathe has no web access, but will soon.
As a matter of fact I am building a new shop here and am going to take advantage of the mild temp to run some wires an insulation today. When done I will have much better access for all the machines.
If you get a chance can you try the files I sent you?
Rick
Please Log in or Create an account to join the conversation.
12 Dec 2010 14:55 #5987
by BigJohnT
Replied by BigJohnT on topic Re:OD Turning Subroutine
The file in this thread or did you e-mail me one?
I'm adding on to my shop too... the footer is done and all I'm lacking is finishing.
John
I'm adding on to my shop too... the footer is done and all I'm lacking is finishing.
John
Please Log in or Create an account to join the conversation.
12 Dec 2010 15:18 #5988
by Rick G
Replied by Rick G on topic Re:OD Turning Subroutine
Here goes...
Please Log in or Create an account to join the conversation.
Time to create page: 0.110 seconds