In Velocity Control the velocity dies off and doesn't start again


I’m having some issues with my new ODrive setup where I get the motor setup and working and command a velocity but it quickly dies off to zero and then doesn’t start again without resetting the ODrive controller.

I start by running the full calibration with completes without error. Then I set to velocity control mode and set a velocity (like 5) and after a short amount of time (sometimes a few seconds and sometimes up to a minute) before it then just slows down to a stop. I don’t know where to start diagnosing this issue. I’ve tried position control and it works but it’s not accurate (sometimes it reaches its position and sometimes it gets close but just stops before it reaches the final position). I’m less concerned about getting position control working properly because the end goal is to get velocity control working but if resolving the position control issue solves the velocity control issue then I’m all ears.

ODrive controller v3.6 56V
ODrive motor D6374 150KV
CUI 8192 encoder with cable

Not sure what information is useful so feel free to respond with any questions about my setup. Happy to take pictures/videos and show what’s happening. Thanks!

1 Like

Here’s a screenshot from the GUI showing how when the position_estimate is not even close to the input_pos or pos_setpoint.

Here’s a screenshot from the GUI showing how when the velocity_estimate is not even close to the input_vel or vel_setpoint.

I am still pretty new here, so not sure I will be of much help :slight_smile: Some more experienced members will soon help you out, I’m sure.

But have you properly tuned your motor yet?

Thanks for the quick reply.

The hard part about the tuning process is, I don’t have the ability to tune properly when it only runs in velocity mode for a few moments before stopping itself. I initially used the GUI Wizard to set up the motor which allowed me to calibrate but that’s the extent of what I’ve been able to do. If there are any recommendations for a typical properly tuned setup that I could blindly assign, that would be awesome. Maybe that way I could get something that mostly works and then tune it the rest of the way when I can reliably move the motor.

have you followed the steps on the bottom of this page?

Yeah, that’s what I was trying when trying to tune it but it’s really subjective. I can try that again and see if it improves it at all.

Just tried going through the tuning process again but like I said before, I really can’t accurately get good numbers because no matter what numbers I set, it doesn’t want to move. I’ve tried setting the current limits higher (30+ amps) but it just sits there.

What is odd is that whenever it gets into these “stuck” states that I’ve been referring to, I can always recover motion by going into idle and doing the full calibration and then I have velocity control again (or at least for a short amount of time until it gets “stuck” again).

Hi Nathaniel,

I just posted about this issue and also solved it. Make sure to enable your brake resistor. This sounds like the same issue I was having.

odrv0.config.enable_brake_resistor = True

Also for future reference, anytime something stops working check for errors on your motors and hall sensors.


Finally you can dump all errors with:

This should give you more information. Likely you have the same error I did which was:

Try this and see if it works for you.


Thanks for the ideas. I do already have the brake resistor enabled. And when it gets “stuck” it doesn’t actually cause any errors. It stays in closed loop control the whole time and is still actively trying to rotate.

Any other ideas?

FYI, we ended up deciding the encoder was the problem. Switching encoders to an identical AMT102 fixed it, iirc.

1 Like

Switching out the encoder resolved the issue. Thanks for all the help!