zhaohe 1 year ago
parent
commit
9de9f8940b
  1. 3
      components/step_motor_ctrl_module/tmc51x0_motor.cpp

3
components/step_motor_ctrl_module/tmc51x0_motor.cpp

@ -713,6 +713,9 @@ int32_t TMC51X0Motor::motor_get_subdevice_reg(int32_t reg_addr, int32_t* reg_val
}
int32_t TMC51X0Motor::motor_read_enc_val(int32_t* enc_val) {
if (m_motor_enc_resolution == 0) {
return motor_read_pos(enc_val);
}
inverse_kinematics(m_stepM1->getENCVAL(), *enc_val);
return 0;
}

Loading…
Cancel
Save