2016年ROS1:在多臺(tái)PC上進(jìn)行ROS通訊(在多臺(tái)遠(yuǎn)程機(jī)器人或電腦上運(yùn)行ROS)
2019年ROS2:ROS2網(wǎng)絡(luò)多機(jī)通信DDS和安全加密SROS(多機(jī)器人系統(tǒng))
ROS2配置非常簡(jiǎn)單,注意事項(xiàng)為:如果是局域網(wǎng),只需確保ROS_DOMAIN_ID一致即可。
如果是單片機(jī)需要micro-ros:
esp32與ros2的歡樂(lè)啟程?
micro-ROS之esp32與ros2資料(freertos)
本文補(bǔ)充內(nèi)容:x86和ARM,樹莓派通用,類似pc+pc模式的ROS1。
主機(jī):
從機(jī):
使用工具multimaster-fkie:
?
為了保證配置順利,需要仔細(xì)閱讀原英文文檔!
功能包安裝:
ros@ros:~$ sudo apt install ros-noetic-fkie-
ros-noetic-fkie-master-discovery
ros-noetic-fkie-master-sync
ros-noetic-fkie-message-filters
ros-noetic-fkie-message-filters-dbgsym
ros-noetic-fkie-multimaster
ros-noetic-fkie-multimaster-msgs
ros-noetic-fkie-node-manager
ros-noetic-fkie-node-manager-daemon
ros-noetic-fkie-potree-rviz-plugin
ros-noetic-fkie-potree-rviz-plugin-dbgsym
ros@ros:~$ sudo apt install ros-noetic-fkie-
ros@ros:~$ rosrun fkie_master_discovery master_discovery _robot_hosts:=[192.168.8.111]
[INFO] [1652091021.942514]: ROS Master URI: http://localhost:11311
[INFO] [1652091021.966031]: Check the ROS Master[Hz]: 1
[INFO] [1652091021.970818]: Heart beat [Hz]: 0.02
[INFO] [1652091021.974751]: Active request after [sec]: 60
[INFO] [1652091021.978513]: Remove after [sec]: 300
[INFO] [1652091021.980809]: Robot hosts: ['192.168.8.111']
[INFO] [1652091021.982873]: Approx. mininum avg. network load: 2.72 bytes/s
[INFO] [1652091021.994576]: Start RPC-XML Server at ('0.0.0.0', 11611)
[INFO] [1652091021.998362]: hide_nodes: []
[INFO] [1652091022.001659]: hide_topics: []
[INFO] [1652091022.005370]: hide_services: []
[INFO] [1652091022.007446]: Subscribe to parameter `/roslaunch/uris`
[INFO] [1652091022.134259]: Detected master discovery: http://192.168.8.100:11611
[INFO] [1652091022.242523]: Added master with ROS_MASTER_URI=http://192.168.8.100:11311/
需要配置正確,可以參考官方和相關(guān)博客!?
常見問(wèn)題:
github.com/fkie/multimaster_fkie/issues/144
?
本文摘自 :https://blog.51cto.com/u