编辑
2024-04-09
笔记
0

目录

ROS2-Desktop-Full Gui
ROS2-Desktop Cli
docker-compose.yml
micro-ROS Agent in Docker
拉取 arm64 架构镜像
导出镜像

ROS2-Desktop-Full Gui

shell
xhost + && sudo docker run -it --rm --net=host -v /dev:/dev -v $HOME/.Xauthority:/root/.Xauthority:ro -e DISPLAY=unix$DISPLAY osrf/ros:humble-desktop-full

ROS2-Desktop Cli

bash
# talker docker run -it --rm osrf/ros:humble-desktop ros2 run demo_nodes_cpp talker # listener docker run -it --rm osrf/ros:humble-desktop ros2 run demo_nodes_cpp listener

docker-compose.yml

yml
version: '2' services: talker: image: osrf/ros:humble-desktop command: ros2 run demo_nodes_cpp talker listener: image: osrf/ros:humble-desktop command: ros2 run demo_nodes_cpp listener depends_on: - talker

micro-ROS Agent in Docker

bash
# UDPv4 micro-ROS Agent sudo docker run -it --rm --net=host microros/micro-ros-agent:$ROS_DISTRO udp4 --port 8888 -v6 # Serial micro-ROS Agent sudo docker run -it --rm -v /dev:/dev --privileged --net=host microros/micro-ros-agent:$ROS_DISTRO serial -b 115200 --dev [YOUR BOARD PORT] -v6 # TCPv4 micro-ROS Agent sudo docker run -it --rm --net=host microros/micro-ros-agent:$ROS_DISTRO tcp4 --port 8888 -v6 # CAN-FD micro-ROS Agent sudo docker run -it --rm -v /dev:/dev --privileged --net=host microros/micro-ros-agent:$ROS_DISTRO canfd --dev [YOUR CAN INTERFACE] -v6

拉取 arm64 架构镜像

shell
docker pull --platform=arm64

导出镜像

shell
docker save osrf/ros:humble-desktop-full | pigz -9 -p 16 > humble-desktop-full.tgz **```**

本文作者:菜鸟

本文链接:

版权声明:本博客所有文章除特别声明外,均采用 署名-非商业性使用-相同方式共享 4.0 国际 (CC BY-NC-SA 4.0) 许可协议。转载请注明出处!