We are experiencing ERROR_BRAKE_RESISTOR_DISARMED when trying to decelerate our motor too quickly. Our setup:
Motor setup: A 315g object is suspended vertically from a 4cm diameter spool. We are using a
Dual shaft motor - D5312s 330KV Odrive motor.
Power supply: We tested both a 24V DC power supply and a 24V Li-Po battery.
Brake resistor tests: We tried 1Ω, 0.5Ω, and 0.25Ω resistors, but the maximum deceleration before triggering the error didn’t change much.
Observations:
Going up is fine up from 0 turn/s to 40 turns/s at 85 turns/s².
Going down, if we try to slow from 10 turns/s to 0 turns/s at 15 turns/s², we get ERROR_BRAKE_RESISTOR_DISARMED.
Brake resistor flag: brake_resistor_saturated is turned on.
Configuration: Full settings are available here: ODrive S1 Config : O_drive_configuration - Google Docs
Is there a way to prevent this error while maintaining fast deceleration?
Is the current sent to the brake resistor limited by abs(dc_max_negative_current) ?
It seems like we didn’t define max_regen_current in our system, but on GitHub code this value is initialized to 0,0f which is coherent with our power supply not being able to dissipate negative currents.
We will be able to do some test tomorrow, we will try with a 0.1ohm resistance, do you think of other test to solve this issue ?
We noticed that the error was due to overvoltage. To temporarily fix the issue, we:
Added a 10 mF capacitor in parallel of the power supply.
Increased the upper voltage limit to 32V.
This solved the problem, but is it normal for the voltage to rise like this?
After further testing, we found that the ODrive is sending current back to the power supply during deceleration. Here is a picture showing the current flow from the power supply and the additional capacitor to the ODrive.
We measured a minimum of -2.8A (with a scaling factor of -0.02 on the readings).
Given that we configured no negative current, is this behavior normal?
How can we prevent the ODrive from sending so much current back to the power supply ?
This typically will happen if either your brake resistor resistance is too low for the amount of current being regenerated (e.g. Vbus/Rbrake < Iregen), or if your actual brake resistor resistance is higher than the value specified to the ODrive; this is typically caused by poor wiring connections, or the brake resistor being a bit out of tolerance. If you’re confident you’re not regenerating more current than the brake resistor can dissipate (Vbus/Rbrake > Iregen), then you can try increasing the stated resistance value to the S1 by a bit (e.g. specifying value of 2.1 for the brake resistance, if you only have a 2 ohm brake resistor).
The first issue is unlikely in our case, since our brake resistor should be able to handle the regenerated current. However, the second point about the actual resistance being higher than the configured value makes sense since we use a 0.1 ohm resistor and could explain the issue. We will test this as soon as possible by slightly increasing the configured brake resistance and report back on the results.
Okay! Note the S1 brake bridge is only rated to about 80A max – a 24V supply with a 0.1 ohm resistor would result in 240A, so I’d recommend using a 24/80 = 0.3 ohm resistor max – I think 0.25 ohm should be fine.
Okay, thank you for the warning, we used a 0.1ohm for test purposes because it was the minimum resistance value we read online but from now on we will use the 0.5ohm provided resistance.