Dc_max_negative_current without brake resistor?

Hello,

I have inherited a project that uses a few odrives that was developed about 1.5 years ago on firmware 0.4

I’m trying to transition the code to work with the latest 0.5.4 firmware but am having a lot of problems with that. I’ve gone through the migration guide and updated all the configuration values accordingly. However when I try and run the motor after applying the configuration values it wont even calibrate. It immediately gives me a CONTROLLER_ERROR_OVERSPEED error.

If I use the default values and just change the torque_constant accordingly and change the input mode to trap_traj i can get it to move. however when it gets to decellerating, it stops and gives me a ODRIVE_ERROR_DC_BUS_OVER_REGEN_CURRENT error.

I do not have a break resistor. I understand the point of it, but this setup was up and running fine for about 6 months without one, so am unsure why it wont work anymore now.
If i change the odrv0.config.dc_max_negative_current from -0.0099 to -0.099 it seems to work, but i dont want to test too much in case it harms my power supply.
How can i find out how much (if any) regen current my power supply can handle? (MeanWell HEP-320-36A)

and if i need a brake resistor, how do i know what resistance to use?

thanks for anyone who can help.

Dom

The power supply is more likely to have a max output voltage and/or overvoltage trip, rather than a max regen current.
If you put the brake resistor back in circuit, you can use the overvoltage_ramp settings to clamp the bus to a reasonable voltage for the power supply, say 40V. This way it will never use the resistor unless it has to, to protect itself and the power supply.
If you set overvoltage_ramp_start to 36.5 and overvoltage_ramp_end to 40, then ODrive will gradually increase the brake resistor PWM, starting at 36.5V and reaching 100% at 40V.
You can use any resistor between 0.1 Ohm and 10 Ohm with a sufficient power rating. The default is 2 Ohm, 50W.

2 Likes

Thank you for your reply. I’ve ordered a power resistor and will give that a try as soon as it arrives.
thanks