3.10. Examples

Connext DDS Micro provides buildable example applications, in the example/ directory of its host bundle. They include a basic HelloWorld application presented in a few different flavors, an RTPS-only emitter, and latency and throughput benchmarking applications.

Each example comes with instructions on how to build and run an application.

All examples are available in C, while the HelloWorld_dpde and HelloWorld_dpde_waitset examples are available in C++.

Note that by the default all the examples link against release libraries. To build release libraries:

./resource/scripts/rtime-make --name x64Darwin17clang9.0 --target self --build --config Release

To build the examples against the debug libraries, specify the the DEBUG option:

make DEBUG=Y
  • Helloworld_dpse. Shows how to use rtiddsgen to generate type-support code from a simple HelloWorld IDL-defined type. This examplecreates a publisher and subscriber, and uses dynamic participant, static endpoint discovery to establish communication.
  • HelloWorld_dpde. Same as the HelloWorld_dpse example, except it uses dynamic participant, dynamic endpoint discovery. This example is available in both C and C++.
  • HelloWorld_dpde_waitset. Same as the HelloWorld_dpde example, except it uses waitsets instead of listener callbacks to access received data.
  • HelloWorld_dpde_secure Same as the HelloWorld_dpde example, except that the RTI Security Plugins are installed and enabled on each DomainParticipant to perform mutual authentication, enforce access control rules, and encrypt data exchanged by applications.
  • HelloWorld_android. Example application using Android™ NDK.
  • HelloWorld_static_udp. Same as HelloWorld_dpde, except it uses static configuration of network interfaces.
  • HelloWorld_appgen. Example application using Application Generation API.
  • HelloWorld_transformations. Same as HelloWorld_dpde, except it uses UDP transformations to send encrypted packets using OpenSSL.
  • RTPS. Example of an RTPS emitter that bypasses the DDS module and APIs to send RTPS discovery and user data.
  • Latency. Measures the end-to-end latency of Connext DDS Micro.
  • Throughput. Measures the end-to-end throughput of Connext DDS Micro.