Installation

Requirements

  1. ACE+TAO (at least the version 6.0.2)
  2. Operating system: Ubuntu 12.04. Other OS reported to work:
    • Ubuntu 10.04
    • Debian wheezy

Hint: Take care to have enough free disk space (appr. 2 GB)

1) ACE+TAO installation

We recommend to build ACE+TAO middleware from sources (Ubuntu's binaries for ACE+TAO are usually too old, we need at least ACE+TAO-6.0.2).

As a precondition for building ACE+TAO from sources the ubuntu packages g++, libstc++ and make must be installed first.

The easiest way to build ACE+TAO is to use our installation script:

     $ wget http://servicerobotik-ulm.de/drupal/sites/default/files/INSTALL-ACE-TAO-6.0.2.sh
     $ chmod +x INSTALL-ACE+TAO-6.0.2.sh
     $ sudo ./INSTALL-ACE+TAO-6.0.2.sh /opt

Hints: For more information and customized installation, feel free to modify the bash script on your needs. Instead of /opt you can also choose a different location to install ACE+TAO into.

After the installation-script has finished (can take approx. 1 h), the environment variables must be set (if not already done). On Ubuntu, we recommend to set ACE_ROOT and TAO_ROOT in .profile. In addition, the LD_LIBRARY_PATH must be enhanced to include ACE_ROOT/lib (use .bashrc for this purpose):

     $ echo "export ACE_ROOT=/opt/ACE_wrappers" >> .profile
     $ echo "export TAO_ROOT=\$ACE_ROOT/TAO" >> .profile
     $ source .profile

     $ echo "export LD_LIBRARY_PATH=\$ACE_ROOT/lib:\$LD_LIBRARY_PATH" >> .bashrc
     $ bash

Hint: To apply the changes in .profile and .bashrc it is recommended to reboot your OS.

2) SmartSoft installation

In the following we use the folder $HOME/SOFTWARE to store all SmartSoft related packages.

For SmartSoft source-files, we create $HOME/SOFTWARE/smartsoft-ACE+TAO-6.0.2 and a softlink $HOME/SOFTWARE/smartsoft:

     $ cd $HOME
     $ mkdir SOFTWARE
     $ cd SOFTWARE
     $ mkdir smartsoft-ACE+TAO-6.0.2
     $ ln -s smartsoft-ACE+TAO-6.0.2 smartsoft

     $ cd $HOME
     $ echo "export SMART_ROOT=\$HOME/SOFTWARE/smartsoft" >> .profile
     $ source .profile

Checkout SmartSoft (you need subversion to be installed):

     $ cd $SMART_ROOT
     $ svn co https://svn.code.sf.net/p/smart-robotics/code/trunk/smartsoft/ .

In order to build the SmartSoft-Kernel and SmartSoft-Components in Ubuntu, the following packages are required:

  • ACE+TAO as shown above (required by SmartSoft-Kernel)
  • doxygen to build the doxygen documentation of the SmartSoft-kernel.
  • libcvaux4-dev and libhighgui4-dev are required by the SmartMapper component
    Hint: If you use opencv-2.3.1 in parallel (e.g. within ros-electric), it may be necessary to build OpenCV from sources.
  • libboost-math-dev

Now you can build the framework and the enclosed components by using the top-level makefile:

     $ cd $SMART_ROOT/src
     $ make 

Get yourself some coffee, because this can take a wile (ca. 30 min to 1 h). On success you will get the following output at the end:

---------------------------------------------------

    Software  S U C C E S S F U L L Y  compiled.

---------------------------------------------------

Optional packages in SmartSoft

The top-level makefile builds the SmartSoft-Kernel, utilities, interface-classes and most of the components per default. Some particular components require additional libraries/drivers (like the driver for Katana-manipulator), which can not be presumed per default. To manually build these components, do:

     $ cd $SMART_ROOT/src/components/<component-name>/src
     $ make 

If you want to add a certain component to be compiled per default in the top-level build, simply add an empty file with the name SMARTSOFT_PACKAGE_MDSD into the folder of this component:

     $ cd $SMART_ROOT/src/components/<component-name>
     $ touch SMARTSOFT_PACKAGE_MDSD

Hint: This file instructs the top-level makefile to execute "make all" inside the component's subfolder src.

CORBA Naming Service

Naming Service Host

All Components and the SmartSoft-Kernel depend on the CORBA Naming-Service as a global directory service. Therefore one instance of the Naming-Service has to be started (before any other component) on the main host in the network (this host must be reachable from all other clients in the network).

To easily start and stop the Naming-Service, SmartSoft provides the following two bash-scripts (available in $SMART_ROOT):

  • startCORBA
  • stopCORBA

Hint: Feel free to modify these scripts in order to parametrize the Naming-Service on your needs.

Naming Service Clients

Each client in the network (where SmartSoft-Components are supposed to run) must set the NameServiceIOR environment variable, that should consist of the host address (where the Naming-Service is running):

   $ export NameServiceIOR=corbaloc:iiop:<Naming-Service-ip-address>:<port-number>/NameService

example (Naming-Service is running on same host):

   $ export NameServiceIOR=corbaloc:iiop:localhost:12345/NameService

example (Naming-Service is running on another host):

   $ export NameServiceIOR=corbaloc:iiop:192.168.0.1:12345/NameService

We recommend to use .bashrc to set this environment variable:

   $ echo "export NameServiceIOR=corbaloc:iiop:192.168.0.1:12345/NameService" >> $HOME/.bashrc

Alternative way for Clients

Instead of using the environment variable (see above), the Naming-Service parameter can also be set individually for each component by using the following component-parameter:

      -ORBInitRef NameService=corbaloc:iiop:localhost:12345/NameService

example:

   $ bin/smartExampleComponent1 -ORBInitRef NameService=corbaloc:iiop:localhost:12345/NameService