Fixed interface sending faster speed then intended

This commit is contained in:
2025-02-22 16:48:07 +01:00
parent 5887151387
commit fabe02d906

View File

@ -69,8 +69,8 @@ hardware_interface::return_type mg::MgStepperInterface::write(const rclcpp::Time
std::string cmd_left;
std::string cmd_right;
cmd_left = std::to_string(left_wheel_vel_cmd / 2 * M_PI) + " ";
cmd_right = std::to_string(-right_wheel_vel_cmd / 2 * M_PI);
cmd_left = std::to_string(left_wheel_vel_cmd / (2 * M_PI)) + " ";
cmd_right = std::to_string(-right_wheel_vel_cmd / (2 * M_PI));
try {
odrive_serial_interface.Write(cmd_left + cmd_right);