ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A answers.ros.org
Ask Your Question
0

Regarding transport layer protocols in ROS2 Foxy Fitzroy

asked 2021-01-10 23:35:31 -0500

Aakashp gravatar image

Hi,

In the Concepts page of ROS2 ( https://index.ros.org/doc/ros2/Concep... ) it is said that "Note however that even the reliable policy in ROS 2 is implemented using UDP, which allows for multicasting if appropriate."

So, is there no TCP transport protocol in ROS2 Foxy ?

My another comprehensive question is: What all transport layer protocols are available in ROS2 Foxy Fitzroy ? (as for example in ROS 1 Noetic, TCP and UDP are supported)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-01-11 02:31:38 -0500

gvdhoorn gravatar image

updated 2021-01-11 10:46:58 -0500

As you're probably aware, ROS 2 is built upon the concept of Middleware Interfaces, which abstract from the actual underlying middleware.

One of the main rationales for this design is to allow users / integrators to easily replace whatever middleware is the default with something they want to use. The default right now is DDS, with Fast DDS being the default DDS vendor (this will change to Cyclone DDS in Galactic).

Ultimately, this means that questions such as:

So, is there no TCP transport protocol in ROS2 Foxy ?

do not really have an answer, as there is no direct support in ROS 2 for anything. ROS 2 only supports RMWs, and whatever those RMWs support, ROS 2 supports.

If something is not supported by your configured RMW, ROS 2 will not support it (but again: this is a bit of a strange thing to say, as "ROS 2" will not know what RMW (and ultimately middleware) you have configured).

Perhaps the best answer to your question would be: it depends on what the specific RMW you have configured supports.

My another comprehensive question is: What all transport layer protocols are available in ROS2 Foxy Fitzroy ? (as for example in ROS 1 Noetic, TCP and UDP are supported)

First: please do not include multiple questions in a single post. ROS Answers is a Q&A site (like Stack Overflow), which works best with a 1-to-1 ratio of questions and answers. Multiple questions in a single post have very poor visibility, leading to them getting less answers.

Having written that: I believe what I wrote earlier applies here as well. There is no single answer to your question, as it would depend on what the available RMWs support.

In general you could probably say something like:

  • for DDS based RMWs, UDP will be the default, some will allow you to request a TCP transport
  • for other RMWs, you'd have to check the documentation of the specific middleware they wrap

Edit:

a) When you say

for DDS based RMWs, UDP will be the default, some will allow you to request a TCP transport

I was having the understanding that all RMWs (i.e. FastRTPS, RTI's Connext, Cyclone etc) are DDS based only. If not, then what are other categories of RMWs beside the DDS-based RMWs ?

Please see my answer to your #q369220. There are a number of non-DDS based middlewares with RMWs available.

b) The following line was not clear to me:

as "ROS 2" will not know what RMW (and ultimately middleware) you have configured

I mean, when we select a particular RMW interface, then can ROS2 not know from it that which RMW we are trying to use ?

seeing as you select an RMW using an environment variable, it's certainly possible to inspect that from any ROS 2 node.

What I meant to say is: by design, apart from the RMWs themselves, ROS 2 code is not supposed to be aware of the specific RMW in use. RMWs ... (more)

edit flag offensive delete link more

Comments

@gvdhoorn: Thanks for your response but I have few doubts in your response and I request you humbly to clarify them please. Before that, I apologise for raising a question within a question. My doubts are: a) When you say for DDS based RMWs, UDP will be the default, some will allow you to request a TCP transport

I was having the understanding that all RMWs (i.e. FastRTPS, RTI's Connext, Cyclone etc) are DDS based only. If not, then what are other categories of RMWs beside the DDS-based RMWs ?

b) The following line was not clear to me: as "ROS 2" will not know what RMW (and ultimately middleware) you have configured

I mean, when we select a particular RMW interface, then can ROS2 not know from it that which RMW we are trying to use ?

c) Lastly, I raised this question hoping that the maintainers of ROS2 ...(more)

Aakashp gravatar image Aakashp  ( 2021-01-11 10:26:50 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2021-01-10 23:35:31 -0500

Seen: 509 times

Last updated: Jan 11 '21