Is this something that just occurred or a recent system hook up?
If I decipher your post right, if you reverse the phasing of the X axis it runs OK, but the indicated direction is wrong, if so, then you have the phasing between the encoder and the command signal reversed, which means they BOTH have to be reversed OR, if the control allows it, once it is running without fault, reverse the axis direction by setting or parameter?
What control is this?
BTW, if you want to swap the encoder phasing, you can do it by just reversing the A & A- OR the B and B-.
Al.
CNC, Mechatronics Integration and Custom Machine Design
“Logic will get you from A to B. Imagination will take you everywhere.”
Albert E.