With the current shunts that ship with ODrive, there is about 50-100mA RMS of noise on the current sensing. This is simply because 50mA through 500 micro-ohm is a very very tiny voltage, and noise creeps in. This means that with a reactive current controller, there will also be this much noise in the output current. On a motor with a low rated current, this means that the torque noise is large compared to rated torque, which gives a qualitatively poor acoustic and maybe also vibration performance.
To make sure you are getting the best results, make sure you request a range lower than 35A. You need to the save configuration and reboot to take effect.
If you want less acoustic noise beyond that, you can either reduce the current controller bandwidth with odrv0.axis0.motor.set_current_control_bandwidth(float bandwidth)
, (default: 1000 [1/s]
). The downside is reduced available bandwidth for velocity and position control. This will update the current control P and I gains.
If you want to use a lower current range than 35A and hence get better resolution, you need to change the shunts. Pick the rang you would like (I_Range
), and choose a current sense amplifier gain (10, 20, 40, 80). For low currents, I’d suggest to pick 10. Then you can compute the required shunt resistor value:
R = 1.6 * 0.9 / (Gain * I_Range)
. Pick the next lower available value, I personally like this series of resistors, but anything in the same package will do.