Help Needed with Tuning ODrive for Precise Position Control on Custom BLDC Setup

Hi everyone,

I’m currently working on a robotics project that involves using ODrive to control a custom-built BLDC motor (with encoder feedback) for a precision linear actuator. I’ve gone through the documentation and several threads on this forum, but I’m still struggling to get consistent, stable performance—especially in position control mode.

Here’s a quick summary of my setup:

  • Motor: Custom 14-pole BLDC motor
  • Power supply: 24V, 20A
  • Encoder: AMT102-V, set to incremental mode
  • ODrive firmware: 0.5.6
  • Control mode: Position control using a Python script over USB

I’ve been able to get the motor calibrated, and I can command movement, but I’m running into significant overshooting and jittering when trying to hold a target position. I’ve tried adjusting the velocity and position gains (both vel_gain, vel_integrator_gain, and pos_gain), but I seem to either get sluggish response or oscillation depending on the values.

A few questions I’m hoping the community can help with:

  1. Is there a best-practice tuning sequence you follow for position mode?
  2. Would using input filtering or setting input_mode to TRAP_TRAJ help in reducing the jitter?
  3. Any known issues when using custom motors with slightly non-standard parameters?

Any advice, tips, or shared experiences would be greatly appreciated. I’m happy to share my current config or a video if that helps in sap abap course in bangalore.

Thanks in advance!

Hi there, thanks for all the information!

Is there a best-practice tuning sequence you follow for position mode?

We have a tuning guide here for v3.6, however it’s a bit rough. We have a better version in the documentation for S1/Pro/Micro here, which will also generally apply to v3.6, as far as the methodology for tuning pos/vel/vel_integrator gains.

Would using input filtering or setting input_mode to TRAP_TRAJ help in reducing the jitter?

I generally recommend using one of those two modes, but they won’t intrinsically help the gains, they’ll just smooth out the motion a bit.

Any known issues when using custom motors with slightly non-standard parameters?

I don’t think so. But what do you mean by “non-standard”?

If you can run odrivetool backup-config config.json and paste the resulting config.json here, I’d be happy to take a look at the ODrive config and see if there’s any issues I can spot. Some pictures and/or videos are also helpful – I always appreciate a bunch of pictures of everything – wiring, encoder mounting, etc.

Other than that, I would recommend trying to follow the tuning guide (only steps 2-8 in ODrivetool, as the GUI doesn’t support v3.6) and see if you’re able to get better response.