<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>ANIMO, Framework to simplify the real-time distributed communication</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Y. Rodríguez</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>C. Alejo</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>I. Alejo</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>A. Viguria</string-name>
          <email>aviguria@catec.aero</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Center for Advanced Aerospace Technologies (CATEC)</institution>
          ,
          <addr-line>41309, La Rinconada (Sevilla)</addr-line>
          ,
          <country country="ES">Spain</country>
        </aff>
      </contrib-group>
      <fpage>16</fpage>
      <lpage>26</lpage>
      <abstract>
        <p>This paper presents a communication framework developed for interconnecting multi-systems based on the Data Distribution Service (DDS). The new built framework, called ANIMO, facilitates the integration of DDS in an application and the interoperability between the different data types of the Cooperating Objects (COs) with the great feature of real-time. Furthermore, a powerful tool to generate code has been developed bringing the incorporation and the updating of the data types as a very easy and simple task. In addition, a novel module has been performed to give the capacity to communicate the ANIMO framework with the ROS middleware that makes even more easier the integration of mobile robots as another Cooperating Object. This paper explains the complete architecture of the ANIMO framework, its diversity of possibilities and two principal works where it has been applied. One is a distributed simulator to validate embedded control algorithms. The other is the task of the supervision and message passing between quadrotors in an experiment of coordination and cooperation involving multiple aerial vehicles.</p>
      </abstract>
      <kwd-group>
        <kwd>Software communication layer</kwd>
        <kwd>Real-time</kwd>
        <kwd>Distributed</kwd>
        <kwd>Multisystems</kwd>
        <kwd>Quality of Service</kwd>
        <kwd>Interoperability</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>
        The increasing usage of heterogeneous systems jointly, such as variety of sensors,
microcontrollers, PCs, robots, etc., and which are distributed in an environment,
implicates a more effort on inevitable tasks of integration and communication between
them. In these cases, where the importance of the work lies in the development of
applications and algorithms and not how the system data are available and
interchangeable, a communication software fast tuning and high performance is desired.
Also, many engineering applications related to smart cities require this data fusion to
be performed in real time. For instance, efficient distributed video surveillance
requires that real-time constraints be respected or, at least, quality of service guarantees
(QoS) be provided [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]. In order to fulfill this necessity, the communication
framework, called ANIMO, has been developed. Along this paper, the ANIMO framework
will be explained.
      </p>
      <p>The communication model underlying in network software is the most important
factor in how applications communicate. The communications model impacts the
performance, the ease to accomplish different communication transactions, the nature
of detecting errors, and the robustness to different error conditions. Unfortunately,
different communications models are better suited to handle different classes of
application domains. The three main types of network communications models are:
pointto-point, client-server and publish-subscribe.</p>
      <p>
        For many applications related to cooperating objects in smart cities, the
publishsubscribe communications model is the one that best suit its requirements since it is
the best choice for systems with complex time-critical data flows [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]. Computer
applications (nodes) “subscribe” to data they need and “publish” data they want to
share. Messages pass directly between the publisher and the subscribers, rather than
moving into and out of a centralized server. Publish-subscribe communication
architectures are good for distributing large quantities of time-sensitive information
efficiently, even in the presence of unreliable delivery mechanisms.
      </p>
      <p>
        Taking into account the above, distributed applications and satisfying real-time, the
ANIMO framework has been developed based on open standard of the Data
Distribution Service for Real-Time Systems (DDS) from the Object Management Group
(OMG). A well known open-source implementation of the DDS is the RTI (Real
Time Innovations) DDS, which has been used in this work. Studies show that DDS
implementations perform significantly better than non-DDS alternatives and are
wellsuited for certain classes of data-critical DRE information management systems [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ].
      </p>
      <p>In addition, other software modules have been built facilitating the integration of
systems and devices, the interoperability between their different data types and the
maintenance and enlargement of the framework itself. Moreover, the network features
needed for an application can be adjusted to the network constraints through a wide
Quality of Service controls (configuration parameters), achieving a high throughput.</p>
      <p>The paper is organized as follows. In the next section the new developed
framework, called ANIMO, based on the DDS is described. In Section 3, a brief description
of two research projects, where the ANIMO framework has been successfully applied,
is exposed and illustrated with results obtained from experiments. Finally, the last
section is devoted to final conclusions.
2</p>
    </sec>
    <sec id="sec-2">
      <title>The ANIMO Framework: Aiding to the Systems</title>
    </sec>
    <sec id="sec-3">
      <title>Intercommunication</title>
      <p>As commented, the ANIMO framework has been developed to make easier the
