Our question is:
Can hooverboard motors be used with standard issue rotary encoder seen below and in Odrive setup guide? We get error = 0x0002 (int) when checking encoder and wheel only calibrates in one direction. We don’t know why yet. Do you?
Our set up method with 48V Odrive v3.5 followed:
We also tried in odrivetool utility to change from hall sensors to rotary encoders with
odrv0.axis0.encoder.config.mode = ENCODER_MODE_INCREMENTAL
The pivot because Hall sensor cpr were too low at 90 counts per rev. However crude, Halls worked ok on both motors. At low speeds low rez halls often produced hunting during static rover position test after right turns. We would like to upgrade to rotary method but not able to get pass calibration for .pos or .vel control test let alone .py scripts for rover path(s).
-Hooverboard motors have 15 pole pairs
-Rotary encoders have 2400 cpr however we have 3D printed planetary gear set to couple rotary shaft with inside of wheel itself as wheel shaft is not accessible. The ratio of inside wall of 10" wheel : rotary encoder shaft is 32:8.
With this gear reduction cpr input into Odrivetool:
odrv0.axis0.encoder.config.cpr = 600
600 pulse per/rev * 4 =2400/(32/8) = 600
This is valid or was there a mistake with cpr setting before Calibration?
odrv0.axis0.requested_state = AXIS_STATE_MOTOR_CALIBRATION
odrv0.axis0.requested_state = AXIS_STATE_ENCODER_OFFSET_CALIBRATION
count_in_cpr = 352 (int)
pos_cpr = 352.02496337890625 (float)
error = 0x0002 (int)
phase = -1.178095817565918 (float)
index_found = False (bool)
offset_float = 0.0 (float)
use_index = False (bool)
pre_calibrated = False (bool)
idx_search_speed = 10.0 (float)
calib_range = 0.019999999552965164 (float)
bandwidth = 100.0 (float)
zero_count_on_find_idx = True (bool)
offset = 0 (int)
mode = 0 (int)
cpr = 600 (int)
is_ready = False (bool)
shadow_count = 5152 (int)
hall_state = 7 (int)
interpolation = 0.5 (float)
vel_estimate = 0.0 (float)
pos_estimate = 5152.0048828125 (float)
No filter cap are connected to encoder inputs on Odrive controller and all 3.3K pull ups installed.
Thank you kindly for any insights and feedback. We would very much like to get Bucky::Liner up again.