AMCL cannot publish a pose or update the transform. Please set the initial pose...
I'm a ROS2 n00b trying to learn navigation2. I have a lot of experience with ROS1's navigation stack but am having basic issues with navigation2. I'm running ROS2 galactic built from source on an NVidia Jetson Xavier NX running Ubuntu 18.04.6 LTS bionic. I'm currently have an issue where AMCL doesn't publish the map->odom transform. This message gets printed every 2 seconds:
AMCL cannot publish a pose or update the transform. Please set the initial pose...
I'm not sure what AMCL is asking for here. How can I set an initial pose if map->odom isn't defined? I have an initial pose of 0, 0, 0, 0 set in my config and what seems to be a valid map. One thing that confuses me is why the map_server only publishes the map once when it launches and never again. Could this be part of the problem?
I'm launching navigation2 with their localization bring up launch file: nav2_bringup/launch/localization_launch.py
rqt_graph:
tf tree:
Link to launch file in question:
https://github.com/frc-88/tj2_ros/blo...
Full terminal output:
[INFO] [launch]: All log files can be found below /home/tj2/.ros/log/2022-05-23-15-43-07-215734-porygon2-18955
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [map_server-1]: process started with pid [18963]
[INFO] [amcl-2]: process started with pid [18964]
[INFO] [lifecycle_manager-3]: process started with pid [18965]
[lifecycle_manager-3] [INFO] [1653334989.312059616] [lifecycle_manager_localization]: Creating
[lifecycle_manager-3] [INFO] [1653334989.362775040] [lifecycle_manager_localization]: Creating and initializing lifecycle service clients
[lifecycle_manager-3] [INFO] [1653334989.473732992] [lifecycle_manager_localization]: Starting managed nodes bringup...
[lifecycle_manager-3] [INFO] [1653334989.473970336] [lifecycle_manager_localization]: Configuring map_server
[map_server-1] [INFO] [1653334989.629669088] [map_server]:
[map_server-1] map_server lifecycle node launched.
[map_server-1] Waiting on external lifecycle transitions to activate
[map_server-1] See https://design.ros2.org/articles/node_lifecycle.html for more information.
[map_server-1] [INFO] [1653334989.630390592] [map_server]: Creating
[map_server-1] [INFO] [1653334989.646481792] [map_server]: Configuring
[map_server-1] [INFO] [map_io]: Loading yaml file: /home/tj2/ros2_ws/install/tj2_navigation/share/tj2_navigation/maps/map_1653284131.yaml
[map_server-1] [DEBUG] [map_io]: resolution: 0.05
[map_server-1] [DEBUG] [map_io]: origin[0]: -4.07
[map_server-1] [DEBUG] [map_io]: origin[1]: -6
[map_server-1] [DEBUG] [map_io]: origin[2]: 0
[map_server-1] [DEBUG] [map_io]: free_thresh: 0.25
[map_server-1] [DEBUG] [map_io]: occupied_thresh: 0.65
[map_server-1] [DEBUG] [map_io]: mode: trinary
[map_server-1] [DEBUG] [map_io]: negate: 0
[map_server-1] [INFO] [map_io]: Loading image_file: /home/tj2/ros2_ws/install/tj2_navigation/share/tj2_navigation/maps/map_1653284131.pgm
[map_server-1] [DEBUG] [map_io]: Read map /home/tj2/ros2_ws/install/tj2_navigation/share/tj2_navigation/maps/map_1653284131.pgm: 206 X 187 map @ 0.05 m/cell
[amcl-2] [INFO] [1653334989.724978304] [amcl]:
[amcl-2] amcl lifecycle node launched.
[amcl-2] Waiting on external lifecycle transitions to activate
[amcl-2] See https://design.ros2.org/articles/node_lifecycle.html for more information.
[amcl-2] [INFO] [1653334989.725556160] [amcl]: Creating
[lifecycle_manager-3] [INFO] [1653334989.760930624] [lifecycle_manager_localization]: Configuring amcl
[amcl-2] [INFO] [1653334989.824301664] [amcl]: Configuring
[amcl-2] [INFO] [1653334989.826404096] [amcl]: initTransforms
[amcl-2] [INFO] [1653334989.899745056] [amcl]: initPubSub
[amcl-2] [INFO] [1653334989.917563232] [amcl]: Subscribed to map topic.
[lifecycle_manager-3] [INFO] [1653334989.936369088] [lifecycle_manager_localization]: Activating map_server
[map_server-1] [INFO] [1653334989.938350944] [map_server]: Activating
[map_server-1] [INFO] [1653334989.941107424] [map_server]: Creating bond (map_server) to lifecycle ...