Negative Number of Pole Pairs in BLDC Motor?

Hi and welcome @squirrelydan ,

A few comments while I think about what might be going on and look at the code…

  • the motor is expected to get a little warm, it depends how quickly :smiley:
  • if you keep the voltage_limit low, then you should be safe. Even better, set the power supply to 5 or 6V
  • switching the motor’s terminals will only change its direction. Any motor phase can be connected to any driver output, it does not matter.
  • I would expect “detents” at low velocity - after all, the motor only has 1PP - so you would expect significant cogging

Let me look at the code and see what -1 is doing when you pass it as the number of PP. May I ask in the meantime, are you using the motor’s hall sensors, or running in open loop mode?

[edit[

In terms of open-loop mode in sine modulation, it seems choosing a negative pole-count would simply change the electrical angle which the open loop is setting - X rad would become 2π-X rad

In terms of closed loop mode, it looks like it would reverse the direction of rotation…

Weird that it doesn’t make things blow up completely, I don’t think negative pole counts were ever intended to be used.

As for why it would run more smoothly, I can’t really see any reason for that from my brief look into the code around this. Are you sure you weren’t just running it more quickly?