Brake resistor and decel voltage/current


#1

I use LiFePo cells from electronic vehicle for my hoverboard motors. The batteries are far from ideal state but they work yet. To avoid any catastrophic damage of cells I would like to measure the voltage and current going to the batteries during deceleration of motors.

  1. Are there any variables which I can read from oDrive?

  2. Currently I have 4.4Ohm brake resistor connected to oDrive. Is it more safe to use brake resistor even if the power coming form batteries? Or it is absolutely unnecessary?

  3. What measures or calculations should I take into consideration in this situation

Thanks for the help in advance!


#2

Hi James,

You can monitor the voltage at odrv0.vbus_voltage and the current drawn (regen is negative) for each axis on odrv0.axis0.motor.current_control.Ibus. You can sum the Ibus for each axis to get the total.

If you hook up a brake resistor and give ODrive the correct setting (odrv0.config.brake_resistance), it will dump ALL regen current into the resistor, and send none to the battery. If you do not plug in the resistor and set odrv0.config.brake_resistance = 0, it will regen all. If you hook it up and you set it to half the actual value, it will dump half and regen the other half.