ros2 nodes on different subnets
Hello,
i'm trying to make ros2 communication work between hosts on different subnets using the latest (dashing) release. i have 2 hosts, one 192.168.2.22 and one 192.168.1.40. i use the following DEFAULT_FASTRTPS_PROFILES.xml:
<?xml version="1.0" encoding="UTF-8" ?>
<profiles>
<participant profile_name="participant_somename" is_default_profile="true">
<rtps>
<builtin>
<metatrafficUnicastLocatorList>
<locator/>
</metatrafficUnicastLocatorList>
<domainId>4</domainId>
<initialPeersList>
<locator>
<udpv4>
<address>192.168.1.40</address>
</udpv4>
</locator>
<locator>
<udpv4>
<address>192.168.2.22</address>
</udpv4>
</locator>
</initialPeersList>
</builtin>
</rtps>
</participant>
</profiles>
this makes the simple demo_nodes_cpp talker and listener work, but 2 nodes on the same machine can't exchange images anymore (eg cam2image and showimage). When i remove the metatrafficUnicastLocatorList, the local communication works again, but then the remote talker/listener scenario doesn't work anymore.
Anybody knows what i'm doing wrong ? Greetings, Frank
Seems for simple cases the above example xml just works, but as i add more nodes things start to break. So i suspect a bug in FastRTPS unicast locators.
So i found out that the maximum initial peers is probably too small for my situation, and the fast-RTPS unicast discovery only probes 3 participants on every peer by default. still trying to figure out how to change maxInitialPeers in this XML