Motor current VS power supply current

I found this piece of text in the getting started guide:

•The current limit: odrv0.axis0.motor.config.current_lim [A]. The default current limit, for safety reasons, is set to 10A. This is quite weak, and good for making sure the drive is stable. Once you have tuned the drive, you can increase this to 75A to get some performance. Note that above 75A, you must change the current amplifier gains. You do this by requesting a different current range. i.e. for 90A on M0: ‘odrv0.axis0.motor.config.requested_current_range = 90’ [A], then save the configeration and reboot as the gains are written out to the DRV (MOSFET driver) only during startup. ◦Note: The motor current and the current drawn from the power supply is not the same in general. You should not look at the power supply current to see what is going on with the motor current. Ok so tell me how it actually works then…
The current in the motor is only connected to the current in the power supply sometimes and other times it just cycles out of one phase and back in the other. This is what the modulation magnitude is (sometimes people call this duty cycle, but that’s a bit confusing because we use SVM not straight PWM). When the modulation magnitude is 0, the average voltage seen across the motor phases is 0, and the motor current is never connected to the power supply. When the magnitude is 100%, it is always connected, and at 50% it’s connected half the time, and cycled in just the motor half the time.
The largest effect on modulation magnitude is speed. There are other smaller factors, but in general: if the motor is still it’s not unreasonable to have 50A in the motor from 5A on the power supply. When the motor is spinning close to top speed, the power supply current and the motor current will be somewhat close to each other.

My question is, when I set the maximum current, with the command,

odrv0.axis0.motor.config.current_lim [A] 

Is this the maximum current to the motor or is this the maximum current that gets drawn from the power supply?

Also, Is there a way to know what the current to the motor is by knowing the current to the Odrive controller (input current)?

greetings Stijn :wink:

Maximum motor current.

If you know the phase voltage and the current throughput you can calculate the power being sent to the motor. Then the power supply current = motor power / bus voltage.


So if I get this, if I use a smps I can’t set the maximum current higher than the maximum current of the smps eventhough this doesn’t draw the maximum of the smps at low speeds?

Greetings Stijn

You may do that if you’re not using the full power of the SMPS. Do the math in terms of power, then convert to current at the last step.

Okay, thanks for thé advice

Greetings Stijn

how does one find out the phase voltage and current throughput? I have a turnigy sk3 149Kv motor.


Why do you need this?


I’d like to do the power calculations that Wetmelon describe above.

What I learned is that it’s best to just use a lab bench power supply and look at the current while testing and buy a supply that’s capable of dilivering that current because it is very hard to predict the current with the ODrive.

You can calculate motor voltage with your vel limit.


hmm that doesn’t make any sense to me, I don’t even see how that would work. most lab power supplys don’t provide more than 5A unless you get something that is in the hundreds of dollars range. also the power supply I have doesn’t go over 32V. So I couldn’t even test at 48 or 56V.


I bought a dps5020 (AliExpress), this one is able to deliver 50v and 20A, this was addequit for me. And it doesn’t Costa much


1 Like

bonjour ! de quel méthode pour qu’on connaisse la tension de phase et le débit de courant ?

Le principe de conservation de l’énergie, imbécile ! :stuck_out_tongue_winking_eye:

Mechanical power + resistive power ~= input power
Where resistive power is I^2 R in the windings, and mechanical power is Torque * Velocity