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

start ros node without a launch file

asked 2013-03-11 21:01:16 -0500

JohnnyRep gravatar image

I would like to init and start a ros node as a service in an other framework to offer my data to an already existing data analysis software written in ROS. That means that this node is created within a non-ros process without a call of launch files.

So far I managed to call ros::init and create a nodeHandle etc. But I need to start any of rosnode first via roslaunch before my process get fully initialize (otherwise my process is blocked and waits for ROS). I guess roscore etc is missing.

How can I initialize all that within my own process, so that ROS gets fully set up without any call of roslaunch.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2013-03-11 23:02:56 -0500

jbohren gravatar image

updated 2013-03-11 23:04:04 -0500

Just run roscore once somewhere else, and you should be good. You'll need to make sure that all of your ROS processes are launched with the proper $ROS_MASTER_URI environment variable so that they point to the machine on which you're running the roscore.

To learn more about how all this works, take a look at the roscore wiki page.

edit flag offensive delete link more

Question Tools


Asked: 2013-03-11 21:01:16 -0500

Seen: 1,036 times

Last updated: Mar 11 '13