Generic DDS subscriber

Overview

rtctkGenDdsSub is a troubleshooting tool to subscribe to DDS Agnostic DDS topic(s). It can be used for verifying if DDS agnostic topic data is being published. For example, it can be used to determin if the DDS topic can be received on a particular machine, and the frequency of the incomming data. When used with MUDPI Publisher and the setting to produce pattern data (ramp), it is possible to check the received data for consistency. It can be run instead of (or in parallel with) other DDS subscribers like Telemetry Subscriber. For troubleshooting and diagnostic FastDDS related problems some additional tools like fastddsMonitor can be used. These additional tools are provided as part of FastDDS.

Prerequisites

Similar to other DDS based applications, the generic DDS publisher uses FastDDS as well. Its DDS QoS is configured using an XML file. Default provided telemDataPathDdsQos.xml is installed in $INTROOT/resource/config/rtctk/dds/ A different file can be specified using the --qos-file command line option. The file needs to be located under rtctk/dds/ in $CFGPATH.

Note

FASTRTPS_DEFAULT_PROFILES_FILE environment variable shall not be used (set). In particular if the file that the variable points to contains the same QoS profiles.

Running

The generic DDS subscriber is run by simply executing: rtctkGenDdsSub with the proper command line arguments. For a list of command line options run the executable with option -h.

E.g. run the subscriber and subscribe to three topics: TestTopic0 TestTopic1 TestTopic2

$ rtctkGenDdsSub -t TestTopic0 TestTopic1 TestTopic2

Messages are logged every 1500 samples for each subscribed topic with the number of received samples, the average time between sample receiving, and the estimated (receiving) frequency. E.g. for TestTopic0:

[TestTopic0][0] 1500 Avg: 0.00113551 Freq: 880.659
[TestTopic0][0] 3000 Avg: 0.00114717 Freq: 871.71
[TestTopic0][0] 4500 Avg: 0.00115725 Freq: 864.118
...

Messages are also logged that indicate that a particular topic (e.g. TestTopic0) is there for a DDS publisher and that the process is subscribed to it. These messages are printed before any data will be received. For example:

GenSubReaderListener(TestTopic0)::on_subscription_match
GenSubReaderListener(TestTopic0)::on_liveliness_changed:  alive_count: 1  not_alive_count: 0  alive_count_change: 1  not_alive_count_change: 0

The following message indicates that a DDS publisher for a particular topic (e.g. TestTopic0) is gone:

GenSubReaderListener(TestTopic00)::on_liveliness_changed:  alive_count: 0  not_alive_count: 1  alive_count_change: -1  not_alive_count_change: 1

Stopping

The process can be stopped using Ctrl-C.