ODrive v3.5 Can't calibrate a motor


#1

I’ve just received a new 24v ODrive v3.5 and have connected it to a MB082GA210 (http://www.exmek.com/uploads/MB82GA.pdf)
PSU is currently 24v 15A

I’m trying to run a full calibration sequence but I’m getting an axis error of 65 and motor error 17
If I understand correctly that is pretty much an issue with - ERROR_PHASE_RESISTANCE_OUT_OF_RANGE but resistances are definitely under 1ohm so not sure why it would be a problem.
No beeps no movement at all on the motor.

I’ve tried following some of the other advice I’ve found on this forum but nothing has worked so far. Any help would be appreciated


#2

Worked it out
Needed to change -
resistance_calib_max_voltage = 6
calibration_current = 0.5
motor_type = 2
now it works

EDIT:
Thought I should add that I needed to change controller.config.vel_gain to get it not to vibrate on while in closed loop mode


#3

I would not suggest motor_type = 2, unless you will only spin very slowly.

I would suggest:

  • resistance_calib_max_voltage = 6
  • calibration_current = 5
  • motor_type = 0

#4

I tried a number of combinations without changing motor_type to 2 but either got the errors
ERROR_MODULATION_MAGNITUDE with
ERROR_CONTROL_DEADLINE_MISSED
OR
ERROR_PHASE_INDUCTANCE_OUT_OF_RANGE

With

  • resistance_calib_max_voltage = 6
  • calibration_current = 5
  • motor_type = 0

The motor moved about an 1/8 of a turn then the o-drive beeped.
In [369]: hex(odrv0.axis1.error)
Out[369]: ‘0x41’

In [370]: hex(odrv0.axis1.motor.error)
Out[370]: ‘0x2’

In [371]: odrv0.axis1.motor
Out[371]:
error = 0x0002 (int)
armed_state = 0 (int)
is_calibrated = False (bool)
current_meas_phB = -0.07162219285964966 (float)
current_meas_phC = 0.030228018760681152 (float)
DC_calib_phB = -0.7744964957237244 (float)
DC_calib_phC = -1.762320876121521 (float)
phase_current_rev_gain = 0.02500000037252903 (float)
current_control:
  p_gain = 0.0 (float)
  i_gain = nan (float)
  v_current_control_integral_d = 0.0 (float)
  v_current_control_integral_q = 0.0 (float)
  Ibus = 0.0 (float)
  final_v_alpha = 0.0 (float)
  final_v_beta = 0.0 (float)
  Iq_setpoint = 0.0 (float)
  Iq_measured = 0.0 (float)
  max_allowed_current = 71.99999237060547 (float)
gate_driver:
  drv_fault = 0 (int)
timing_log:
  TIMING_LOG_GENERAL = 0 (int)
  TIMING_LOG_ADC_CB_I = 809 (int)
  TIMING_LOG_ADC_CB_DC = 11327 (int)
  TIMING_LOG_MEAS_R = 3613 (int)
  TIMING_LOG_MEAS_L = 3601 (int)
  TIMING_LOG_ENC_CALIB = 0 (int)
  TIMING_LOG_IDX_SEARCH = 0 (int)
  TIMING_LOG_FOC_VOLTAGE = 3539 (int)
  TIMING_LOG_FOC_CURRENT = 0 (int)
config:
  pre_calibrated = False (bool)
  pole_pairs = 4 (int)
  calibration_current = 5.0 (float)
  resistance_calib_max_voltage = 6.0 (float)
  phase_inductance = 0.0009335419745184481 (float)
  phase_resistance = 0.2689632773399353 (float)
  direction = 1 (int)
  motor_type = 0 (int)
  current_lim = 10.0 (float)
  requested_current_range = 70.0 (float)
  current_control_bandwidth = 1000.0 (float)
set_current_control_bandwidth(current_control_bandwidth: float)

#5

We recently fixed an issue where we arbitrarily called any measured inductance over 500uH to be too high. We fixed that in firmware version 0.4.3. Can you try flashing that on?


#6

Sorry I meant to respond earlier…0.4.3 is a success but I couldn’t update via the odrivetool as it gave an error.