Well, the PMSM motor spins. Good torque control in both directions. I love that you just set Id to zero, and let the magnets do the work. The power factor is almost 1. It's nice and smooth too, and makes a cool sound. I haven't messed with the field weakening yet, but I'll try it.
I also need to get a video of trying to find the rotor flux position for the first time. It worked beautifully. I set Id to 5 amps, and Iq to 0. Since Iq is what is supposed to cause the rotation, and Id is supposed to cause the field strength, the motor shouldn't turn at all. But if you don't know the true rotor flux angle (which for all eternity is a fixed offset), the motor will spin if you guessed wrong. So, I let the guesses run from 0 up to 1023 "degrees" (one complete electrical revolution), and you actually see the dang motor spin one way, gradually slow down, stop (that's the sweet spot!), and turn around and go the other way. So, then I just read what offset it was when the motor was in the middle of its stopping, and then from that point on, commanded Id to be zero, and Iq to be throttle position. Then the dang thing just works! And the response is fast! Bang reverse! Bang forward! Now move super slow! I command you, Torque! haha. It doesn't lose sync like was able to happen with the ACIM at first.
|