I have a working rotary carousel ATC and have a customized M6 macro based on a popular macro floating around the forum here. I've been using it for some time so it's a proven system, however I want to find out if I can use index pin/rotary encoder in order to accurately position the spindle for tool changes. After gutting and rebuilding the tool changer electronics I lost any ability to align the spindle with the changer. For some time I have been using the spindle without drive dogs as it's just a light duty machine and at first I didn't have any particular need for alignment, but I would like to re-visit that concept. Reason is that the spring clips in the carousel don't hold the toolholders very well unless the holder is aligned with the drive keys; I've tried various mechanical workarounds but nothing works reliably at all times.
Setup: I have a belt driven spindle with a 3 phase AC motor drive with VFD. Index pin on spindle and rotary encoder on motor shaft, I can do rigid tapping successfully so integration with UCCNC already works well. Can the index and encoder be read in the M6 macro in order to get alignment? My thinking is once alignment is achieved I can fire a braking solenoid against the belt pulley to hold it in place for the change. I have doubts that the index signal will be accurate enough by itself but if I can read the encoder signals for the correct number of counts after the index signal (similar to rigid tapping) that may give me the accuracy I need.
Dan