integration between different heterogeneous systems such as sensors, robots, systems, etc.
that can be part of any smart cities application. It has a scalable architecture that is
formed of the following modules:
 The communication layer (CL), it is the framework core based on DDS.
 The hardware abstraction layers (HAL). There is a HAL for each device or
Cooperating Object to be incorporated into the framework. This layer is responsible for
abstracting the peculiarities of the device and converting the data types used by its
driver to the types defined in ANIMO. The HALs are libraries that wrap the device
drivers to integrate them easily.
 The services of devices as high level applications (HLAs), that using the
communication layer and the hardware abstraction layer, send the device data and receive
the control command by DDS. There are already several devices integrated in
ANIMO such as the haptics, the cyber gloves, the IS900 tracker, the webcams and
the testbed accessing to the quadrotors. In this way, the devices are available for
the possible HLAs. It is shown in Figure 1.
 The ROS Bridge module gives the capacity to communicate the ANIMO
framework with the ROS middleware1 that makes even more easier the integration of
mobile robots as another Cooperating Object, i.e., the ROS world is accessible in
ANIMO. This characteristic could be very interesting for smart cities applications
where it is needed to interconnect robots with other smart sensors.
 A powerful tool to generate code brings the ANIMO extension as a very easy and
simple task.</p>
      <p>The benefits that the ANIMO framework provides to the applications are numerous.
For example it accelerates development since it replaces low-level communications
code with high-level interfaces. Also, it combines asynchronous publish/subscribe
1</p>
      <p>
        ROS (Robot Operating System) provides libraries and tools to help software developers
create robot applications. It provides hardware abstraction, device drivers, libraries,
visualizers, message-passing, package management, and more. ROS is licensed under an open
source, BSD license [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ].
messaging and real-time data management, it automatically discovers and routes data
between publishers (writers) and subscribers (readers) to the same topic, eliminates
dependence on start-up order, automatically synchronizes state if there are
disconnections or/and reconnections, and a change of the QoS used in the application means
only a change in the configuration file avoiding the recompilation of the application.
2.1
      </p>
      <sec id="sec-3-1">
        <title>Architecture of the Communication Layer</title>
        <p>Given that the DDS API is very extensive and it is desired that the communication
layer be reusable and simple, hiding the complexity of DDS, the ANIMO framework
has built its own communication layer which can be integrated into any application
requiring distributed software. Its architecture is detailed in Figure 2.</p>
        <p>The communication layer is implemented in the C++ programming language and it
is available for Linux and Windows platforms as dynamic library.
The ANIMO framework has a first layer of DDS abstraction (DDS wrapper). It
creates the topics, the participants, the publishers, the data writers, the subscribers and
the readers. However, in order to further facilitate the use of the framework, ANIMO
integrates another layer of abstraction that provides access points for sending (APS)
and receiving (APR) data to the applications reducing the number of objects to create.</p>
        <p>The common data types or structures that are exchanged between the applications
are defined in Common Data Library (CDL), which gives support to the
communication layer and the applications. At present, the CDL has more than forty different data
types like position, rotation, velocity, angular speed, flight plan, MAVLink messages,
etc. Thanks to the powerful tool built to generate code, the incorporation and the
updating of the data types is a very easy and simple task.
2.2</p>
      </sec>
      <sec id="sec-3-2">
        <title>A rapid and easy way to extend the ANIMO Framework</title>
        <p>A feature that adds more value to the framework is to have a code generator for
updating the framework. The code generator is joined to an useful GUI program helps to
the developer in the maintenance task. From a description file of the data types that
will travel through the network, all the ANIMO framework code that depends on the
data types is self-generated. Then, these files are copied to the respective projects and
compiled. Finally, the installation packages are built to reinstall them updating the
framework libraries on the computer.</p>
        <p>
          XML has been chosen as the description file format because it is well-known by
most developers. Managing the information that contains; it is possible to auto
generate the ROS messages and actions for the ROS packages and ROS Bridge module,
and the IDLs and the C++ code for the ANIMO framework core. The code generator
is based on the Apache Velocity Project [
          <xref ref-type="bibr" rid="ref5">5</xref>
          ].
2.3
        </p>
      </sec>
      <sec id="sec-3-3">
        <title>Connecting with the ROS Middleware</title>
        <p>
          A novel module, called ROS Bridge, has been performed to give the capacity to
