当前位置:网站首页>[ROS] (05) ROS Communication - Node, Nodes & Master
[ROS] (05) ROS Communication - Node, Nodes & Master
2022-08-02 14:19:00 【CynalFly】
The article is just a study note in the personal learning process, the main reference is ROS tutorial1a>.
1. Concepts
Nodes: A node is an executable file that can communicate with other nodes through ROS.
Node Manager (Master): ROS's naming service, eg to help nodes discover each other.
2, Nodes
A node (Node) is actually just an executable file in the ROS package (executable file generated by C++ compilation, python script), and the executable file becomes a process after running,This process is called node in ROS..ROS nodes use the ROS client library to communicate with other nodes.Nodes can publish or subscribe to topics, and can also provide or consume services.A ROS control system includes many nodes, such as unmanned vehicles, one node (Node) controls the wheel motor of the unmanned vehicle, one node (Node) obtains positioning information through inertial navigation, one node (Node) obtains image information through the camera, and one node (Node) obtains image information through the camera.Node (Node) integrates various information to execute path planning and so on.
ROS client libraries allow nodes written in different languages to communicate with each other:
- roscpp=C++ client
- rospy=python client
3, Master
The robot is a systematic implementation with many components, huge functions and high complexity.In practical applications, the robot may integrate various sensors such as lidar, inertial navigation, millimeter-wave radar, camera, GPS, and motion control devices to be responsible for functions such as perception, control, decision-making, and calculation. Each function point is aIndividual Nodes.So how to manage, allocate and control these nodes?This uses the ROS Master, which provides naming and registration services for the rest of the nodes in the ROS system.The role of the Master is to enable each ROS node (Nodes) to locate each other, and then to carry out point-to-point communication.
4, rosnode
rosnode is a command line tool for displaying information about ROS nodes.The commands are:
| Command | Features |
|---|---|
| rosnode ping | Test the connection to the node |
| rosnode list | List active nodes |
| rosnode info | Print information about the node |
| rosnode machine | List nodes on the specified device |
| rosnode kill | kill a running node |
| rosnode cleanup | Clear unconnectable nodes |
When using ctrl+C to stop the node, the node is not completely cleared, you can use
rosnode cleanupto clear the node.
5. Example test
#Step 1: (ROS primary operation) Run the roscore command to start the master, which is responsible for ros node registration, parameter server, topic communication management, etc.
#Step 2: Runrosnode related commands.
/rosoutThis node is used to collect and log debug output from the node, which is always running.
ROS.otg. ROS Tutorial[EB/OL]. 2020-12-22[2022-7-5].
http://wiki.ros.org/en/ROS/Tutorials. ︎
边栏推荐
猜你喜欢
随机推荐
如何解决mysql服务无法启动1069
[ROS] (04) Detailed explanation of package.xml
微信小程序-最近动态滚动实现
瑞吉外卖笔记——第10讲Swagger
[ROS](04)package.xml详解
[ROS](01)创建ROS工作空间
Audio processing: floating point data stream to PCM file
shell脚本“画画”
web测试和app测试的区别?
你接受不了60%的暴跌,就没有资格获得6000%的涨幅 2021-05-27
瑞吉外卖笔记——第05讲Redis入门
关于密码加密的一点思路
Geoffery Hinton:深度学习的下一个大事件
php开源的客服系统_在线客服源码php
Sentinel源码(六)ParamFlowSlot热点参数限流
drf源码分析与全局捕获异常
ping命令的使用及代码_通过命令查看ping路径
Interview | with questions to learn, Apache DolphinScheduler Wang Fuzheng
What are the file encryption software?Keep your files safe
How to solve mysql service cannot start 1069
创建&编译ROS软件包Package](/img/c2/5931d5cbade509c6ca34d66a274756.png)








