runCore
Start ROS core
Syntax
Description
Examples
Run ROS Core on ROS Device
Connect to a remote ROS device and start a ROS core. The ROS core is needed to run ROS nodes to communicate via a ROS network. You can run and stop a ROS core or node and check their status using a rosdevice
object.
Create a connection to a ROS device. Specify the address, user name, and password of your specific ROS device. The device contains information about the ROS device, including the available ROS nodes that can be run using runNode
.
ipaddress = '192.168.203.131'; d = rosdevice(ipaddress,'user','password')
d = rosdevice with properties: DeviceAddress: '192.168.203.131' Username: 'user' ROSFolder: '/opt/ros/indigo' CatkinWorkspace: '~/catkin_ws' AvailableNodes: {'voxel_grid_filter_sl'}
Run a ROS core and check if it is running.
runCore(d)
Another roscore / ROS master is already running on the ROS device. Use the 'stopCore' function to stop it.
running = isCoreRunning(d)
running = logical
1
Stop the ROS core and confirm that it is no longer running.
stopCore(d) pause(2) running = isCoreRunning(d)
running = logical
0
Input Arguments
device
— ROS device
rosdevice
object
ROS device, specified as a rosdevice
object.
Version History
Introduced in R2019b
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)