cancel
Showing results for 
Search instead for 
Did you mean: 

How to swap motor phases at runtime in MCSDK Firmware?

StefanH1
Associate II

We are using MCSDK 6.4.0 in Position Mode with a 3-Phase Motor with quadrature Encoder (only A+B phases, no Z Pin).

How can the motor phases be swapped at runtime in Software (U,V,W -> V,U,W), e.g. when the motor is connector is wired in the opposite direction (but the motor encoder is wired correctly)?

I know that i can set up the PWM Outputs in MC Workbench (as well as swap encoder pins), but i need a solution that can configure this at runtime without rebuilding the Project. 


I could not find a function for that (just feeding an inverted Position to MCI_ExecPositionCommand() does not take into account that the motor encoder is wired for an opposite direction as the motor phases).

If this is currently not possible, can you add this feature in a future release?

1 ACCEPTED SOLUTION

Accepted Solutions
GMA
ST Employee

Hello @StefanH1,

Thank you for your continued interest in our products.
We put significant effort into developing the best solutions we can provide. However, the current topology is considered static, and there are no plans to manage dynamic topology configuration.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA

View solution in original post

1 REPLY 1
GMA
ST Employee

Hello @StefanH1,

Thank you for your continued interest in our products.
We put significant effort into developing the best solutions we can provide. However, the current topology is considered static, and there are no plans to manage dynamic topology configuration.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA