Another post here!
Similar to my post about absolute homing, I am able to message my servo drives using serial commands and configure them to have different gear ratios to the Step/Dir input from Mach 4. I have also added a relay in my control cabinet (tied to an output from Mach 4) which physically disconnects the Z axis drive from the Smoothstepper Step/Dir signals and connects it to the encoder output of my spindle motor drive. Using this method, I can cause the Z axis to follow the exact motion generated by my spindle in a true closed loop fashion. By changing the gear ratio at the drive, I can program the threads per inch of the tap that I am using.
With this, I hope to be able to accomplish rigid tapping using the spindle encoder to drive axis motion. This all happens after the smoothstepper and does not rely on any Mach 4 controlled hardware.
My question is, can I modify Mach 4's behavior to a G84 call, or do I need to create a custom M function? Will these functions wait for my code to complete before continuing through the rest of the G code?