Skip to content

Commit 69c3c4b

Browse files
FranFinjamoralp
andauthored
Reworked concepts/middleware section. (#259)
* Reworked concepts/middleware section. * Update _docs/concepts/middleware/Micro_XRCE-DDS/index.md Co-authored-by: Jose Antonio Moral <joseantoniomoralparras@gmail.com> * Update _docs/concepts/middleware/Micro_XRCE-DDS/index.md Co-authored-by: Jose Antonio Moral <joseantoniomoralparras@gmail.com> * Update _docs/concepts/middleware/Micro_XRCE-DDS/index.md Co-authored-by: Jose Antonio Moral <joseantoniomoralparras@gmail.com> * Update _docs/concepts/middleware/rosserial/index.md Co-authored-by: Jose Antonio Moral <joseantoniomoralparras@gmail.com> * Changed unexisting links to exitsting ones. Co-authored-by: Jose Antonio Moral <joseantoniomoralparras@gmail.com>
1 parent a88cf62 commit 69c3c4b

8 files changed

Lines changed: 198 additions & 33 deletions

File tree

_data/docs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
- title: Middleware
2222
docs:
2323
- concepts/middleware/Micro_XRCE-DDS
24+
- concepts/middleware/memo_prof
2425
- concepts/middleware/rosserial
2526
- concepts/middleware/IoT
2627

_docs/concepts/middleware/Micro_XRCE-DDS/index.md

Lines changed: 51 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ permalink: /docs/concepts/middleware/Micro_XRCE-DDS/
44
redirect_from: /docs/concepts/middleware/
55
---
66

7+
This page is dedicated to describing the most salient features of [**Micro XRCE-DDS**](https://micro-xrce-dds.docs.eprosima.com/en/latest/index.html),
8+
the default middleware implementation for micro-ROS' rmw layer.
9+
710
**eProsima Micro XRCE-DDS** is an open-source wire protocol that implements the OMG DDS for e**X**tremely **R**esource **C**onstrained **E**nvironment standard ([DDS-XRCE](https://www.omg.org/spec/DDS-XRCE/)).
811
The aim of the DDS-XRCE protocol is to provide access to the DDS Global-Data-Space from resource-constrained devices.
912
This is achieved thanks to a **client-server** architecture, where low resource devices, called *XRCE Clients*, are connected to a server, called *XRCE Agent*, which acts on behalf of its clients in the DDS Global-Data-Space.
@@ -15,41 +18,74 @@ Micro XRCE-DDS is composed by two main elements:
1518
* [Micro XRCE-DDS Agent](https://github.com/eProsima/Micro-XRCE-DDS-Agent): a **C++11 out-of-the-box application** which implements the XRCE Agent functionality.
1619
* [Micro XRCE-DDS Client](https://github.com/eProsima/Micro-XRCE-DDS-Client): a **C99 library** which implements the XRCE Client side functionality.
1720

18-
Apart of these, Micro XRCE-DDS uses other two components:
21+
In addition, Micro XRCE-DDS uses other two components:
1922

2023
* [Micro CDR](https://github.com/eProsima/Micro-CDR): a **de/serialization engine** used in the Client library.
21-
* [Micro XRCE-DDS Gen](https://github.com/eProsima/Micro-XRCE-DDS-Gen): a **code generator tool** used for generating *Micro CDR* de/serialization function and Client apps examples from IDL sources.
24+
* [Micro XRCE-DDS Gen](https://github.com/eProsima/Micro-XRCE-DDS-Gen): a **code generator tool** used for generating *Micro CDR* de/serialization functions and Client apps examples from IDL sources.
2225

2326
## Application
2427

25-
Micro XRCE-DDS is focused on microcontroller applications which require a publisher/subscriber architecture.
28+
Micro XRCE-DDS is focused on microcontroller applications which require to access a publisher/subscriber architecture.
2629
Some examples of this kind of applications are those found in sensor networks, IoT or robotics.
27-
On this last regard, some companies such as [Renesas](https://www.sensorsmag.com/iot-wireless/mcus-support-dds-xrce-protocol-for-ros-2) and [ROBOTIS](https://xelnetwork.readthedocs.io/en/latest/) are using Micro XRCE-DDS as the middleware solution.
28-
Furthermore, the [micro-ROS](https://microros.github.io) project, whose target is to put ROS 2 onto microcontroller, has adopted Micro XRCE-DDS as the middleware layer.
30+
Some companies such as [Renesas](https://www.sensorsmag.com/iot-wireless/mcus-support-dds-xrce-protocol-for-ros-2) and [ROBOTIS](https://xelnetwork.readthedocs.io/en/latest/) are using Micro XRCE-DDS as a middleware solution.
31+
Furthermore, the [micro-ROS](https://microros.github.io) project, whose goal is to put ROS 2 onto microcontroller, has adopted Micro XRCE-DDS as its default middleware layer.
2932

3033
## Main Features
3134

3235
### Low Resource Consumption
3336

34-
As it was aforementioned, Micro XRCE-DDS is focused on microcontroller applications. Therefore, the design and implementation of this middleware have been carried out taking into account the memory restriction of this kind of devices.
35-
Proof of this is the fact that Micro XRCE-DDS Client is completely dynamic memory free.
36-
From the point of view of memory footprint, the [latest](https://github.com/eProsima/Micro-XRCE-DDS-Client/releases/tag/v1.0.1) version of this library has a memory consumption of less than **75 KB of Flash memory** and **2.5 KB of RAM** for a complete publisher and subscriber application.
37+
As it was mentioned above, Micro XRCE-DDS is focused on microcontroller applications. Therefore, the design and implementation of this middleware have been carried out taking into account the memory constraints of this kind of devices.
38+
A proof of this is the fact that the XRCE Client is completely dynamic memory free.
39+
From the point of view of the memory footprint, the [latest](https://github.com/eProsima/Micro-XRCE-DDS-Client/releases/latest) version of this library has a memory consumption of less than **75 KB of Flash memory** and around **3 KB of RAM** for a complete publisher and subscriber application handling messages sizes on the order of 512 B.
40+
For more detailed information on the memory consumption as a function of message size, entity number and internal memory management of the middleware library, please refer to the [Micro XRCE-DDS memory profiling](/docs/concepts/middleware/memo_prof/) section.
41+
Moreover, this library is highly configurable thanks to a *profile* concept that enables to choose, add or remove some features in configuration time. That allows customizing the XRCE Client library size, if there are features that are not used.
42+
There are several definitions for configuring and building the Client library at compile-time.
43+
These definitions allow to create a version of the library according to the application requirements, and can be modified in the `client.config` file.
44+
For incorporating the desired configuration, it is necessary to run the `cmake` command every time the definitions change.
45+
46+
For more information on how to configure micro-ROS by opportunely tuning parameters either in the Micro XRCE-DDS library
47+
orin its rmw implementation [`rmw_microxrcedds`](https://github.com/micro-ROS/rmw-microxrcedds), consult this [tutorial](/docs/tutorials/core/microxrcedds_rmw_configuration/) and the `rmw_microxrcedds` [README](https://github.com/micro-ROS/rmw-microxrcedds#rmw-micro-xrce-dds-implementation).
3748

3849
### Multi-Transport Support
3950

40-
In contrast to other IoT middleware such as MQTT and CoaP, which work over only a particular transport layer, XRCE support multiple transport protocol natively.
51+
As part of the profiles discussed in the previous section, the user can choose between several transport layers to communicate the Clients with the Agent.
52+
Indeed, in contrast to other IoT middleware such as MQTT and CoaP, which work over only a particular transport layer, XRCE supports multiple transport protocols natively.
4153
In particular, the latest version of Micro XRCE-DDS support: **UDP**, **TCP** and a custom **Serial** transport protocol.
4254

43-
Apart from this, Micro XRCE-DDS has a transport interface for both Agent and Client which allows to implement custom transport in an straight-forward manner.
44-
This makes the port of Micro XRCE-DDS to different platforms and the addition of new transports a task that any user can undertake.
55+
Apart from this, Micro XRCE-DDS has a transport interface for both Agent and Client which allows to implement custom transports in a straightforward manner.
56+
This makes the port of Micro XRCE-DDS to different platforms and the addition of new transports a seamless task that any user can undertake.
4557

4658
### Multi-Platform Support
4759

48-
Micro XRCE-DDS Client support **Windows**, **Linux** and **NuttX** as embedded RTOS.
49-
On the other hand, Micro XRCE-DDS Agent support Windows and Linux platform.
60+
The XRCE Client supports **FreeRTOS**, **Zephyr** and **NuttX** as embedded RTOS. Moreover, it also runs on **Windows** and **Linux**.
61+
On the other hand, the XRCE Agent supports **Windows** and **Linux**.
62+
63+
### QoS support
64+
65+
The XRCE Client library allows the user to use two different approaches for creating DDS entities in the XRCE Agent:
66+
67+
* By XML (the default option)
68+
* By reference
69+
70+
When using the default option, users are enabled to create entities either in Reliable or Best-Effort mode, with the XML files written and stored on the Client side. But these QoS configurations may not fit some users' requirements.
71+
For these cases, Micro XRCE-DDS allows to create entities directly on the Agent, where the user can write custom XML QoS as in DDS.
72+
Each entity available on the Agent will be associated to a label, so that the Clients can to create the entities they need
73+
for the communication by just referring to these labels.
74+
75+
Additionally, using references will also reduce the memory consumption of the Client inside the MCU.
76+
This is because the reference approach allows avoiding to build the parts of the code where XMLs are stored.
77+
78+
Notice that this mechanism is inherited by micro-ROS which, as a consequence, will be able to leverage the same full set of QoS as ROS 2.
79+
For a comprehensive review on how to use custom QoS in micro-ROS, please visit this [dedicated page](/docs/tutorials/core/create_dds_entities_by_ref/) in the tutorials section.
80+
5081

5182
## Other links
5283

5384
* [Manual at Read the Docs](https://micro-xrce-dds.readthedocs.io/en/latest/)
54-
* [GitHub](https://github.com/eProsima/Micro-XRCE-DDS)
55-
85+
* [Micro XRCE-DDS on GitHub](https://github.com/eProsima/Micro-XRCE-DDS)
86+
* [XRCE Client on GitHub](https://github.com/eProsima/Micro-XRCE-DDS-Client)
87+
* [XRCE Agent on GitHub](https://github.com/eProsima/Micro-XRCE-DDS-Agent)
88+
* [rmw_microxrcedds on GitHub](https://github.com/micro-ROS/rmw-microxrcedds)
89+
* [Micro XRCE-DDS memory profiling](/docs/concepts/middleware/memo_prof/)
90+
* [Middleware optimization tutorial](/docs/tutorials/core/microxrcedds_rmw_configuration/).
91+
* [How to use custom QoS in micro-ROS](/docs/tutorials/core/create_dds_entities_by_ref/)
21.6 KB
Loading
38.5 KB
Loading

0 commit comments

Comments
 (0)