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

[ROS2] roslaunch fails reading yaml file

asked 2019-05-17 09:48:18 -0500

Andreas Ziegler gravatar image

updated 2019-06-17 11:27:38 -0500

Hi everyone

I working with ROS2 Crystal on Ubuntu Bionic. My goal is to add multi camera support to the ros2 realsense node (similar to the solution of the ros1 realsense node). I added a yaml file which is loaded from the launch python script. I also adjusted the node accordingly (You can find the code here https://github.com/AndreasAZiegler/ro... and my changes here https://github.com/AndreasAZiegler/ro...). There seems to be a problem with the loading of the yaml file. It doesn't matter, what parameters I define or not, I always get an error. I even took a yaml file from the ros2 example repository.

When I launch the node with

ros2 launch realsense_ros2_camera ros2_intel_realsense.launch.py

I get the following error message:

[ERROR] [launch.LaunchService]: Caught exception in launch (see debug for traceback): 'utf-8' codec can't decode byte 0xf0 in position 143: invalid continuation byte

I'm glad for any advice.

[Update]

I now moved to ROS2 dashing and adjusted the code accordingly (https://github.com/AndreasAZiegler/ro...). I still have the same problem. When I run the node with

ros2 run realsense_ros2_camera realsense_ros2_camera  __params:=/path/to/config/parameters.yaml

it works as expected and I get the following output:

[INFO] [RealSenseCameraNode]: We are looking for serial number 845112070204.

When I run the same node with the launch file (https://github.com/AndreasAZiegler/ro...)

ros2 launch realsense_ros2_camera ros2_intel_realsense.launch.py

the parameter is not loaded as the output is:

[realsense_ros2_camera-1] [INFO] [RealSenseCameraNode]: We are looking for serial number 0.

The path to the file is correct (I print it within the python launch file) and there is no error, it just does not load the parameter

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-09-03 02:51:15 -0500

xhuan28 gravatar image

updated 2019-09-03 02:51:30 -0500

It should be an issue of launch_ros. Refer to the following links for details. https://github.com/ros2/launch_ros/is...
https://github.com/ros2/rclcpp/issues...

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2019-05-17 09:48:18 -0500

Seen: 2,052 times

Last updated: Sep 03 '19