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

Poco exception = /home/msy/ros_ws/devel/lib//libgrid_layer.so: undefined symbol: _ZN2tf11Transformer18DEFAULT_CACHE_TIMEE

asked 2023-06-30 02:27:11 -0500

peter_feng gravatar image

updated 2023-06-30 02:31:38 -0500

I wrote a custom costmap plugin.

It can work on local costmap.The configuration is as follows:

plugins:
- {name: grid_layer, type: "simple_layer_namespace::GridLayer"}
- {name: inflation_layer, type: "costmap_2d::InflationLayer"}

But if I configure it to the global costmap,it will report an error.

[ INFO] [1688106907.862182415, 1687920714.481622674]: global_costmap: Using plugin "grid_layer" terminate called after throwing an instance of 'pluginlib::LibraryLoadException' what(): Failed to load library /home/msy/ros_ws/devel/lib//libgrid_layer.so. Make sure that you are calling the PLUGINLIB_EXPORT_CLASS macro in the library code, and that names are consistent between this macro and your XML. Error string: Could not load library (Poco exception = /home/msy/ros_ws/devel/lib//libgrid_layer.so: undefined symbol: _ZN2tf11Transformer18DEFAULT_CACHE_TIMEE)

The configuration is as follows:

plugins:
# - {name: static_layer, type: "costmap_2d::StaticLayer"}
# - {name: obstacle_layer, type: "costmap_2d::ObstacleLayer"}
- {name: grid_layer, type: "simple_layer_namespace::GridLayer"}
- {name: inflation_layer, type: "costmap_2d::InflationLayer"}

What went wrong?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2023-07-02 09:59:18 -0500

Mike Scheutzow gravatar image

"Transformer" is part of the tf ros package, so in your CMakeLists.txt you need to specify that your plugin has a dependency on this package. There are other tf-related ros packages you may also need (tf2, tf2_ros, tf_conversions), but I'm pretty sure that particular error is from tf.

edit flag offensive delete link more

Comments

I added all of them(tf, tf2_ros, tf_conversions) to the configuration file.

It worked! Thank you.

peter_feng gravatar image peter_feng  ( 2023-07-03 02:20:11 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2023-06-30 02:27:11 -0500

Seen: 111 times

Last updated: Jul 02 '23