The unexpected mistakes brought about by the first control

I have two motors with AS5047D encoders but I dont want to burn and verify the encoders’ OTP memory for obtaining the absolute zero angle.As a result,I must pose them into the position I wanted before odrive initialization.Everything seems nothing warning until the state control sent ,which is purposed to keep the motor in an angle with perfectly PID parameter. One motor did the clockwise angle while the other did the anti-clockwise.Of course this entire process happens in a split second cause the state control command was sent instantly in loop as soon as the power is on.

At first I think maybe one encoder was on backward so I monitor the counter of the encoder while push the motor on the same direction.The value of the counter was incremented as I push it on the directong of anti-clockwise ,same situation on the other.In a word, the two encoders perfectly installed.

Then I sent a same control command to two odrives and they rotate the same corresponding angle on the basis of the wrong original angle.

I have no idea for how the odrive initializas and processes the first state control command , and how it set up its absoluly coordinate system.

Thanks for your answer

Are these SPI absolute encoders or incremental encoders?

I’m very happy to get your answer!

It would be an absolute encoders if I burn and verify its OTP memory ,which would never change from then on.But now it would set its count to zero when it is on, nothing to do with angle.

However, I have solve this problem by interchanging lines of two three-phase output ports which on the circuit board where I control two motors.The way to change the direction of the encoder is flip along roll angle but not the yaw angle

Now I am thinking about the difference between interchanging lines of two three-phase output ports, and interchanging lines of only two phase of each three-phase output ports, tough it looks like no difference,changing the direction of each motor.

You can swap the A and B lines of the encoder output to change the direction of the motor

OH, I didn’t find such a simple way.Thank you!