Skip to content

updateApproximatePathOrientations method sets orientations of path poses in accordance of 0 rad yaw angle #5424

@CihatAltiparmak

Description

@CihatAltiparmak

Bug report

Required Info:

  • Operating System:
    • nav2_docker
  • Computer:
    • PC
  • ROS2 Version:
    • rolling latest
  • Version or commit hash:
  • DDS implementation:
    • fastrtps

Steps to reproduce issue

The decision as to which direction the path segment will go through is made only by zero rad yaw angled pose. Just send the gool poses everwhere you want and then you will see the truth. For differential drive robots which uses nav2_mppi_controller (enabled use_orienation of Path Align Critic), this may be a little troublesome, controller may act just like crazy.

Expected behavior

The orientations of the smoothed path poses should be set in accordance of robot's current pose's orientation at the beginnging (or user should be able to select this option).

Actual behavior

The orientations of the robot sometimes does not set correctly, which may bring about the controller which consider these orientations applying unfeasible velocity commands.

Here is a video of the bug.

Screencast.from.08-07-2025.01.44.44.AM.webm

Reproduction instructions

Additional information

pt_yaw = tf2::getYaw(path.poses[1].pose.orientation);
this part always will be zero rad yaw if the planner does not set orientations of start pose of the path.

It can be a feature request as well, but IMO, we can fetch the robot's current pose inside smoother and then we can use this robot poses to decide which direction robot should go through. We can make this optional. I am strongly willing to contribute navigation2 project by adding this option if you want. Looking forward to seeing your feedbacks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions