Ask Your Question
0

Use ROS libraries in a non-ROS project

asked 2015-02-01 02:46:42 -0500

jdorfsman gravatar image

I have been working on a large project which uses OpenCV and Boost libraries (not using ROS). Now my manager asked me to include ROS libraries into the project. The only use for ROS will be to send and receive messages within a single robot. I will need to receive an operation code and send a respond. I was wondering if there is a way to configure a ROS project with only a "talker" and "listener" and then somehow include these in my main project and use them there? This could be the best way, another option is to compile my whole project using ROS (add all the libraries and dependencies) but I have tried this many times and I get multiple errors. Another way I thought would be creating a class inside my project which will use the terminal read/write from/to a topic.. Is the first option possible? Thanks!

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2015-02-02 06:49:01 -0500

Wolf gravatar image

Typically, I think the best work around for this would be to create an lean API for the most basic calls you need of your existing code base. Then put your existing project into a shared library and call into your library from a very tiny ROS talker/listener exectuable that sets up the communication to the ROS world via publishers/subscribers,

edit flag offensive delete link more

Comments

Is there a manual to do this, I'm trying but not succeeding to create this shared library..

jdorfsman gravatar image jdorfsman  ( 2015-02-03 08:46:35 -0500 )edit
0

answered 2015-02-02 07:45:18 -0500

gvdhoorn gravatar image

updated 2015-02-02 07:45:28 -0500

As an alternative to @Wolf's answer, you might be interested in ros_bridge. That would allow interaction between a ROS node graph and a stand-alone system, but would remove the need to link against any ROS libraries.

edit flag offensive delete link more

Comments

I will try this option, thanks!

jdorfsman gravatar image jdorfsman  ( 2015-02-03 07:50:53 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2015-02-01 02:46:42 -0500

Seen: 187 times

Last updated: Feb 02 '15