ros2node
Create a ROS 2 node on the specified network
Description
The ros2node
object represents a ROS 2 node, and allows you to
communicate with the rest of the ROS 2 network. You have to create a node before you can
create publishers and subscribers.
Creation
Description
initializes a ROS 2 node with the given node
= ros2node(Name
)Name
. The node will be on the
network specified by the domain identification 0
, unless otherwise
specified by the ROS_DOMAIN_ID
environment variable.
By default the node uses the 'rmw_fastrtps_cpp'
ROS middleware
(RMW) implementation unless otherwise specified by the
RMW_IMPLEMENTATION
environment variable. Set the
RMW_IMPLEMENTATION
environment variable before creating the
ros2node
object. For example,
setenv('RMW_IMPLEMENTATION','rmw_cyclonedds_cpp')
sets the RMW
implementation to 'rmw_cyclonedds_cpp'
. For more information on RMW
implementations see Switching Between ROS Middleware Implementations.
Input Arguments
Properties
Object Functions
delete | Remove reference to ROS 2 node |