communicate the ANIMO framework with the ROS middleware that makes even
more easier the integration of mobile robots as another Cooperating Object. More
specifically, ROS Bridge allows the automatic generation of a data parser between the
ANIMO framework and ROS using a XML configuration file. In Figure 3 can be
observed the link of the ANIMO framework core with the ROS Bridge module. The
ROS Bridge API wrappers the ROS API providing methods for the publication and
the subscription of the ROS messages. Moreover, the separate ROS networks can be
communicated by a DDS network using the ROS Bridge module. In this way, the
isolated clients and servers of the ROS actions achieve to be connected and are able to
interchange data across the ANIMO framework.
The following sections explain two principal works where ANIMO has been applied.
One is a distributed simulator to validate real embedded control algorithms. The
simulator has been developed in the European Commission’s 7th Framework Programme
(FP7) project, EC-SAFEMOBIL [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ]. The other is the task of the supervision and
message passing between quadrotors in an experiment of coordination and cooperation
involving multiple aerial vehicles. This task is still developing in the ARCAS project
[
          <xref ref-type="bibr" rid="ref8">8</xref>
          ]; it is also a FP7 project.
        </p>
        <p>In closing, appoint other works where ANIMO is involved:
 Real-time visualization of the experiments being carried out in the testbed of</p>
        <p>FADA-CATEC through a scale virtual world, with the possibility of 3D projection.
 Manipulation of an articulated arm of two degrees of freedom using an haptic
device.
 Simulator for the formation of operators of Remotely Piloted Aircraft Systems
(RPAS), implicating communication between the Ground Control Station (GCS),
the simulation engine, the simulated aircraft with real embedded control
algorithms, the instructor station and the databases. This project is still developing.
 Human Machine Interface (HMI) for the navigation in a 3D virtual world (zoom,
translation and rotation) commanded from the gestures collected using a cyber
glove and the IS900 tracker.
3.1</p>
      </sec>
      <sec id="sec-3-4">
        <title>Distributed Simulator to Validate Embedded Control Algorithms</title>
        <p>
          The EC-SAFEMOBIL project is devoted to the development of sufficiently accurate
common motion estimation and control methods and technologies in order to reach
levels of reliability and safety to facilitate unmanned vehicle deployment in a broad
range of applications [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ]. With this goal, several scenarios are defined in the project to
be performed both in simulation and in real experiments. The distributed simulator
offers the opportunity to test the developed methods in the project in a repeatable and
thorough manner, validating embedded control algorithms before executing them in a
real experiment, in regard scalability, fault-tolerance, trajectory planning and
cooperative tracking. The most important scenarios are:
 Rotary-wing UAV landing on a ship (see Figure 4 (a)).
 Autonomous distributed warehousing traffic and control (see Figure 4 (b)).
 Tracking for surveillance. Many UAVs (Unmanned Aerial Vehicles) follow to
their targets (see Figure 4 (c)).
The simulator has been developed based on the VT MÄK tools [
          <xref ref-type="bibr" rid="ref7">7</xref>
          ], VR-Forces
(backend module or simulation engine) and VR-Vantage (front-end module or visual image
generator), and has the great feature that, the simulations can be visualized in 3D. The
rotary-wing UAV landing on a ship scenario will be explained as example. The
modules are implicated in this scenario constituting the simulator framework is shown in
Figure 5. There are two programs exchange data by using the ANIMO framework
core2. One is the simulation engine; it is responsible of the synchronization between
all modules managing the simulation time. The other is a wrapper of the real UAV
control embedded algorithms. The developed control in Simulink is generated as C++
classes which are integrated without changes in the simulator framework. In the side
of the simulator, the ship, the radio beacon sensor3 and the UAV are created like
VRForces plugins. The UAV behaviour is simulated in a very truthful way using the auto
generated code of the developed UAV model in Simulink. The control loop is
implemented in the simulator as shown in Figure 5. In each simulation step, the RBS data
2 In the tracking for surveillance scenario, can be observed in the Figure 4 (c), there are many
UAVs and targets, therefore, the simulator framework is composed of a wrapper program
for each UAV more the simulation engine program.
3 It is the proposed sensor for the scenario. RBS System is composed of two subsystems, one
located in the UAV itself and another one installed on the ground surrounding the landing
area. The RBS airborne system provides a relative position to the UAV on board computer
(relative to the moving landing pad, located on the ship, in body fixed frame).
are inputs in the control algorithms which act in the simulated UAV. After that, the
new UAV state together the ship state update the simulated sensor closing the loop.
        </p>
        <p>Figure 6 shows the evolution of the UAV and target position in wave conditions (a)
