0
$\begingroup$

I have ROS2 Humble installed in a Ubuntu 22.04 PC, and WSL2 on my Windows 11. I want to make them communicate together, but I didn't succeed with basic talker/listener. How to achieve that?
I tried several things, first what is on the Microsoft website, with port proxy. But I don't know if I should use a specific port so I tried first with 4000, and then with two others recommended by ChatGPT (I also opened the ports on my Windows Defender Firewall):

Address         Port        Address         Port
--------------- ----------  --------------- ----------
0.0.0.0         4000        192.168.199.165 4000
0.0.0.0         7400        192.168.199.165 7400
0.0.0.0         7600        192.168.199.165 7600

This IP address is the one of my WSL on eth0.

If I ping the Ubuntu PC (192.168.11.15) from my WSL it works, when I ping the Windows PC (192.168.11.50) from the Ubuntu PC it works too. However when I try ros2 multicast send/receive in both way from WSL2 and Ubuntu PC, as well as talker/listener, it is not communicating.

Moreover, I have only Windows 11 Home, so I cannot use Hyper-V manager to set the connection type.

I also tried with CycloneDDS, bu I am not sure if I set the config parameters well. Here on WSL:

<?xml version="1.0" encoding="UTF-8" ?>
<CycloneDDS>
  <Domain>
    <General>
      <NetworkInterfaceAddress>192.168.199.165</NetworkInterfaceAddress>
      <AllowMulticast>true</AllowMulticast>
    </General>
  </Domain>
</CycloneDDS>

and Ubuntu PC:

<?xml version="1.0" encoding="UTF-8" ?>
<CycloneDDS>
  <Domain>
    <General>
      <NetworkInterfaceAddress>192.168.11.15</NetworkInterfaceAddress>
      <AllowMulticast>true</AllowMulticast>
    </General>
  </Domain>
</CycloneDDS>

What should I do to allow the communication of ROS though WSL2?

$\endgroup$

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.