Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ERROR] [1711077612.076564900] [controller_server]: Failed to make progress #14

Closed
ayakasakurai0213 opened this issue Mar 28, 2024 · 3 comments

Comments

@ayakasakurai0213
Copy link

ayakasakurai0213 commented Mar 28, 2024

This issue is a rewrite of #12 and #13 .

I am running actual robot of HSR and trying navigation according to hsrb_rosnav_config.

HSR can plan the path, but cannot move independently.

Here are the details.

I am running HSR in the following environment:
Ubuntu 20.04.6 LTS
ROS foxy

I built the environment according to the section of Actual Robot in hsr_ros2_doc.

I run navigation is done in the following steps.

  1. bringup HSR
  2. launch Rviz
  3. autonomous movement

First, power on HSR and stop docker on ROS1.
Then bringup HSR by entering the following command:

ros2 launch hsrb_bringup hsrb.launch.py

Next, launch Rviz by entering the following command:

ros2 launch hsrb_rosnav_config nav_rviz.launch.py

We create a launch file nav_rviz.launch.py in the hsrb_rosnav_config package.

Contents of nav_rviz.launch.py:
import os
from ament_index_python.packages import get_package_share_directory
import launch
from launch import LaunchDescription
from launch.substitutions import (
    Command,
    FindExecutable,
    LaunchConfiguration,
    PathJoinSubstitution,
)
from launch_ros.substitutions import FindPackageShare

from launch_ros.actions import Node
from launch.actions import DeclareLaunchArgument

from launch.substitutions import LaunchConfiguration
from launch.actions import IncludeLaunchDescription
from launch.launch_description_sources import PythonLaunchDescriptionSource

def declare_arguments():
    declared_arguments = []
    declared_arguments.append(
        DeclareLaunchArgument('description_package',
                              default_value='hsrb_description',
                              description='Description package with robot URDF/xacro files.'))
    declared_arguments.append(
        DeclareLaunchArgument('description_file',
                              default_value='hsrb4s.urdf.xacro',
                              description='URDF/XACRO description file with the robot.'))
    return declared_arguments

def generate_launch_description():

    package_dir = get_package_share_directory("hsrb_rosnav_config")
    
    description_package = LaunchConfiguration('description_package')
    description_file = LaunchConfiguration('description_file')
    robot_description_content = Command(
        [PathJoinSubstitution([FindExecutable(name='xacro')]), 
         ' ', 
         PathJoinSubstitution([FindPackageShare(description_package), 
                               'robots', 
                               description_file])
         ])
    robot_description = {'robot_description': robot_description_content}
    
    use_sim_time = LaunchConfiguration('use_sim_time', default='true')
    rviz = os.path.join(package_dir, "rviz" , "hsr_navigation.rviz")
    ekf_path = os.path.join(package_dir, "config", 'nav2_params.yaml')


    return LaunchDescription(declare_arguments() + [
        launch.actions.DeclareLaunchArgument(name='gui', default_value='True',
                                             description='Flag to enable joint_state_publisher_gui'),

        Node(
            package='robot_localization',
            executable='ekf_node',
            name='ekf_filter_node',
            output='screen',
            parameters=[ekf_path, {'use_sim_time': use_sim_time}]
            ),

        Node(
            package='rviz2',
            executable='rviz2',
            name='rviz2',
            arguments=['-d', rviz],
            parameters=[{'use_sim_time': use_sim_time}],
            output='screen'),
    ])

Then, launch the program of autonomous movement by entering the following command:

ros2 launch hsrb_rosnav_config navigation_launch.py map:=/full/path/to/map.yaml

After that, specify 2D Pose Estimate and Navigation2 Goal.

State after specify Navigation2 Goal:

  • HSR does not move independently after path planning
  • The error is displayed
Contents of the error:

