Hi guys !
I have an 24V odrive board 3.6 with firmware v0.4.11 and I’m using it with a brushless motor from hobbyking (Turnigy Aerodrive SK3 - 4250-350kv) and a cheap encoder (B015GYY7XU)
I setup my odrive as the documentation suggest:
odrv0.axis0.motor.config:
pre_calibrated = False (bool)
pole_pairs = 7 (int)
calibration_current = 10.0 (float)
resistance_calib_max_voltage = 2.0 (float)
phase_inductance = 2.110511741193477e-05 (float)
phase_resistance = 0.04368022829294205 (float)
direction = -1 (int)
motor_type = 0 (int)
current_lim = 20.0 (float)
current_lim_tolerance = 1.25 (float)
inverter_temp_limit_lower = 100.0 (float)
inverter_temp_limit_upper = 120.0 (float)
requested_current_range = 60.0 (float)
current_control_bandwidth = 1000.0 (float)
odrv0.axis0.controller.config
control_mode = 3 (int)
pos_gain = 20.0 (float)
vel_gain = 0.0005000000237487257 (float)
vel_integrator_gain = 0.0010000000474974513 (float)
vel_limit = 20000.0 (float)
vel_limit_tolerance = 1.2000000476837158 (float)
vel_ramp_rate = 10000.0 (float)
setpoints_in_cpr = False (bool)
odrv0.axis0.encoder.config
mode = 0 (int)
use_index = False (bool)
find_idx_on_lockin_only = False (bool)
pre_calibrated = False (bool)
zero_count_on_find_idx = True (bool)
cpr = 2400 (int)
offset = -1279 (int)
offset_float = 0.1684531271457672 (float)
enable_phase_interpolation = True (bool)
bandwidth = 1000.0 (float)
calib_range = 0.019999999552965164 (float)
calib_scan_distance = 50.26548385620117 (float)
calib_scan_omega = 12.566370964050293 (float)
idx_search_unidirectional = False (bool)
ignore_illegal_hall_state = False (bool)
The full_calibration and the closed_loop_control work just fine. But when I want to move the motor with pos_setpoint, I’m getting this error:
axis0
axis: Error(s):
ERROR_CONTROLLER_FAILED
motor: Error(s):
ERROR_CONTROL_DEADLINE_MISSED
encoder: no error
controller: Error(s):
ERROR_OVERSPEED
I’m trying to figure out what happen for 2 weeks now. I played with a lot of params, try 12V and 24v power supply, change the motor and the encoder (but same ref), try python script instead of odrivetool.
Same result
I have the feeling that the problem come from the encoder (600 ppr so 2400 cpr) because I read
“Usually that error is caused by noise on the index pulse line of the encoders. It gets picked up and triggers an interrupt on repeat.”
But my setup is pretty clean and I don’t understand how there can be noise
Am I missing something ? Any ideas ?
Thanks for your help