Skip to content

Commit 2c970e6

Browse files
beniaminopozzanhamishwillee
authored andcommitted
docs: clarify Micro-XRCE-DDS-Agent versions ROS 2 compatibility (PX4#25591)
--------- Signed-off-by: Beniamino Pozzan <beniamino.pozzan@gmail.com> Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
1 parent 3486765 commit 2c970e6

1 file changed

Lines changed: 53 additions & 6 deletions

File tree

docs/en/middleware/uxrce_dds.md

Lines changed: 53 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -106,12 +106,19 @@ The development version, fetched using `--edge` above, does work.
106106

107107
### Build/Run within ROS 2 Workspace
108108

109-
The agent can be built and launched within a ROS 2 workspace (or build standalone and launched from a workspace.
109+
The agent can be built and launched within a ROS 2 workspace (or build standalone and launched from a workspace).
110110
You must already have installed ROS 2 following the instructions in: [ROS 2 User Guide > Install ROS 2](../ros2/user_guide.md#install-ros-2).
111111

112112
::: warning
113113
This approach will use the existing ROS 2 versions of the Agent dependencies, such as `fastcdr` and `fastdds`.
114-
This considerably speeds up the build process but requires that the Agent dependency versions match the ROS 2 ones.
114+
This considerably speeds up the build process but requires that the Agent dependency versions match the ROS 2 ones:
115+
116+
| ROS 2 version | Micro-XRCE-DDS-Agent version |
117+
| ------------- | ---------------------------- |
118+
| Foxy | v2.4.2 |
119+
| Humble | v2.4.2 |
120+
| Jazzy | v2.4.3 |
121+
115122
:::
116123

117124
To build the agent within ROS:
@@ -124,15 +131,50 @@ To build the agent within ROS:
124131

125132
1. Clone the source code for the eProsima [Micro-XRCE-DDS-Agent](https://github.com/eProsima/Micro-XRCE-DDS-Agent) to the `/src` directory (the `main` branch is cloned by default):
126133

134+
::::tabs
135+
136+
::: tab jazzy
137+
127138
```sh
128139
cd ~/px4_ros_uxrce_dds_ws/src
129140
git clone -b v2.4.3 https://github.com/eProsima/Micro-XRCE-DDS-Agent.git
130141
```
131142

143+
:::
144+
145+
::: tab humble
146+
147+
```sh
148+
cd ~/px4_ros_uxrce_dds_ws/src
149+
git clone -b v2.4.2 https://github.com/eProsima/Micro-XRCE-DDS-Agent.git
150+
```
151+
152+
:::
153+
154+
::: tab foxy
155+
156+
```sh
157+
cd ~/px4_ros_uxrce_dds_ws/src
158+
git clone -b v2.4.2 https://github.com/eProsima/Micro-XRCE-DDS-Agent.git
159+
```
160+
161+
:::
162+
163+
::::
164+
132165
1. Source the ROS 2 development environment, and compile the workspace using `colcon`:
133166

134167
:::: tabs
135168

169+
::: tab jazzy
170+
171+
```sh
172+
source /opt/ros/jazzy/setup.bash
173+
colcon build
174+
```
175+
176+
:::
177+
136178
::: tab humble
137179

138180
```sh
@@ -161,6 +203,15 @@ To run the micro XRCE-DDS agent in the workspace:
161203

162204
:::: tabs
163205

206+
::: tab jazzy
207+
208+
```sh
209+
source /opt/ros/jazzy/setup.bash
210+
source install/local_setup.bash
211+
```
212+
213+
:::
214+
164215
::: tab humble
165216

166217
```sh
@@ -230,7 +281,6 @@ The configuration can be done using the [UXRCE-DDS parameters](../advanced_confi
230281

231282
- [UXRCE_DDS_CFG](../advanced_config/parameter_reference.md#UXRCE_DDS_CFG): Set the port to connect on, such as `TELEM2`, `Ethernet`, or `Wifi`.
232283
- If using an Ethernet connection:
233-
234284
- [UXRCE_DDS_PRT](../advanced_config/parameter_reference.md#UXRCE_DDS_PRT):
235285
Use this to specify the agent UDP listening port.
236286
The default value is `8888`.
@@ -240,7 +290,6 @@ The configuration can be done using the [UXRCE-DDS parameters](../advanced_confi
240290
The default value is `2130706433` which corresponds to the _localhost_ `127.0.0.1`.
241291

242292
You can use [Tools/convert_ip.py](https://github.com/PX4/PX4-Autopilot/blob/main/Tools/convert_ip.py) to convert between the formats:
243-
244293
- To obtain the `int32` version of an IP in decimal dot notation the command is:
245294

246295
```sh
@@ -254,14 +303,12 @@ The configuration can be done using the [UXRCE-DDS parameters](../advanced_confi
254303
```
255304

256305
- If using a serial connection:
257-
258306
- [SER_TEL2_BAUD](../advanced_config/parameter_reference.md#SER_TEL2_BAUD), [SER_URT6_BAUD](../advanced_config/parameter_reference.md#SER_URT6_BAUD) (and so on):
259307
Use the `_BAUD` parameter associated with the serial port to set the baud rate.
260308
For example, you'd set a value for `SER_TEL2_BAUD` if you are connecting to the companion using `TELEM2`.
261309
For more information see [Serial port configuration](../peripherals/serial_configuration.md#serial-port-configuration).
262310
263311
- Some setups might also need these parameters to be set:
264-
265312
- [UXRCE_DDS_KEY](../advanced_config/parameter_reference.md#UXRCE_DDS_KEY): The uXRCE-DDS key.
266313
If you're working in a multi-client, single agent configuration, each client should have a unique non-zero key.
267314
This is primarily important for multi-vehicle simulations, where all clients are connected in UDP to the same agent.

0 commit comments

Comments
 (0)