[controller_server-1] [INFO] [1711077602.065240930] [local_costmap.local_costmap]: Received request to clear entirely the local_costmap
[controller_server-1] [INFO] [1711077602.076080318] [controller_server]: Received a goal, begin computing control effort.
[controller_server-1] [INFO] [1711077602.426512054] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077603.426505040] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077604.476500892] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077605.526497582] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077606.576501000] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077607.576501680] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077608.626503445] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077609.676499406] [controller_server]: Passing new path to controller.
[controller_server-1] [INFO] [1711077610.676499838] [controller_server]: Passing new path to controller.
[planner_server-2] [WARN] [1711077611.494322610] [global_costmap.global_costmap]: Can't update static costmap layer, no map received
[controller_server-1] [INFO] [1711077611.726506327] [controller_server]: Passing new path to controller.
[controller_server-1] [ERROR] [1711077612.076564900] [controller_server]: Failed to make progress
[controller_server-1] [WARN] [1711077612.076722094] [controller_server_rclcpp_node]: [follow_path] [ActionServer] Aborting handle.
[controller_server-1] [INFO] [1711077612.095229289] [local_costmap.local_costmap]: Received request to clear entirely the local_costmap
[planner_server-2] [INFO] [1711077612.095798248] [global_costmap.global_costmap]: Received request to clear entirely the global_costmap
[recoveries_server-3] [INFO] [1711077612.106158884] [recoveries_server]: Attempting spin
[recoveries_server-3] [INFO] [1711077612.108650991] [recoveries_server]: Turning 1.57 for spin recovery.
[recoveries_server-3] [INFO] [1711077613.109627457] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077614.109668319] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077615.109801359] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077616.109621440] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077617.109543970] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077618.109549229] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077619.109580373] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077620.109509738] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077621.109508454] [recoveries_server]: spin running...
[planner_server-2] [WARN] [1711077621.494320460] [global_costmap.global_costmap]: Can't update static costmap layer, no map received
[recoveries_server-3] [INFO] [1711077622.109489899] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077623.109482526] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077624.109472705] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077625.109478057] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077626.109443989] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077627.109607907] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077628.109431126] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077629.109421072] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077630.109395034] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077631.109610792] [recoveries_server]: spin running...
[planner_server-2] [WARN] [1711077631.494403856] [global_costmap.global_costmap]: Can't update static costmap layer, no map received
[recoveries_server-3] [INFO] [1711077632.109605338] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077633.109395948] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077634.109377382] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077635.109327999] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077636.109466975] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077637.109356273] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077638.109911714] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077639.109350267] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077640.109315493] [recoveries_server]: spin running...
[recoveries_server-3] [INFO] [1711077641.109405172] [recoveries_server]: spin running...
^C[WARNING] [launch]: user interrupted with ctrl-c (SIGINT)
[lifecycle_manager-9] [INFO] [1711077657.417588109] [rclcpp]: signal_handler(signal_value=2)
[map_server-7] [INFO] [1711077657.417591599] [rclcpp]: signal_handler(signal_value=2)
[waypoint_follower-5] [INFO] [1711077657.417611664] [rclcpp]: signal_handler(signal_value=2)
[recoveries_server-3] [INFO] [1711077657.417624477] [rclcpp]: signal_handler(signal_value=2)
[lifecycle_manager-6] [INFO] [1711077657.417642972] [rclcpp]: signal_handler(signal_value=2)
[controller_server-1] [INFO] [1711077657.417646982] [rclcpp]: signal_handler(signal_value=2)
[bt_navigator-4] [INFO] [1711077657.417703273] [rclcpp]: signal_handler(signal_value=2)
[bt_navigator-4] [ERROR] [1711077657.418931201] [bt_navigator]: Action server failed while executing action callback: "Failed to create interrupt guard condition in Executor constructor: the given context is not valid, either rcl_init() was not called or rcl_shutdown() was called., at /tmp/binarydeb/ros-foxy-rcl-1.1.14/src/rcl/guard_condition.c:67"
[bt_navigator-4] [WARN] [1711077657.418956192] [bt_navigator]: [navigate_to_pose] [ActionServer] Aborting handle.
[bt_navigator-4] [INFO] [1711077657.421430445] [bt_navigator]: Destroying
[planner_server-2] [INFO] [1711077657.417755857] [rclcpp]: signal_handler(signal_value=2)
[INFO] [recoveries_server-3]: process has finished cleanly [pid 229568]
[INFO] [planner_server-2]: process has finished cleanly [pid 229566]
[amcl-8] [INFO] [1711077657.417774824] [rclcpp]: signal_handler(signal_value=2)
[INFO] [controller_server-1]: process has finished cleanly [pid 229564]
[map_server-7] [INFO] [1711077657.418754448] [map_server]: Destroying
[recoveries_server-3] [WARN] [1711077657.419306881] [recoveries_server]: [spin] [ActionServer] Current goal was not completed successfully.
[recoveries_server-3] [WARN] [1711077657.419339355] [recoveries_server]: [spin] [ActionServer] Aborting handle.
[lifecycle_manager-6] [INFO] [1711077657.425754777] [lifecycle_manager_navigation]: Destroying
[amcl-8] [INFO] [1711077657.426371525] [amcl]: Destroying
[lifecycle_manager-9] [INFO] [1711077657.426598087] [lifecycle_manager_localization]: Destroying
[waypoint_follower-5] [INFO] [1711077657.427229596] [waypoint_follower]: Destroying
[ERROR] [bt_navigator-4]: process has died [pid 229571, exit code -6, cmd '/opt/ros/foxy/lib/nav2_bt_navigator/bt_navigator --ros-args -r __node:=bt_navigator --params-file /tmp/tmp27jgxwzu -r /tf:=tf -r /tf_static:=tf_static'].
[INFO] [lifecycle_manager-9]: process has finished cleanly [pid 229609]
[INFO] [amcl-8]: process has finished cleanly [pid 229606]
[INFO] [lifecycle_manager-6]: process has finished cleanly [pid 229595]
[INFO] [map_server-7]: process has finished cleanly [pid 229601]
[bt_navigator-4] terminate called after throwing an instance of 'rclcpp::exceptions::RCLError'
[bt_navigator-4] what(): Failed to create interrupt guard condition in Executor constructor: the given context is not valid, either rcl_init() was not called or rcl_shutdown() was called., at /tmp/binarydeb/ros-foxy-rcl-1.1.14/src/rcl/guard_condition.c:67
[INFO] [waypoint_follower-5]: process has finished cleanly [pid 229592]

The error says that
[global_costmap.global_costmap]: Can't update static costmap layer, no map received.

I believe that HSR cannot estimate self-location for global_costmap because global_costmap is not updated.

Therefore, when I specify 2D Pose Estimate outside the map, HSR seems to estimate self-location only for local_costmap.

@k-takeshita
Copy link
Contributor

I looked into it a bit since your team's pull requests have been helpful.
It seems like the error message 'Can't update static costmap layer, no map received.' is being output when the callback subscribing to /map is not being executed.
https://github.com/ros-planning/navigation2/blob/foxy-devel/nav2_costmap_2d/plugins/static_layer.cpp

You may want to check the status of the map topic using commands like 'ros2 topic echo /map' or 'ros2 topic info -v /map'.

Also, from my experience, although the cause is unclear, building the navigation2 repository from source has sometimes resolved the issue.

@y-masutani
Copy link

y-masutani commented Apr 3, 2024

@ayakasakurai0213 Please try hsr-project/hsrb_rosnav#6

@ayakasakurai0213
Copy link
Author

@y-masutani
Thanks to your comment, I fixed that problem!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants