ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

[bt_navigator]: Action server failed while executing action callback: "One of the children of a DecoratorNode or ControlNode is nullptr"

asked 2022-05-25 04:10:59 -0500

Bastian2909 gravatar image

For a bit of context : I'm not fully understanding how the nav2 package work so I might be inacurate, feel free to correct me ! I'm using ros Foxy on ubuntu 20.04, rviz2 and gazebo 11.

My goal is to move my robot from point A to point B using nav2, to do so I believe I have to set a 2D starting pose estimate on rviz2 and then a 2D pose goal. Everything work fine until I set this goal where the bt_navigator send this error on my terminal :

[bt_navigator]: Action server failed while executing action callback: "One of the children of a DecoratorNode or ControlNode is nullptr"
[bt_navigator-12] [WARN] [1653469056.049863668] [bt_navigator]: [navigate_to_pose] [ActionServer] Aborting handle.

here is the previous lines in case :

[rviz2-15] [INFO] [1653469032.586736918] [rviz2]: Trying to create a map of size 1000 x 1000 using 1 swatches
[rviz2-15] [ERROR] [1653469032.695960860] [rviz2]: Vertex Program:rviz/glsl120/indexed_8bit_image.vert Fragment Program:rviz/glsl120/indexed_8bit_image.frag GLSL link result : 
[rviz2-15] active samplers with a different type refer to the same texture image unit
[INFO] [harrowbot_ui-1]: process has finished cleanly [pid 31290]
[rviz2-15] [INFO] [1653469051.876974783] [rviz2]: Setting estimate pose: Frame:odom, Position(-0.0527983, 0.134308, 0), Orientation(0, 0, 0.0319221, 0.99949) = Angle: 0.063855
[rviz2-15] [INFO] [1653469055.959320211] [rviz2]: Setting goal pose: Frame:odom, Position(3.24848, 0.127145, 0), Orientation(0, 0, 0.0764996, 0.99707) = Angle: 0.153149
[bt_navigator-12] [INFO] [1653469055.993426860] [bt_navigator]: Begin navigating from current location to (3.25, 0.13)

Here is my nav2_param.yaml file :

bt_navigator:
  ros__parameters:
    use_sim_time: True
    global_frame: map
    robot_base_frame: base_link
    odom_topic: /odom
    bt_loop_duration: 10
    default_server_timeout: 20
    enable_groot_monitoring: True
    groot_zmq_publisher_port: 1666
    groot_zmq_server_port: 1667
    # 'default_nav_through_poses_bt_xml' and 'default_nav_to_pose_bt_xml' are use defaults:
    # nav2_bt_navigator/navigate_to_pose_w_replanning_and_recovery.xml
    # nav2_bt_navigator/navigate_through_poses_w_replanning_and_recovery.xml
    # They can be set here or via a RewrittenYaml remap from a parent launch file to Nav2.
    plugin_lib_names:
    - nav2_compute_path_to_pose_action_bt_node
    - nav2_follow_path_action_bt_node
    - nav2_back_up_action_bt_node
    - nav2_spin_action_bt_node
    - nav2_wait_action_bt_node
    - nav2_clear_costmap_service_bt_node
    - nav2_is_stuck_condition_bt_node
    - nav2_goal_reached_condition_bt_node
    - nav2_goal_updated_condition_bt_node
    - nav2_initial_pose_received_condition_bt_node
    - nav2_reinitialize_global_localization_service_bt_node
    - nav2_rate_controller_bt_node
    - nav2_distance_controller_bt_node
    - nav2_speed_controller_bt_node
    - nav2_truncate_path_action_bt_node
    - nav2_goal_updater_node_bt_node
    - nav2_recovery_node_bt_node
    - nav2_pipeline_sequence_bt_node
    - nav2_round_robin_node_bt_node
    - nav2_transform_available_condition_bt_node
    - nav2_time_expired_condition_bt_node
    - nav2_distance_traveled_condition_bt_node
    - nav2_is_battery_low_condition_bt_node
    - nav2_navigate_to_pose_action_bt_node

bt_navigator_rclcpp_node:
  ros__parameters:
    use_sim_time: True

map_server:
  ros__parameters:
    use_sim_time: True
    yaml_filename: "turtlebot3_world.yaml"

map_saver:
  ros__parameters:
    use_sim_time: True
    save_map_timeout: 5.0
    free_thresh_default: 0.25
    occupied_thresh_default: 0.65
    map_subscribe_transient_local: True


local_costmap:
  local_costmap:
    ros__parameters:
      update_frequency: 5.0
      publish_frequency: 2.0
      global_frame: odom
      robot_base_frame: base_link
      use_sim_time: True
      rolling_window: true
      width: 3
      height: 3
      resolution: 0.05
      footprint: "[ [0.496, 0.433], [0.496, -0.433], [-0.312, -0.433], [-0.312, 0.433] ]"
      plugins: ["voxel_layer", "inflation_layer"]
      inflation_layer:
        plugin: "nav2_costmap_2d::InflationLayer"
        cost_scaling_factor: 3.0
        inflation_radius: 0.55
      voxel_layer:
        plugin: "nav2_costmap_2d::VoxelLayer"
        enabled: True
        publish_voxel_map: True
        origin_z: 0.0
        z_resolution: 0.05
        z_voxels: 16
        max_obstacle_height: 2.0
        mark_threshold: 0
        observation_sources: scan
        scan:
          topic: /scan
          max_obstacle_height: 2.0
          clearing: True
          marking: True
          data_type: "LaserScan"
          raytrace_max_range: 3.0
          raytrace_min_range: 0.0
          obstacle_max_range: 2.5
          obstacle_min_range: 0.0
      static_layer:
        map_subscribe_transient_local: True
      always_send_full_costmap: True
  local_costmap_client:
    ros__parameters:
      use_sim_time: True
  local_costmap_rclcpp_node:
    ros__parameters:
      use_sim_time: True

global_costmap:
  global_costmap:
    ros__parameters:
      update_frequency: 1.0
      publish_frequency: 1.0
      global_frame: map
      robot_base_frame: base_link
      use_sim_time: True
      robot_radius: 0.5
      resolution: 0.05
      track_unknown_space: true
      plugins: ["static_layer", "obstacle_layer ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2022-05-25 04:36:43 -0500

Joe28965 gravatar image

Where did you get the base for nav2_params.yaml from? this yaml is the one that is in the foxy-devel branch for Nav2.

I can see that there are some clear differences between the two (the list of plugin_lib_names is different, for starters). I think you're working with an old file as the basis for your parameters. I recommend using the one that I linked as your base and add stuff like your footprint (which I noticed you've also changed, that change looks like it should work) to that new clean base.

My guess as to why it's not working is because your yaml file is trying to start things that are renamed, removed, merged, or a combination of the 3.

It's going to be very tedious to go through the entire file bit by bit to find these deprecated mistakes, while editing a clean base should work and be a lot faster.

edit flag offensive delete link more

Comments

Thank you for everything,this link is exactly what I needed, now everything work, i'm so happy to finally see my robot move by itself ! Indeed, i remember having some trouble with the list of plugin_lib_names. Thank you again for your time !!!!

Bastian2909 gravatar image Bastian2909  ( 2022-05-25 05:11:34 -0500 )edit

Happy to help, that's what the forum is for. I'm glad it worked.

Joe28965 gravatar image Joe28965  ( 2022-05-25 06:22:25 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2022-05-25 04:10:59 -0500

Seen: 576 times

Last updated: May 25 '22