Skip to content

No acceleration limiting in Gazebo diff-drive simulation #255

Description

@147258369ymc

Description

The TurtleBot3 Gazebo simulation allows physically impossible accelerations.
The XL430-W250 Dynamixel motor has a maximum achievable linear acceleration of
approximately 5 m/s² (derived from stall torque and robot mass). However, in
simulation, step changes in cmd_vel produce accelerations exceeding 50 m/s².

This is caused by:

  1. max_wheel_torque in the SDF model set to 20 Nm (actual XL430 stall torque: ~1.4 Nm)
  2. No acceleration rate limiter in the diff-drive plugin

Steps to Reproduce

ros2 launch turtlebot3_gazebo empty_world.launch.py

Send alternating velocity commands rapidly:

ros2 topic pub -r 3 /cmd_vel geometry_msgs/msg/Twist "{linear: {x: 0.22}}"

Then immediately:

ros2 topic pub -r 3 /cmd_vel geometry_msgs/msg/Twist "{linear: {x: -0.22}}"

Monitor odometry and compute acceleration from velocity differences

Observed

Linear acceleration: 55.14 m/s² (11x physical limit)
Angular acceleration: 7194 rad/s² (240x physical limit)

Suggested Fix

  1. Set max_wheel_torque to ~1.4 Nm (XL430-W250 stall torque)
  2. Add acceleration rate limiting in the diff-drive plugin or SDF joint parameters

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions