Stevo,
I went back and took a look at your macro and it's looks close. At the time of that post you didn't know yet or it wasn't stated yet but the code for the B-axis is really the only hitch with it. In Polar mode, you are no longer using actual table angle values, it's an "axis name swap" that the machine will use to calculate and rotate.
To explain, this is all Polar programming is: The contol will exchange one linear axis with a rotatary axis. This happens when a rotary axis name is used in the code. The code values being used still uses linear positioning. So all you need to do is swap the linear axis name with the rotary axis name. Then as Bill mentioned, there may be some parameters that will associate the proper "linear to rotary" connection. For example: X to A, Y to B, Z to C, etc. You and I can go over this in more detail outside of this thread if you'd like. But for you machine, is likely already set up correctly and I believe you mentioned running a 'test code' for G12.1..... so I think it's just a matter of getting the outputs to it's liking.
Anyhow, the one last hitch here... Your macro is running this in incremental. Personally, I've never ran polar in incremental on a part. I know it's possible as I've gone through the motions but that was still running a complete profile. On top of incremental, you've posted it as a loop which adds to the questions of "will this work?". BTW, I know you're just shooting ideas here and not forcing this to be this way..... FYI, some machines won't run Polar in incremental or they require a totally different set of axis names for incremental (such as using U, V, or W for example but I've seen odd ones like "H" and stuff). So your incremental process idea is new territory for me...
I've tweeked your macro and posted below the possibilities. The first program (O1111) is an incremental loop similar to your posted macro. I adjusted the G12.1 outputs so you can give this a whirl. I know the positioning might look funky but once you see where the value range is supposed to come from, what I'm doing here will make sense... just not sure if it works or is correct for the reasons stated above with being in incremental.
The 2nd program, I reworked your macro to run this in absolute mode. This program (O1112) is the entire profile complete. I couldn't find my old HMC post so I used my existing post configuration and simply renamed the axes accordingly. If you're up to it, try them out..... we gotta be in the ballpark here.....
note: This still has the lugs on center with the O/D. I'm not interested in this placement right now. My goal is to get you functional code and to get you the understanding of what Polar is, how to work with it and gain comfort to move forward from there.
Incremental Loop
O1111(G91 PROVEOUT)
#1=.5(TOOL DIAMETER)
#2=33.466(DIA TO CUT)
#4=.01(DEPTH OF TOOL)
#5=11.2(RADI FEED RATE)
#6=192(ROTARY FEEDRATE)
#3=100(SPEED)
#10=0(COUNTER)
G0G90G59G18X0Y3.Z[[#2+#1]/2]B0M3S#3
G91X-.5Z.15
G90Y.1
G1Y-#4F50.
G91G2X.5Z-.15R2.F#5
G1B9.2025F#6
N1G12.1
G3B.6204Z.3709R.665F#5
G3B.6068Z-.3928R.665
IF[#10GE15]GOTO2
#10=#10+1
G13.1
G1B18.405F#6
GOTO1
N2G1B9.2025F#6
G2X.5Z.15R2.
G0G90Y4.
M30
Absolute mode, complete profile
O1112(G90 PROVEOUT)
#4=.01(DEPTH OF TOOL)
#6=192(ROTARY FEEDRATE)
#3=100(SPEED)
G0G90G59G18X0Y3.Z17.583B0M3S#3
G90Y.1
G18Z17.583B0.
G12.1
G1Z17.583B-.5F200.
Y-#4F50.
Z17.483F#6
G2Z16.983B0.R.5
G3Z16.7644B2.716R16.983
Z17.0314B3.3878R.665
Z16.5277B3.9062R.665
Z14.4489B8.9247R16.983
Z14.4385B9.6475R.665
Z13.7747B9.9337R.665
Z9.9337B13.7747R16.983
Z9.6475B14.4385R.665
Z8.9247B14.4489R.665
Z3.9062B16.5277R16.983
Z3.3878B17.0314R.665
Z2.716B16.7644R.665
Z-2.716R16.983
Z-3.3878B17.0314R.665
Z-3.9062B16.5277R.665
Z-8.9247B14.4489R16.983
Z-9.6475B14.4385R.665
Z-9.9337B13.7747R.665
Z-13.7747B9.9337R16.983
Z-14.4385B9.6475R.665
Z-14.4489B8.9247R.665
Z-16.5277B3.9062R16.983
Z-17.0314B3.3878R.665
Z-16.7644B2.716R.665
B-2.716R16.983
Z-17.0314B-3.3878R.665
Z-16.5277B-3.9062R.665
Z-14.4489B-8.9247R16.983
Z-14.4385B-9.6475R.665
Z-13.7747B-9.9337R.665
Z-9.9337B-13.7747R16.983
Z-9.6475B-14.4385R.665
Z-8.9247B-14.4489R.665
Z-3.9062B-16.5277R16.983
Z-3.3878B-17.0314R.665
Z-2.716B-16.7644R.665
Z2.716R16.983
Z3.3878B-17.0314R.665
Z3.9062B-16.5277R.665
Z8.9247B-14.4489R16.983
Z9.6475B-14.4385R.665
Z9.9337B-13.7747R.665
Z13.7747B-9.9337R16.983
Z14.4385B-9.6475R.665
Z14.4489B-8.9247R.665
Z16.5277B-3.9062R16.983
Z17.0314B-3.3878R.665
Z16.7644B-2.716R.665
Z16.983B0.R16.983
G2Z17.483B.5R.5
G1Z17.583
G13.1
G0Y4.
M30
Let me know! :cheers:
It's just a part..... cutter still goes round and round....