Does you machine have G68?
Hi all
this is my first post to this form (i joined yesterday) and i hope someone out there can help me with some macro programs.( i hope i posted in the right form)
i only know a little about macro programs,i'm a g-code programmer.i searched the forms and found many macros,but they were all for milling machines or straight in machining....nothing going in on an angle in a lathe.i am machining a ....cone part!(nozzle tip)in the lathe and i need to put holes around the tip/cone
on different angles/positions/hole diameters & different depths in the z-minus & x-minus directions(we do a lot of similar parts,macros will be the best).angle will be to the z axis.i will use one main program to turn the part and position for the macro with tool,spindle,coolant,start points ect already called up(radius comp either in the macro or call first?whats best?)i will then index my c axis and repeat for more holes,usually 1-3 holes per part.we have a nakamura sc 200 my machine with fanuc 21i-tb control.all of our programming is done in inches.i would like to have a drill peck cycle,helix mill cycle,and a circle mill cycle that can take multi-passes around arcing in and out of each cut.i would like to use rad comp on helix and circle.these are also small parts with hole sizes ranging from around .04"-.150",so there is not much room between the drill dia,e-mill dia & finish hole size.(example .047 dia. hole being drilled with .043 dia drill and milled to size with a .0394 dia e-mill.....just an example of one hole).i would like to have as many of the arguments met as possible that i will list in my g65 call.any help would be great...a complete working macro would be better.i am also new to these angled live holders,i am still waiting for my holders to come,but need to get the programming done ahead of time,so i'm ready to test when they get here.straight machining no problem but angled......gives me a problem.
1)lathe angle drill macro:G65 P8800 A25. H.160 Q.043 F5.0
(ALL ARGUMENTS ARE POSITIVE NUMBERS)
(A=ANGLE IN Z PLANE)
(F=FEED)
(H=HYPOTENUSE LENGTH...DEPTH)
(Q=PECK AMOUNT)
(*****or a complete retract with reducing peck amounts would be better or both******)
2)lathe angle circle mill macro:G65P8801D.0394X.1504Y0.K.160R.0472F2.5C.001A 25.S100.
(ALL ARGUMENTS ARE POSITIVE NUMBERS)
(D=DIA. OF E-MILL)
(X=X START POINT..CENTER)
(Y=Y START POINT..CENTER)
(K=HYPOTENUSE LENGTH..LENGTH/DEPTH OF HOLE AT ANGLE)
(R=DIA. OF HOLE)
(F=FEED OF CIRCLE MILL)
(C=DEPTH OF CUT or # OF PASSES OF CIRCLE MILL)
(A=ANGLE = Z PLANE)
(S=FEED INTO HOLE TO START CIRCLE MILL)(some holes are bigger than the e-mill but some are smaller)
3)lathe angle helix mill macro:G65P8802K.0394X.1504Y0.Z.075E.0472F2.5Q.001A 25.W.08
(ALL ARGUMENTS ARE POSITIVE NUMBERS)
(K=DIA. OF E-MILL)
(X=X START POINT..CENTER)
(Y=Y START POINT..CENTER)
(Z=HYPOTENUSE LENGTH..LENGTH/DEPTH OF HOLE AT ANGLE)
(E=DIA. OF HOLE)
(F=FEED )
(Q=DEPTH OF CUT IN Z)
(A=ANGLE = Z PLANE)
Thanks...i will look for other threads on this form that i can help out with,like tooling,maintenance ect.these are more my areas.
CNC-Lathe-Junkie
I am interested in seeing how you plan to interpolate a diameter without g68 in a macro.
The machine that we have unfortunately does not have coordinate conversion nor do they have 3D coordinate conversion.(in our machines its g368,g68 is mirror image/balance cutting and we don't have the options) In this case we will have to program the machine to accommodate the angle that the tool is sitting on. Most CAM systems are capable of doing this,just not with the level that we have.i would like to use a macro to accommodate many parts.i'm sure that someone who is good at writing macros can figure this one out......who's up for the challenge?
Problems with writing the macro only for angled live tool machining in the lathe.i have many years experience in programming,set-up,tool making,maintenance ect.im a cnc machinist ,mostly for lathes.i can program and/or find g-code and/or macro programs for drilling/milling 90 deg to an axis ..thats no problem.i need help doing this on an angle in the lathe,and i would prefer using macro programming over long hand g codes.live tool machining on an angle is the issue.i believe all the info needed for a macro program is stated in my 1st post.
hope this helps.
What I am alluding to is if you cut in the XY plane you get a circle. When you cut in the xz plane, you get a circle. When you cut in the yz plane you get a circle. Now, when you cut in the XYZ plane you get an ellipse when you try to cut a circle. So, you have to make small linear moves to get a circle at an angle if you do not have G68.
interesting!!
i hear what you are saying "when you cut in the XYZ plane you get an ellipse when you try to cut a circle".
any more ideas/suggestions on how to proceed? i need to interpolate these diameters and have control over the size(+/- .002" avg.)...i can't just drill in because of burrs into a cross hole. (i wish i could....the drilling should be OK)the process has already been proven on our mills...now i need to move it to the lathe to free up mill time.
Start simple. Start with the drilling. I think the others will be a problem due to the arc cutting.
What type of pecking? G73 style? Or, G83?
You will need 2 feeds, unless you want the retract to be a formula based upon the cut feed. Remember, you do not want to be in G00 when peck returning at an angle.
How do you want the peck retracts to be handles? Retract .02? .03? All the way out?
How do you want the return from peck to be handled? Shy of the last peck depth position by the retract amount?
So, all of the positions will have to be trigged out by the control. You will probably be storing positions in variables since you want to peck. Now, it is time to ask yourself, is there any reason I want to go through this headache(and, it will be a serious headache) rather than just post out a program in a Cam program?
There was a time for macros. Now, it's pretty much gone. Cam can do just about anything, more efficiently.
I think your right ....gonna be a headache.i will do the drill and post here.i may have to upgrade mastercam to post programs and not use macros to cut arc's.i will not give up yet...anything is possible when the right heads get together,lol.do you know what level of mastercam i would need.we now have X2 basic for mill and lathe,(level 1's)...yes its old,lol.if you have a cadcam system could you post a pass of something doing a arc on an angle just so i can see what the format would look like(like the passes i'm trying to do with the macros only do it with cadcam system)?
1" diameter cut at 45 degrees using a .25 end mill and a .001" arc tolerance. The smaller the tolerance, the more lines you get.
%
O0001(TEMPLATE)
(POSTED - 02-13-19 10:38 AM)
(MACHINE - KUEI_NIGATA_HMILL_0)
G00 G17 G40 G49 G90
N4(1/4 EMIL NECK ST)
(CONTOUR OD )
T4 M106
M45 (AUGER ON)
M11 (UNLOCK)
G00 G90 G54 B90.
M10 (LOCK)
G00 G90 G54 X0. Y.3536
G43 H04 D04 Z3.
S8000 M03
Z1.1107
G01 Z1.0607 F25.
G41 X-.0448 Y.355 Z1.0592 F40.
X-.0893 Y.3592 Z1.055
X-.133 Y.3663 Z1.0479
X-.1757 Y.3761 Z1.0381
X-.2169 Y.3886 Z1.0256
X-.2564 Y.4036 Z1.0106
X-.2939 Y.4211 Z.9931
X-.329 Y.4409 Z.9734
X-.3614 Y.4628 Z.9514
X-.3909 Y.4867 Z.9275
X-.4173 Y.5123 Z.9019
X-.4403 Y.5396 Z.8746
X-.4598 Y.5682 Z.8461
X-.4755 Y.5979 Z.8164
X-.4875 Y.6284 Z.7858
X-.4955 Y.6596 Z.7546
X-.4995 Y.6912 Z.723
Y.723 Z.6912
X-.4955 Y.7546 Z.6596
X-.4875 Y.7858 Z.6284
X-.4755 Y.8164 Z.5979
X-.4598 Y.8461 Z.5682
X-.4403 Y.8746 Z.5396
X-.4173 Y.9019 Z.5123
X-.3909 Y.9275 Z.4867
X-.3614 Y.9514 Z.4628
X-.329 Y.9734 Z.4409
X-.2939 Y.9931 Z.4211
X-.2564 Y1.0106 Z.4036
X-.2169 Y1.0256 Z.3886
X-.1757 Y1.0381 Z.3761
X-.133 Y1.0479 Z.3663
X-.0893 Y1.055 Z.3592
X-.0448 Y1.0592 Z.355
X0. Y1.0607 Z.3536
X.0448 Y1.0592 Z.355
X.0893 Y1.055 Z.3592
X.133 Y1.0479 Z.3663
X.1757 Y1.0381 Z.3761
X.2169 Y1.0256 Z.3886
X.2564 Y1.0106 Z.4036
X.2939 Y.9931 Z.4211
X.329 Y.9734 Z.4409
X.3614 Y.9514 Z.4628
X.3909 Y.9275 Z.4867
X.4173 Y.9019 Z.5123
X.4403 Y.8746 Z.5396
X.4598 Y.8461 Z.5682
X.4755 Y.8164 Z.5979
X.4875 Y.7858 Z.6284
X.4955 Y.7546 Z.6596
X.4995 Y.723 Z.6912
Y.6912 Z.723
X.4955 Y.6596 Z.7546
X.4875 Y.6284 Z.7858
X.4755 Y.5979 Z.8164
X.4598 Y.5682 Z.8461
X.4403 Y.5396 Z.8746
X.4173 Y.5123 Z.9019
X.3909 Y.4867 Z.9275
X.3614 Y.4628 Z.9514
X.329 Y.4409 Z.9734
X.2939 Y.4211 Z.9931
X.2564 Y.4036 Z1.0106
X.2169 Y.3886 Z1.0256
X.1757 Y.3761 Z1.0381
X.133 Y.3663 Z1.0479
X.0893 Y.3592 Z1.055
X.0448 Y.355 Z1.0592
G40 X0. Y.3536 Z1.0607
G00 Z3.
M05
G91 G28 Z0.
G28 Y0.
G90
M11 (UNLOCK)
G00 B0.
M46 (AUGER OFF)
M30
%
hy cnc lathe junkye please, will you share a photo with your part, and the machine ? in order to give you advice, i need to know what axis are available, and i would like to see the toolholder / kindly
ps : i have just a little experience with okuma y lathes, milling with xcz axis ( that's 3d ), math for generating interpolated movements, and feed management, when feed projection among each axis is variable
we are merely at the start of " Internet of Things / Industrial Revolution 4.0 " era : a mix of AI, plastics, human estrangement, powerful non-state actors ...