The goal of this guide is help you download and compile OpenDDS for Linux on the Raspberry Pi and run a simple example.
Build Directions

    For this guide you need a Raspberry Pi set up with Raspbian Linux and connected to a local network. You will also need a Linux host system connected to the same network where we will build OpenDDS. This guide also assumes you know the address and user credentials of the Pi. Perform these all these steps on the host computer:

  1. Ensure that your host environment has:

    • a C++ compiler
    • GNU Make
    • Perl
    • Optional Java SDK 1.5 through 1.8 for Java JNI binding support

    See Building for a complete list of dependencies and supported platforms.

  2. Download and extract the latest tar.gz file from the download site.
  3. Download and extract the Raspberry Pi toolchain from GitHub. Copy or note the absolute path of it, because we need to pass that to OpenDDS's build system.
  4. Enter the OpenDDS-<version> directory
  5. Run the following as a single command, replacing <PITOOLS> with the absolute path of the toolchain:
    ./configure --target=linux-cross\
    • If you want to use OpenDDS's Java bindings and examples, add --java to the end of this command.
    • If you have a 32-bit system, remove the "-x64" part of the command. This shouldn't be necessary though, unless you are running an older system.

  6. make

See Support if you encounter problems with configuration or building.

Copying OpenDDS to the Pi

There are multiple ways to do this, including using a flash drive. This method uses the network.

  1. Leave the OpenDDS-<version> directory: cd ..
  2. tar czf OpenDDS.tar.gz OpenDDS-<version>
  3. scp OpenDDS.tar.gz USER@ADDRESS: where USER and ADDRESS are the username and IP address of your Raspberry Pi. It will ask you for the password for the user on the Pi.
  4. ssh USER@ADDRESS to access the Pi, taking the same information as the previous command.
  5. tar xzf OpenDDS.tar.gz
Run the Messenger Example
  1. While still in ssh on the Pi, enter the OpenDDS-<version> directory
  2. export DDS_ROOT="$PWD/build/target"
  3. export ACE_ROOT="$DDS_ROOT/ACE_wrappers"
  5. export PATH=${PATH}:"$ACE_ROOT/bin":"$DDS_ROOT/bin"
  6. cd $DDS_ROOT/DevGuideExamples/DCPS/Messenger for C++ example or cd $DDS_ROOT/java/tests/messenger for Java example
  7. ./

The Messenger Example starts an InfoRepo, publisher, and subscriber. The InfoRepo allows the publisher and subscriber to find each other. Once the publisher finds the subscriber, it sends 10 messages to the subscriber and waits 30 seconds for the subscriber to acknowledge the messages.

Next Steps

See Chapter 2 of the Developer's Guide for a detailed explanation of the Messenger C++ Example or Chapter 11 for the Java Example.