Your first steps with Zenoh as an RMW in ROS 2
Built by the Zenoh team at ZettaScale with ❤️
Welcome! This repository is part of the Demystifying ROS 2 Networking
workshop, scheduled to take place on October 21st at ROSCon 2024. It contains all the resources you’ll need to get started with rmw_zenoh
, the Zenoh middleware for ROS 2
.
In this hands-on workshop, you’ll explore how to leverage Zenoh as a ROS 2 middleware (RMW) layer. Whether you're new to Zenoh or looking to deepen your understanding of it, this workshop is designed to give you practical insights through simple demonstrations.
What's Included:
- Some introduction slides showing an overview of both Zenoh and
rmw_zenoh
. - Dockerized environment: Pre-configured for easy setup and reproducibility.
- Simple ROS 2 applications: Designed to showcase the use of rmw_zenoh.
- Scripts and utilities: Simplifying container management, environment setup and configuration files.
Get ready to dive into the exciting world of ROS 2 networking with Zenoh!
This workshop runs entirely within Docker containers, so you’ll need a host machine with Docker installed. Both amd64
and arm64
architectures are supported.
The easiest way to get the image is by pulling it from Docker Hub:
docker pull zettascaletech/roscon2024_workshop
Alternatively, you can clone this repository and build the image yourself using the provided build_image.sh
script. By default, the image will be named roscon2024_workshop, or you can specify a different name by setting the $IMAGE_NAME environment variable.
./docker/build_image.sh
The image includes ROS 2 Jazzy Jalisco (core) with pre-installed demo ROS 2 packages. It also has a workspace at /ros_ws
where rmw_zenoh
is already built and installed from source. Both the ROS 2 Jazzy environment and the workspace will be automatically set up when you start a bash session (see the /root/.bashrc
file for details).
The docker directory contains several scripts to help manage the container:
- Run
./docker/create_container.sh
to create a container namedroscon2024_workshop
, or use the$CONTAINER_NAME
environment variable to specify a custom name. The container will use the host network (--net host
). Important directories in the container include:/ros_ws
: The ROS workspace/ros_ws/src/rmw_zenoh
: Thermw_zenoh
source code (already built and installed in the workspace)/ros_ws/zenoh_confs
: A volume mapped to thezenoh_confs/
directory in this repository
- Run
./docker/login_container.sh
to start a bash shell inside the container - Run
./docker/restart_container.sh
to restart the container - Run
./docker/stop_container.sh
to stop the container - Run
./docker/rm_container.sh
to delete the container - Run
./docker/rm_image.sh
to delete the Docker image
This step is optional...
...since rmw_zenoh sources are already pulled from a recent version in /ros_ws/src/rmw_zenoh
and build and installed.
However, you can refresh and re-build rmw_zenoh from sources running the following commands:
cd /ros_ws/src/rmw_zenoh
git pull
cd /ros_ws
colcon build --cmake-args -DCMAKE_BUILD_TYPE=Release