Ping from .launch file
Hello! I am attempting to add a line to my ros .launch file that would emulate the 'ping ##.#.###.##' command used in the command line. Is this possible? I am running Ubuntu 16.04. Thanks!
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
Hello! I am attempting to add a line to my ros .launch file that would emulate the 'ping ##.#.###.##' command used in the command line. Is this possible? I am running Ubuntu 16.04. Thanks!
'emulate' or actually run ping
?
If the latter: see #q272267.
Running regular (ie: non-ROS) binaries from roslaunch
is possible, but requires some special care.
The example there is with Python, but a simple bash script should also work.
With the assistance of your answer, I made a small python script and put that in the launch file. Thank you!
ICMP
ping, you can also run rosping node from your launch.For xmlrpc
ping in ROS network level, in rosnode Python API there are some methods, e.g. rosnode_ping. In the simplest form you can run a command like:
python -c "import rosnode; rosnode.rosnode_ping('/rosout', verbose=True)"
@AmateurHour: this is a good suggestion and was actually why I asked:
'emulate' or actually run
ping
?
Asked: 2018-06-26 16:26:11 -0500
Seen: 350 times
Last updated: Sep 15 '18
Ackermann Steering and Arduino Servo Control
difference between execute_cb and goalcb?
gps waypoints are not shown in mapviz
Timestamps of static transforms
[SOLVED] fedora: rqt_plot runtime error
What does the rospy.subscriber command do? [closed]
Setting octomap resolution doesn't work
How to give desired position(x,y,z) to ikfast translation3d solver in cpp?