I have just gotten my ODrives working with my scooter hub motors after having to flash them with an STLink to get them up to the latest firmware.
I can calibrate the motor and hall effect encoder and control the speed of the motor in closed loop mode.
What I am not understanding is why at lower speeds even when I stall out the motor the current and torque stays low. When running at a low speed at 30V input the current will drop from 130mA to 100mA when I stall the motor. This is not what I would expect for a closed loop motor controller. At higher speed when I try to stall the motor the current drain will raise to over 3A (my power supply’s limit).
I have tried to figure out the poles and encoder settings, but I am not confident I have them right. My suspicion is that this has something to do with my problem.
Advice would be appreciated.
In : odrv0.axis1.config Out: startup_motor_calibration = False (bool) startup_encoder_index_search = False (bool) startup_encoder_offset_calibration = False (bool) startup_closed_loop_control = True (bool) startup_sensorless_control = False (bool) enable_step_dir = False (bool) counts_per_step = 2.0 (float) ramp_up_time = 0.4000000059604645 (float) ramp_up_distance = 12.566370964050293 (float) spin_up_current = 10.0 (float) spin_up_acceleration = 400.0 (float) spin_up_target_vel = 400.0 (float) In : odrv0.axis1.motor Out: error = 0x0000 (int) armed_state = 3 (int) is_calibrated = True (bool) current_meas_phB = 0.2699102759361267 (float) current_meas_phC = 0.29183363914489746 (float) DC_calib_phB = -0.5921880602836609 (float) DC_calib_phC = -0.5132480263710022 (float) phase_current_rev_gain = 0.012500000186264515 (float) current_control: p_gain = 0.021729597821831703 (float) i_gain = 20.42594337463379 (float) v_current_control_integral_d = 0.006775654852390289 (float) v_current_control_integral_q = 1.9460315704345703 (float) Ibus = 0.05689043551683426 (float) final_v_alpha = 1.9309014081954956 (float) final_v_beta = 0.03602290526032448 (float) Iq_setpoint = 0.3829110264778137 (float) Iq_measured = 0.43184879422187805 (float) max_allowed_current = 35.999996185302734 (float) gate_driver: drv_fault = 0 (int) timing_log: TIMING_LOG_GENERAL = 0 (int) TIMING_LOG_ADC_CB_I = 793 (int) TIMING_LOG_ADC_CB_DC = 11301 (int) TIMING_LOG_MEAS_R = 0 (int) TIMING_LOG_MEAS_L = 0 (int) TIMING_LOG_ENC_CALIB = 0 (int) TIMING_LOG_IDX_SEARCH = 0 (int) TIMING_LOG_FOC_VOLTAGE = 0 (int) TIMING_LOG_FOC_CURRENT = 4751 (int) config: pre_calibrated = True (bool) pole_pairs = 20 (int) calibration_current = 10.0 (float) resistance_calib_max_voltage = 4.0 (float) phase_inductance = 0.00021729597938247025 (float) phase_resistance = 0.20425942540168762 (float) direction = 1 (int) motor_type = 0 (int) current_lim = 10.0 (float) requested_current_range = 25.0 (float) current_control_bandwidth = 100.0 (float) set_current_control_bandwidth(current_control_bandwidth: float)
In : odrv0.axis1.encoder Out: error = 0x0000 (int) is_ready = True (bool) index_found = False (bool) shadow_count = 96759 (int) count_in_cpr = 39 (int) offset = 142 (int) interpolation = 0.5380810499191284 (float) phase = -0.9696226119995117 (float) pos_estimate = 96759.875 (float) pos_cpr = 39.81002426147461 (float) hall_state = 6 (int) pll_vel = 103.1333236694336 (float) config: mode = 1 (int) use_index = False (bool) pre_calibrated = True (bool) idx_search_speed = 10.0 (float) cpr = 120 (int) offset = 142 (int) offset_float = 0.5390880703926086 (float) bandwidth = 100.0 (float) calib_range = 0.019999999552965164 (float)