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

Make old programs work in new ROS version

asked 2014-08-12 03:39:38 -0500

abcgarden gravatar image

I have asked a specific question last time, now I want to ask a more general question to which the answer will be definitely helpful to people who also have the confuse like I do. The question is:

There are always many changes to files(the content and the file name!) from one ROS version to another version. So I want to know what kind of changes have been made(as detailed as possible) so that I can modify my program to run in the new ROS version. I think my possible solution is either one of the following:

Condition I: what is no longer available in the new ROS version is a header file 
Solution: Copy-paste the old header file into the package folder of the new ROS version and include it in the source code.

But the problem is the header file maybe rely on other header files so I will copy-paste many of them.

Consition II: what is no longer available in the new ROS version is a package
Solution: 1. Copy-paste the whole package to the package directory of the new ROS version and  "depend" on it.
2. Find out similar package in the new ROS version and change my programs.

Solution 1 is direct but seems not practical, the old package may not be compatible with new ROS and another problem is how to make it "dependable"?

Solution 2 seems better but it involves much work to do. The most important thing is how to find out a similar package? Should I compare each class, function and variable between them(I have to compare each new package?!) And in each package there are many classes, functions and it takes me much time to understand them. And even worse, if there is no similar package, I should write a new package available in the new ROS.

Any suggestion or more possibly better solutions to my question?

edit retag flag offensive close merge delete

Comments

I did not find other solution. I was in groovy, and changed for hydro. I've been oblige to check one by one all my package. But most of package works fine in the new ROS version

Moda gravatar image Moda  ( 2014-08-12 06:04:39 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
2

answered 2014-08-12 06:32:32 -0500

BennyRe gravatar image

The place to look first is the migration guide of the specific distribution. For Hydro this is this guide.

Your solution to condition 1 is very dirty in my eyes. It would cause much headache in the future.

The second condition is the one that actually occurs often. Just copy-pasting a package can work, but you may have to migrate this package to. So you should fork the package, port it to the new distro and do a pull request.

Solution 2 is also possible. But it would be much easier to contact the maintainer of the old package and ask what they use with the new distro.

edit flag offensive delete link more

Comments

Do you have another better solution to consition1? Can you give me more details of your solution for Condition II, like how to fork the package? @BennyRe

Winston gravatar image Winston  ( 2014-08-12 12:39:03 -0500 )edit

It seems that there is no migration guide for Groovy? @BennyRe

abcgarden gravatar image abcgarden  ( 2014-08-13 10:45:49 -0500 )edit

There's a section on the Groovy Wiki page.

BennyRe gravatar image BennyRe  ( 2014-08-14 01:02:12 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2014-08-12 03:39:38 -0500

Seen: 405 times

Last updated: Aug 12 '14