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

Does MRPT_navigation work in HYDRO?

asked 2015-02-10 23:20:10 -0600

kost9 gravatar image

updated 2015-02-11 01:05:36 -0600

I tried to follow the steps described here: http://wiki.ros.org/mrpt_navigation/T... but catkin_make gives me errors. My steps are: 1)sudo apt-get install libmrpt-dev 2)cd /src 3)git clone https://github.com/mrpt-ros-pkg/mrpt_... 4)cd .. 5)catkin_make

After that, when building mrpt_navigation it gives me this:

[ 50%] Building CXX object mrpt_navigation/mrpt_bridge/CMakeFiles/mrpt_bridge.dir/src/point_cloud2.cpp.o
Building CXX object mrpt_navigation/mrpt_bridge/CMakeFiles/mrpt_bridge.dir/src/point_cloud.cpp.o
/home/arms/catkin_ws/src/mrpt_navigation/mrpt_bridge/src/pose.cpp: In function ‘mrpt::poses::CPose3D& mrpt_bridge::convert(const tf::Transform&, mrpt::poses::CPose3D&)’:
/home/arms/catkin_ws/src/mrpt_navigation/mrpt_bridge/src/pose.cpp:87:10: error: ‘class mrpt::poses::CPose3D’ has no member named ‘setRotationMatrix’
/home/arms/catkin_ws/src/mrpt_navigation/mrpt_bridge/src/point_cloud2.cpp: In function ‘bool mrpt_bridge::copy(const mrpt::slam::CSimplePointsMap&, const Header&, sensor_msgs::PointCloud2&)’:
/home/arms/catkin_ws/src/mrpt_navigation/mrpt_bridge/src/point_cloud2.cpp:108:55: note: #pragma message: TODO: "Implement pointcloud2 mrpt2ros"

[ 52%] Building CXX object mrpt_navigation/mrpt_bridge/CMakeFiles/mrpt_bridge.dir/src/laser_scan.cpp.o

[ 55%] Building CXX object mrpt_navigation/mrpt_bridge/CMakeFiles/mrpt_bridge.dir/src/map.cpp.o

make[2]: *** [mrpt_navigation/mrpt_bridge/CMakeFiles/mrpt_bridge.dir/src/pose.cpp.o] Error 1

make[2]: *** Waiting for unfinished jobs....

Linking CXX shared library /home/arms/catkin_ws/devel/lib/libmrpt_localization_core.so
[ 55%] Built target mrpt_localization_core
Scanning dependencies of target mrpt_localization

[ 61%] [ 61%] Building CXX object mrpt_navigation/mrpt_localization/CMakeFiles/mrpt_localization.dir/src/mrpt_localization/mrpt_localization_parameters.cpp.o
Building CXX object mrpt_navigation/mrpt_localization/CMakeFiles/mrpt_localization.dir/src/mrpt_localization/mrpt_localization.cpp.o
make[1]: *** [mrpt_navigation/mrpt_bridge/CMakeFiles/mrpt_bridge.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
Linking CXX shared library /home/arms/catkin_ws/devel/lib/libmrpt_localization.so

[ 61%] Built target mrpt_localization

make: *** [all] Error 2

Invoking "make" failed

In my src/mrpt_navigation there are multiple mrpt folders and when I run roslaunch mrpt_localization demo.launch it gives me: Error: cannot launch node of type [mrpt_localization/mrpt_localization_node]: cant locate node in package
Could anyone please help?

I am using ROS Hydro, Ubuntu 12.04

[edit] added full error message

edit retag flag offensive close merge delete

Comments

Please edit your question to include the full error that you get when running catkin_make

ahendrix gravatar image ahendrix  ( 2015-02-11 00:12:29 -0600 )edit

2 Answers

Sort by » oldest newest most voted
1

answered 2015-03-05 01:42:56 -0600

updated 2015-03-05 01:46:09 -0600

The best solution is to remove the system version of mrpt, which is quite old in Ubuntu 12.04:

sudo apt-get remove libmrpt-dev mrpt-apps

then installing a more recent version. You have 2 options:

1) Build from sources, either cloning master from GitHub or downloading the last stable version. Building instructions can be found here.

2) Installing with apt-get via the PPA repository.

Cheers,
JL

edit flag offensive delete link more

Comments

Thank you Very much, Jose! that helped.

kost9 gravatar image kost9  ( 2015-03-11 07:02:24 -0600 )edit

I installed the more recent version from the PPA repository.
Then, export MRPT_DIR=YOUR_MRPT_BUILD_DIR

But when I went to the MRPT Git Repository, there was only the ROS Indigo distribution.
I'm working with Hydro, where can I find it?

sealguy77 gravatar image sealguy77  ( 2015-03-13 13:05:26 -0600 )edit

@kost9: Great!

@sealguy77: Just clone the branch named "indigo", it should work on hydro too. In the future we'll probably rename the branch to "master" or alike to avoid confusion.

Jose Luis Blanco gravatar image Jose Luis Blanco  ( 2015-03-14 03:49:20 -0600 )edit

Hi Jose! thanks for your help again!

Another question: Does mrpt_localization package rely on odometry messages from robot? I used a slam method to generate a map that doesnt need odometry, since my robot doesnt provide odometry data.

kost9 gravatar image kost9  ( 2015-03-14 04:10:54 -0600 )edit

Yes, mrpt_localization relies on odometry, but if it is not present it should still be able to track the robot just from laser scans (increase the "uncertainty parameters" a bit to make the particles spread more than usual). If it doesn't work open an issue on GitHub or try to fix and pull-request

Jose Luis Blanco gravatar image Jose Luis Blanco  ( 2015-03-15 09:15:20 -0600 )edit

A) Thanks for help, Jose! I tried following but had no luck. So far I used your demo.launch file as a template: 1) I tried feeding my own map (.pgm, .tiff formats) but those didnt load.
2) changed r1/front_laser/scan to just /scan (I provide scan topic) 3) not sure how to set up tf transform

kost9 gravatar image kost9  ( 2015-03-17 00:52:46 -0600 )edit

B) generally I dont know how to set this launch file up.

in terminal I get this error : Failed to subtract global_frame (map) from odom_frame (r1/odom)

I am only providing /scan topic and I have a ready map (previously generated in rviz by hector_slam)

I would very much appreciate your help!

kost9 gravatar image kost9  ( 2015-03-17 01:02:39 -0600 )edit
0

answered 2015-02-11 02:26:03 -0600

ahendrix gravatar image

It looks like mrpt_bridge is trying to call a function that doesn't exist in the version of MRPT that you're using.

Looking at the recent commits on the MRPT repository, it looks like they're made some recent commits for MRPT version compatibility, so I suspect the MRPT API has changed between the version that they're using and the version you're using.

You should figure out which version of MRPT you're using.

You can then either look at the MRPT docs for your version, try to fix mrpt_bridge so that it compiles, and send the maintainers a pull request, or you can report a bug with the version of MRPT you're using and your compile error, and wait for them to fix it.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2015-02-10 23:20:10 -0600

Seen: 700 times

Last updated: Mar 05 '15