and calm sea (b). When the sea is in calm, the UAV is able to land. However, when
there are waves, it is necessary another helper mechanism to carry out the complete
landing. The EC-SAFEMOBIL project proposes to use a tether linking the UAV and
the platform (tether guiding) in order to increase the stability. This experiment is
being conducted this year.</p>
      </sec>
      <sec id="sec-3-5">
        <title>Experiment of Coordination and Cooperation Involving Multiple Aerial</title>
      </sec>
      <sec id="sec-3-6">
        <title>Vehicles</title>
        <p>
          The ARCAS project proposes the development and experimental validation of the
first cooperative free-flying robot system for assembly and structure construction [
          <xref ref-type="bibr" rid="ref8">8</xref>
          ].
For the missions involve inspection tasks and translation of structures, experiments of
coordination and cooperation of multiple aerial vehicles, avoidance collision, are
proposed. At present, these experiments have been executed in simulation using
Gazebo (see Figure 7 (b)). The real experiments are programmed for early March this
year using the testbed4 of FADA-CATEC (see Figure 7 (a)).
        </p>
        <p>The architecture of the multivehicle experiments is presented in Figure 8. The
modules executed on the ground, the Trajectory Planning (TP) and the Global
Supervisor (GS) are connected to a DDS network. Whereas that the modules executed on
board, the Trajectory Generation (TG), the Collision Avoidance (CA) and the UAV
Abstraction Layer (UAL) are connected by a ROS network. The two network are
united thanks to the ROS Bridge (ROSB) forward the ANIMO topics to the ROS
topic and vice versa. The ROSB runs on the ground. In the beginning, the GP sends
some waypoints of the desired trajectory of all involved UAVs to the TP. Then, the
TP, which knows the world, plans the trajectories for each UAV avoiding the
obstacles of the area and send them. The trajectories arrive to the UAVs through the ROS
Bridge module. At that point, the TG generates the control references for its UAV.
These control references act in the low-level software using UAL. Furthermore, the
control references are modified from CA if a collision with other UAVs is detected.
For this it is necessary that each UAV knows the state of all the other UAVs, which is
achieved using the ROS Bridge module.</p>
        <p>Figure 9 shows the results of an experiment with three UAVs. Figure 9 (a) is an
experiment without executing the CA module. Therefore, there is a collision
implicating two UAVs which go to ground. In Figure 9 (b) can be observed that the collision
is avoided because the CA module is being executed.
4 This testbed is based on an indoor positioning system that uses 20 VICON cameras. This
system can calculate the position and attitude of any moving object within the volume of the
testbed (15x15x5 m) in real time (with an update rate of up to 500 Hz).</p>
        <p>Also, the novel modules have been explained allowing the interconnection with
other middlewares like ROS and the extension of the framework with any information
type without difficulty.</p>
        <p>Finally, it has been shown how the developed ANIMO framework has been
applied to two different projects with very different real-time communication needs
showing the countless possibilities that the framework could have where applied to
smart cities applications.</p>
      </sec>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1. arc a -Valls,
          <string-name>
            <given-names>M.</given-names>
            ,
            <surname>Basanta-Val</surname>
          </string-name>
          ,
          <string-name>
            <surname>P.</surname>
          </string-name>
          <article-title>Est e -Ayres, I: Adaptive real-time video transmission over DDS In: Dept</article-title>
          . of Telematics Eng., Univ. Carlos III de Madrid, Leganes, Spain.
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <given-names>Core</given-names>
            <surname>Libraries</surname>
          </string-name>
          and
          <article-title>Utilities User's Manual of Real-Time Innovations, Version 4</article-title>
          .5, http://www.rti.com
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Xiong</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Parsons</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Edmondson</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Nguyen</surname>
            ,
            <given-names>H.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Schmidt</surname>
            ,
            <given-names>D. C.</given-names>
          </string-name>
          :
          <article-title>Evaluating the Performance of Publish/Subscribe Platforms for Information Management in Distributed Real-time and Embedded Systems</article-title>
          . In: Vanderbilt University,
          <string-name>
            <surname>Nashville</surname>
            <given-names>TN</given-names>
          </string-name>
          , USA
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <article-title>Official website of the ROS middleware</article-title>
          , http://wiki.ros.org
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>5. The Apache Velocity Project, http://velocity.apache.org</mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <article-title>Official website of the EC-SAFEMOBIL project</article-title>
          , http://www.ec-safemobilproject.eu
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>7. Official website of VT MÄK, http://www.mak.com/</mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <article-title>Official website of the ARCAS project</article-title>
          , http://www.arcas-project.eu
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>