im setting up a mill turn configuration that uses a horizontal servo driven secondary spindle that doubles as a 4th axis. the horizontal spindle is switched between a spindle and A axis using a swap axis macro. it uses gang turning tools next to the milling head to do both turning and milling operations in the same program using only the mach3 mill profile. ive managed to hack up a fanuc turning post to do everything i want from fusion 360 cam without using an x-z swap on the machine to handle turning code. instead i did the swap in the post, outputting x for z and z for x. arcs no longer work properly, but i just forced it to not use arcs by reducing maximum arc to very small number. everything is working fine except for singe point threading on the horizontal spindle. I already know how to make it happen using a synchronized A, X move. for example, A3600 x10 will do 10 threads at 1mm pitch. its just kind of time consuming to manually write it out for multiple depths, zeroing A at beginning of each pass, etc. It would be nice if i could get a threading cycle from fusion 360 to work properly and not need to manually write it. Or at least a shorter version of writing it. Is there any way to make this work in the mill profile like it does in the lathe profile? Or am i stuck just writing it with the spindle as an axis? If i am stuck doing it as A axis, is there a convenient way to write it? Currently when i cam the threads in fusion, its outputting G32 for threading and it almost works. this is an example of what it gives me for a 3 pass 1mm pitch:

N10 G98 G18
N11 G21
N12 G50 S2800
N13 G53 Z0.


(THREAD1)
N14 T60 M6
N15 G54
N16 G99
N17 G97 S500 M3
N18 G0 Z16.35 X-80.
N19 G0 X-75.
N20 Z6.183
N21 G32 X-0.167 F1.
N22 Z6.35 X0. F1.
N23 G0 Z16.35
N24 X-75.
N25 Z6.017
N26 G32 X-0.333 F1.
N27 Z6.35 X0. F1.
N28 G0 Z16.35
N29 X-75.
N30 Z5.85
N31 G32 X-0.5 F1.
N32 Z6.35 X0. F1.
N33 G0 Z16.35
N34 X-80.


N35 G53 Z0. X0.
N36 M30
%

remember that my x and z is swapped in the post, so x moves are moving along the axis of the horizontal spindle and z is the depth of the thread, also x moves positive toward the chuck. my post is also modified to output in radius mode instead of diameter. Each pass does what its supposed to, it moves in feed per rev as it should, gives a 1mm pitch cut, but the multiple passes dont line up. Is it simply not capable of lining up the multiple passes since its being done in mill profile? the other possibility is the fact that im not giving it an encoder pulse. since my horizontal spindle is a step/dir driven servo, mach3 should always know its exact position without needing the pulse input, but maybe it still wants it to make this work? my dyn4 servo drive is capable of sending an encoder pulse to mach3 if that will help, but it needs a specific cable and more wiring to do it. Ill do it if its likely to fix the issue, but i dont want to bother if its not gonna help. Is this type of cycle just not gonna work in the mill profile?