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

ROS2 launch external (non ROS) program

asked 2021-09-16 07:32:06 -0500

JanWeber gravatar image

Hello,

I am looking for a possibility to start a non-ROS program in ROS2 with a launchfile. For ROS1 there is aliencontrol. Is there something like this for ROS2? Or is it possible to start external programs from the Python launchfile?

Thank you! Jan

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
4

answered 2021-09-22 08:56:48 -0500

ChuiV gravatar image

Take a look at the ExecuteProcessAction (https://github.com/ros2/launch/blob/m...)

In fact, the Node Action you're probably already using in the python launch script wraps ExecuteProcess.

ExecuteProcess(cmd=['ping', '192.168.1.1'],
               output='screen'),
edit flag offensive delete link more

Comments

please consider ticking the answer to be correct if it has solved your problem.

flo gravatar image flo  ( 2021-09-23 15:12:06 -0500 )edit

Concrete example that uses ExecuteProcessActioncan be found in the official tutorial https://docs.ros.org/en/rolling/Tutor...

130s gravatar image 130s  ( 2023-04-07 15:53:24 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2021-09-16 07:32:06 -0500

Seen: 368 times

Last updated: Sep 22 '21