ros2 rti dds cross communications example?

asked 2019-01-17 22:56:12 -0600

Jim N gravatar image

updated 2019-01-18 02:38:11 -0600

gvdhoorn gravatar image

Does anyone know of an example of an RTI connext DDS node reading/writing with a ROS2 node? I have been using RTI connext for the last few years and am jumping back into ROS, via ROS2. However, i am at a loss as to how to take my IDLs and turn them into a .msg.

For example: what would this look like as a .msg? depth.idl and fluidpressure.idl

depth.idl:

include "fluid pressure.idl"

module robot
{

    const octet WATER_TYPE_SALT = 1;

    struct depth
    {
        sensor::msg::dds::fluidpressure pressure;
        string id;    //@key
        float depth;
    };
};

fluidpressure.idl:

module sensor
{  

    module msg
    {

        module dds
        {
            struct fluidpressure
            {
                double fluid_pressure;
                double variance;
            };
        };
     };
};

Is it as simple as saying:

depth.msg:

const byte WATER_TYPE_SALT = 1

sensor/msg/dds/fluidpressure   pressure

float32 depth

and fluidpressure.idl:

double32  fluid_pressure

double32  variance

?

Thanks

Jim

edit retag flag offensive close merge delete