Ask Your Question
1

Are there examples of DEFAULT_FASTRTPS_PROFILES.xml?

asked 2018-10-30 13:47:03 -0600

MisterblueGuy gravatar image

Configuring FastRTPS for static IP addresses and streaming seems to be to create a DEFAULT_FASTRTPS_PROFILES.xml file to specify parameters. The eProsima "ROS2 Fine Tuning" presentation from ROSCon'17[1] hints at "InitialPeers" and "metatrafficUnicastLocatorList" XML elements. I can't find any other documentation on this XML file usage. The User Guide for FastRTPS[3] has a few scattered mentions and example snippets and the XSD files in the FastRTPS github repository[2] don't even define all the fields mentioned in the presentation.

The question is, are there any complete examples of DEFAULT_FASTRTPS_PROFILES.xml usages? Say I have 3 computers with static IP addresses that can't multicast to each other. What would the XML file be?

Or, most likely, can someone point me to the documentation that I have overlooked.

[1] https://roscon.ros.org/2017/presentat...

[2] https://github.com/eProsima/Fast-RTPS

[3] https://eprosima-fast-rtps.readthedoc...

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-11-14 09:20:03 -0600

tompe17 gravatar image

updated 2018-11-14 09:21:21 -0600

I am also looking for examples and documentation... In a discussion on discource I got the syntax for what you like to do. The file should look like this:

<?xml version="1.0" encoding="UTF-8" ?>
<profiles>
    <participant profile_name="participant_profile" is_default_profile="true">
        <rtps>
            <builtin>
                <metatrafficUnicastLocatorList>
                    <locator/>
                </metatrafficUnicastLocatorList>
                <initialPeersList>
                    <locator>
                        <address>10.8.0.2</address>
                    </locator>
                    <locator>
                        <address>10.8.0.3</address>
                    </locator>
                    <locator>
                        <address>10.8.0.4</address>
                    </locator>
                    <locator>
                        <address>10.8.0.5</address>
                    </locator>
                    <locator>
                        <address>10.8.0.6</address>                      
                    </locator>
                    <locator>
                        <address>10.8.0.7</address>                      
                    </locator>
                    <locator>
                        <address>10.8.0.8</address>                      
                    </locator>
                </initialPeersList>
            </builtin>
        </rtps>
    </participant>
</profiles>
edit flag offensive delete link more

Comments

This is a great start but it doesn't seem to be working for me. I'll spend some time figuring out how to get FASTRTPS to log so I can find out why I don't seem to have initial participants being set.

MisterblueGuy gravatar imageMisterblueGuy ( 2018-11-18 01:18:25 -0600 )edit

I found why it wasn't working for me -- the participant discovery was still working and getting tied up on different network interfaces. The fix is to add to the answer's XML <use_simple_rtps_pdp>"false"</use_simple_rtps_pdp> before the <initialpeerslist>.

MisterblueGuy gravatar imageMisterblueGuy ( 2018-11-29 13:52:15 -0600 )edit

Another note, if the port number is not specified in the initialPeersList locator, FastRTPS internally generates four locator entries for four possible default port numbers. The defaults are 7410, 7412, 7414, and 7416. If one has multiple domains, add 250 * domainID.

MisterblueGuy gravatar imageMisterblueGuy ( 2018-11-29 14:01:03 -0600 )edit

I noticed in my comment, the XML was lower-case-ified. I don't know how smart TinyXML2 is about element case, but the element tag is defined as 'use_SIMPLE_RTPS_PDP' and not all lower case.

MisterblueGuy gravatar imageMisterblueGuy ( 2018-11-29 14:04:18 -0600 )edit

The syntax has changed (for crystal and fasrtps 1.7.2) and is now:

<locator>
  <udpv4>
    <address>10.8.0.2</address>
  </udpv4>
</locator>

Setting use_simple_rtps_pdp to false breaks things for me, if it doesn't work, also check that you use the same domainid on both computers... (took me a couple of hours to figure that one out...)

Cyrille Berger gravatar imageCyrille Berger ( 2019-05-14 01:04:30 -0600 )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

2 followers

Stats

Asked: 2018-10-30 13:47:03 -0600

Seen: 299 times

Last updated: Nov 14 '18