Thanks for the help, but wow am I lost with that code. I'm new to this. When I did the retrofit with ah-ha, they supplied me with the script I attached. I gave them the sequence of the turret change, and the wire voltage for the encoder and they wrote the code for me. I thought I was following what they did, but I don't understand what you sent me. But I'm gonna try do some more reading.
It 's not really an encoder, that is what Hardinge calls it. its more like hall effect switches encased in some resin. there is a magnet that rotates with the turret over the resin. So I'm not sure what state the wires are in between stations. I'll check it when I get a chance. I do know they treated the 8th station differently in there code.
thanks
Art