Posted by @Anisha-thakkar:
System info:
Ubuntu’22
ROS2 Humble
rmf jazzy (src build)
I have successfully installed the rmf core setup, successfully ran all the demos of rmf_demos and free_fleet example too.
Now I am trying integrate the real robot with rmf. I have completed the zenoh bridge setup on the robot and communication is established. I have created the building.yaml map of the surrounding with the help of traffic editor and done the necessary change in fleet adapter but when I am trying to launch fleet adapter it throws initial state location error as following:
ros2 launch free_fleet_examples nav2_tb3_simulation_fleet_adapter.launch.xml server_uri:="ws://localhost:8000/_internal"
[INFO] [launch]: All log files can be found below /home/einfochips/.ros/log/2025-02-04-16-12-20-108867-AHMCPU2642-234346
[INFO] [launch]: Default logging verbosity is set to INFO
[INFO] [fleet_adapter.py-1]: process started with pid [234347]
[fleet_adapter.py-1] [retreat_to_charger_interval] value is not provided, default to 10 seconds
[fleet_adapter.py-1] Finishing request: charge
[fleet_adapter.py-1] Fleet is configured to perform ChargeBattery as finishing request
[fleet_adapter.py-1] Maximum delay is not provided, default to 10.0
[fleet_adapter.py-1] [INFO] [1738665740.957307021] [smartrover_fleet_adapter]: Parameter [discovery_timeout] set to: 60.000000
[fleet_adapter.py-1] [INFO] [1738665740.962790386] [smartrover_fleet_adapter]: Registering to query topic rmf_traffic/query_update_1
[fleet_adapter.py-1] [INFO] [1738665740.973868705] [smartrover_fleet_adapter]: Mirror handling new sync of 1 queries from schedule node [c2b944f0-73c9-4a10-840c-85985624f905]
[fleet_adapter.py-1] [INFO] [1738665741.995917870] [smartrover_command_handle]: Transformation error estimate for L1: 6.6409171819835375
[fleet_adapter.py-1] [INFO] [1738665742.000543613] [smartrover_fleet_adapter]: Attempting to connect to ws://localhost:8000/_internal
[fleet_adapter.py-1] [INFO] [1738665742.001114835] [smartrover_fleet_adapter]: Fleet [smartrover] is configured to perform delivery tasks
[fleet_adapter.py-1] [INFO] [1738665742.001148268] [smartrover_fleet_adapter]: Fleet [smartrover] is configured to perform patrol tasks
[fleet_adapter.py-1] [INFO] [1738665742.001195442] [smartrover_fleet_adapter]: Finished configuring Easy Full Control adapter for fleet [smartrover]
[fleet_adapter.py-1] [INFO] [1738665742.002766787] [smartrover_fleet_adapter]: Succesfully connected to ws://localhost:8000/_internal
[fleet_adapter.py-1] [INFO] [1738665742.002810608] [smartrover_fleet_adapter]: Connected to server
[fleet_adapter.py-1] [INFO] [1738665742.002837256] [smartrover_fleet_adapter]: Sent all updates
[fleet_adapter.py-1] [INFO] [1738665742.002857570] [smartrover_fleet_adapter]: Attempting queue flush if connected
[fleet_adapter.py-1] [INFO] [1738665742.007143429] [smartrover_command_handle]: Unable to get transform between base_footprint and map: <class 'tf2.LookupException'>: "sr1/map" passed to lookupTransform argument target_frame does not exist.
[fleet_adapter.py-1] [INFO] [1738665742.007541245] [smartrover_command_handle]: Failed to update robot [sr1]: Unable to get transform between base_footprint and map
[fleet_adapter.py-1] [INFO] [1738665742.007895717] [smartrover_command_handle]: Failed to pose of robot [sr1]
[fleet_adapter.py-1] [INFO] [1738665742.107609545] [smartrover_command_handle]: Unable to get transform between base_footprint and map: <class 'tf2.LookupException'>: "sr1/map" passed to lookupTransform argument target_frame does not exist.
[fleet_adapter.py-1] [INFO] [1738665742.107912369] [smartrover_command_handle]: Failed to update robot [sr1]: Unable to get transform between base_footprint and map
[fleet_adapter.py-1] [INFO] [1738665742.108196798] [smartrover_command_handle]: Failed to pose of robot [sr1]
[fleet_adapter.py-1] [INFO] [1738665742.209250458] [smartrover_fleet_adapter]: Adding robot [sr1] to fleet [smartrover].
[fleet_adapter.py-1] [ERROR] [1738665742.209469318] [smartrover_fleet_adapter]: Unable to compute a location on the navigation graph for robot [sr1] being added to fleet [smartrover] using map [L1] and position [108.278, 137.536, -2.916] specified in the initial_state argument. This can happen if the map in initial_state does not match any of the map names in the navigation graph supplied or if the position reported in the initial_state is far way from the navigation graph. This robot will not be added to the fleet.
[fleet_adapter.py-1] [INFO] [1738665742.308766563] [smartrover_fleet_adapter]: Adding robot [sr1] to fleet [smartrover].
[fleet_adapter.py-1] [ERROR] [1738665742.308894380] [smartrover_fleet_adapter]: Unable to compute a location on the navigation graph for robot [sr1] being added to fleet [smartrover] using map [L1] and position [108.270, 137.416, -2.942] specified in the initial_state argument. This can happen if the map in initial_state does not match any of the map names in the navigation graph supplied or if the position reported in the initial_state is far way from the navigation graph. This robot will not be added to the fleet.
[fleet_adapter.py-1] [INFO] [1738665742.409011998] [smartrover_fleet_adapter]: Adding robot [sr1] to fleet [smartrover].
[fleet_adapter.py-1] [ERROR] [1738665742.409119626] [smartrover_fleet_adapter]: Unable to compute a location on the navigation graph for robot [sr1] being added to fleet [smartrover] using map [L1] and position [108.276, 137.354, -2.956] specified in the initial_state argument. This can happen if the map in initial_state does not match any of the map names in the navigation graph supplied or if the position reported in the initial_state is far way from the navigation graph. This robot will not be added to the fleet.
[fleet_adapter.py-1] [INFO] [1738665742.512703974] [smartrover_fleet_adapter]: Adding robot [sr1] to fleet [smartrover].
[fleet_adapter.py-1] [ERROR] [1738665742.512974840] [smartrover_fleet_adapter]: Unable to compute a location on the navigation graph for robot [sr1] being added to fleet [smartrover] using map [L1] and position [108.344, 137.329, -2.924] specified in the initial_state argument. This can happen if the map in initial_state does not match any of the map names in the navigation graph supplied or if the position reported in the initial_state is far way from the navigation graph. This robot will not be added to the fleet.
[fleet_adapter.py-1] [INFO] [1738665742.617289731] [smartrover_fleet_adapter]: Adding robot [sr1] to fleet [smartrover].
Fleet adapter config file is as follows:
# FLEET CONFIG =================================================================
# RMF Fleet parameters
rmf_fleet:
name: "smartrover"
fleet_manager:
ip: "127.0.0.1"
port: 22011
user: "some_user"
password: "some_password"
limits:
linear: [0.5, 0.75] # velocity, acceleration
angular: [0.6, 2.0] # velocity, acceleration
profile: # Robot profile is modelled as a circle
footprint: 0.3 # radius in m
vicinity: 0.5 # radius in m
reversible: True # whether robots in this fleet can reverse
battery_system:
voltage: 12.0 # V
capacity: 24.0 # Ahr
charging_current: 5.0 # AIDLE
mechanical_system:
mass: 20.0 # kg
moment_of_inertia: 10.0 #kgm^2
friction_coefficient: 0.22
ambient_system:
power: 20.0 # W
tool_system:
power: 0.0 # W
recharge_threshold: 0.10 # Battery level below which robots in this fleet will not operate
recharge_soc: 1.0 # Battery level to which robots in this fleet should be charged up to during recharging tasks
publish_fleet_state: 10.0 # Publish frequency for fleet state, ensure that it is same as robot_state_update_frequency
account_for_battery_drain: True
task_capabilities: # Specify the types of RMF Tasks that robots in this fleet are capable of performing
loop: True
delivery: True
# actions: ["some_action_here"]
finishing_request: "charge" # [park, charge, nothing]
responsive_wait: True # Should responsive wait be on/off for the whole fleet by default? False if not specified.
robots:
# tb1:
# # charger: "robot1_charger"
# responsive_wait: False # Should responsive wait be on/off for this specific robot? Overrides the fleet-wide setting.
# # For Nav2RobotAdapter
# navigation_stack: 2
# initial_map: "L1"
# maps:
# L1:
# map_url: "/opt/ros/humble/share/nav2_bringup/maps/turtlebot3_world.yaml"
sr1:
charger: "charger"
responsive_wait: False # Should responsive wait be on/off for this specific robot? Overrides the fleet-wide setting.
# For Nav2RobotAdapter
navigation_stack: 2
initial_map: "L1"
maps:
L1:
map_url: "/home/einfochips/my_map.yaml"
# initial_pose: [109.138, 135.746, -2.940]
robot_state_update_frequency: 10.0 # Hz
# TRANSFORM CONFIG =============================================================
# For computing transforms between Robot and RMF coordinate systems
reference_coordinates:
L1:
rmf: [[42.3770, 10.4130],
[90.8730, 6.2020],
[98.4800, 101.7010],
[26.6190, 102.9240]
]
robot: [[0.0848, 3.7000],
[2.5200, 3.8600],
[2.9100, -0.9010],
[-0.7320, -0.9540]
]