Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Limit network access to micro ros agent #957

Open
fitocuan opened this issue Aug 25, 2023 · 1 comment
Open

Limit network access to micro ros agent #957

fitocuan opened this issue Aug 25, 2023 · 1 comment

Comments

@fitocuan
Copy link

Hi,

I am very new with ROS2 Fast DDS and I've been using ROS2 humble to communicate multiple PCs through a LAN network (192.168.3.x). Each PC controls two robots via TCP (192.168.2.x), this network has been hidden from the Fast DDS by configuring with the following whitelist in the XML code.

This works as expected. However, when I connect a Raspberry Pi Pico docker agent with microros the topics passed through the PCs are initially slowed down and then recover back to normal after 1-2 minutes.

I suspect the issue is the microros agent is trying communicate with the robot's network, as when I disconnect the robots everything works fine. Is there a way to configure a whitelist inside the microrosagent?

<?xml version="1.0" encoding="UTF-8" ?>
<profiles xmlns="http://www.eprosima.com/XMLSchemas/fastRTPS_Profiles">
        <transport_descriptors>
            <transport_descriptor>
                <transport_id>CustomTcpTransport2</transport_id>
                <type>TCPv4</type>
                <interfaceWhiteList>
                    <address>192.168.3.7</address>
                    <address>127.0.0.1</address>
                </interfaceWhiteList>
            </transport_descriptor>
        </transport_descriptors>
        
        <transport_descriptors>
            <transport_descriptor>
                <transport_id>CustomUDPTransport2</transport_id>
                <type>UDPv4</type>
                <interfaceWhiteList>
                    <address>192.168.3.7</address>
                    <address>127.0.0.1</address>
                </interfaceWhiteList>
            </transport_descriptor>
        </transport_descriptors>

        <!-- default publisher profile -->
        <publisher profile_name="default_publisher" is_default_profile="true">
            <historyMemoryPolicy>PREALLOCATED_WITH_REALLOC</historyMemoryPolicy>
            <qos>
                <publishMode>
                    <kind>ASYNCHRONOUS</kind>
                </publishMode>  
                
            </qos>
        </publisher>

        <!-- default subscriber profile -->
        <subscriber profile_name="default_subscriber" is_default_profile="true">
            <historyMemoryPolicy>PREALLOCATED_WITH_REALLOC</historyMemoryPolicy>
            
        </subscriber>

        

   
        <participant profile_name="CustomTcpTransportParticipant2" is_default_profile="true">
            <rtps>

                <useBuiltinTransports>false</useBuiltinTransports>
                <userTransports>
                    <transport_id>CustomTcpTransport2</transport_id>
                </userTransports>
                
                
            </rtps>
        </participant>
        
        <participant profile_name="CustomUDPTransportParticipant2" is_default_profile="true">
            <rtps>

                <useBuiltinTransports>false</useBuiltinTransports>
                <userTransports>
                    <transport_id>CustomUDPTransport2</transport_id>
                </userTransports>
                
            </rtps>
        </participant>
        
</profiles>
@pablogs9
Copy link
Member

pablogs9 commented Sep 4, 2023

Hello, this issue shall be moved to the Fast DDS repo, in micro-ROS Agent, the middleware is configured via XML files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants