Hi,
Yesterday, I was testing two hub motors like this, and after reaching the safe upper limit temperature (100 C) both motors went to IDLE. When the error happened, the current output to the motors was 75 amps. My computer wasn’t able to detect the ODrive controller so, I restarted it. I tried to engage the motors again but I got the following errors instead:
In [1]: dump_errors(odrv0)
axis0
axis: Error(s):
ERROR_MOTOR_FAILED
motor: Error(s):
ERROR_DRV_FAULT ERROR_CURRENT_UNSTABLE
encoder: no error
controller: no error
axis1
axis: Error(s):
ERROR_MOTOR_FAILED
motor: Error(s):
ERROR_DRV_FAULT
encoder: no error
controller: no error
I tried to calibrated them again using the values from the hoverboard guide, and I got the following error after running AXIS_STATE_MOTOR_CALIBRATION:
axis1
axis: Error(s):
ERROR_MOTOR_FAILED
ERROR_PHASE_RESISTANCE_OUT_OF_RANGE
encoder: no error
controller: no error
I noticed that the two hub motors have more resistance to spin freely while I was spinning them manually. I lowered the current_limit and requested_current_range from 75 to 25 in the axis 0. I tried again the calibration step and this time, It worked. Now that hub motor was spinning with less resistance. I tried the same operation in axis 1 but I couldn’t make it work with the same operation as axis 0. What I did to make it work was to increase the resistance_calib_max_voltage from 4 to 12. The problem with that is that I’m getting a phase resistance of 0.3995180130004883 instead of 0.14280153810977936 as it was before. The wheel in axis 1 seems to behave weirdly compare with the wheel in axis 0 which has less resistance. Why is that?
These are the parameters I was using before the incident:
axis0
“motor”: {“config”: {“pre_calibrated”: false, “pole_pairs”: 15, “calibration_current”: 10.0, “resistance_calib_max_voltage”: 4.0, “phase_inductance”: 0.0001943952520377934, “phase_resistance”: 0.16325418651103973, “direction”: 1, “motor_type”: 0, “current_lim”: 75.0, “current_lim_tolerance”: 2.0, “inverter_temp_limit_lower”: 100.0, “inverter_temp_limit_upper”: 120.0, “requested_current_range”: 75.0, “current_control_bandwidth”: 100.0}}, “controller”: {“config”: {“control_mode”: 2, “pos_gain”: 0.0, “vel_gain”: 1.0, “vel_integrator_gain”: 3.5, “vel_limit”: 800.0, “vel_limit_tolerance”: 1.2000000476837158, “vel_ramp_rate”: 10000.0, “setpoints_in_cpr”: false}}axis1
“motor”: {“config”: {“pre_calibrated”: true, “pole_pairs”: 15, “calibration_current”: 10.0, “resistance_calib_max_voltage”: 4.0, “phase_inductance”: 0.00017962828860618174, “phase_resistance”: 0.14280153810977936, “direction”: 1, “motor_type”: 0, “current_lim”: 75.0, “current_lim_tolerance”: 2.0, “inverter_temp_limit_lower”: 100.0, “inverter_temp_limit_upper”: 120.0, “requested_current_range”: 75.0, “current_control_bandwidth”: 100.0}}, “controller”: {“config”: {“control_mode”: 2, “pos_gain”: 0.0, “vel_gain”: 4.0, “vel_integrator_gain”: 1.5, “vel_limit”: 800.0, “vel_limit_tolerance”: 1.2000000476837158, “vel_ramp_rate”: 10000.0, “setpoints_in_cpr”: false}},
These are the parameters after the changes I did:
axis0
“motor”: {“config”: {“pre_calibrated”: true, “pole_pairs”: 15, “calibration_current”: 10.0, “resistance_calib_max_voltage”: 4.0, “phase_inductance”: 0.00018229673150926828, “phase_resistance”: 0.1471279412508011, “direction”: 1, “motor_type”: 0, “current_lim”: 25.0, “current_lim_tolerance”: 2.0, “inverter_temp_limit_lower”: 100.0, “inverter_temp_limit_upper”: 120.0, “requested_current_range”: 25.0, “current_control_bandwidth”: 100.0}}, “controller”: {“config”: {“control_mode”: 2, “pos_gain”: 1.0, “vel_gain”: 0.019999999552965164, “vel_integrator_gain”: 0.10000000149011612, “vel_limit”: 1000.0, “vel_limit_tolerance”: 1.2000000476837158, “vel_ramp_rate”: 10000.0, “setpoints_in_cpr”: false}}axis1
“motor”: {“config”: {“pre_calibrated”: true, “pole_pairs”: 15, “calibration_current”: 10.0, “resistance_calib_max_voltage”: 12.0, “phase_inductance”: 0.00012091038661310449, “phase_resistance”: 0.413774311542511, “direction”: 1, “motor_type”: 0, “current_lim”: 25.0, “current_lim_tolerance”: 2.0, “inverter_temp_limit_lower”: 100.0, “inverter_temp_limit_upper”: 120.0, “requested_current_range”: 25.0, “current_control_bandwidth”: 100.0}}, “controller”: {“config”: {“control_mode”: 2, “pos_gain”: 1.0, “vel_gain”: 0.019999999552965164, “vel_integrator_gain”: 0.10000000149011612, “vel_limit”: 1000.0, “vel_limit_tolerance”: 1.2000000476837158, “vel_ramp_rate”: 10000.0, “setpoints_in_cpr”: false}}