Motor stall in closed loop

Hello! I have some troubles with 10 pole pair BLDC motor. In open loop velocity mode (where input voltage and electrical angle changing) motor spins very good. But in velocity closed loop with voltage control, motor start moving slowly and stall in random position (at this moment voltage.q is maximum allowed voltage), electrical angle is measured correctly. Why motor doesnt move with input voltage value? Thanks!


In order for the motor to work correctly in a closed loop, you need to tune the motor. Change your PID values and your motor will work. It is always recommended to start from low values for tunning.

Also, I will recommend going to the documents section you will get a full explanation there.

Many thanks
Moid Khan


Thanks for response! I set velocity PID regulator to “soft” values and I can see ramp of regulator output and also ramp of voltage.q value. motor start to move for some degrees and when it reach voltage limit, stop and hold position. As I have understood, according to electrical angle of motor voltage.q value applied to phases, and while moving to another electrical angle voltage on phases changes, but when motor is stopped, applied voltages on phases can’t move motor. I use space vector modulation, maybe I need to use another type of modulation? But In openloop mode everything good…

In my limited experience, sorry to say so but there are a thousand things that could be off here. The only advice with such limited information that has value is to track the operation of the whole system all the way through. If open loop is good that’s one stage, the next is to print out the sensor values and make sure it’s linear with the rotation and error free. Then you have to get the code to read and set the electrical angle repeatedly working. There are all kinds of things like errors due to code propagation delays that can cause complications especially at higher speed, but get it working at lower speed and then speed it up.