INTRODUCTION
Overview
Download and Install
Quick Start
Documentation
Publications

NONFRAMEWORK CODE
Driver Interfaces
Drivers
Libraries
Utilities

FRAMEWORK CODE
Interfaces
Components
Libraries
Utilities

Full Software Listings

DEVELOPER
Tutorials
Examples
Dev Guide
Dashboard

PEOPLE
Contributors
Users

SourceForge.net Logo
Project
Download
Mailing lists

 

         

Connecting components without the Registry

Note:
Reviewed for release 2.14.

In this tutorial we will reproduce the setup of the Quick-Start Guide but now without running the IceGrid Registry. The system diagram is shown below.

doc_tute_direct.png

The client will connect to the server using so called direct connection method. This is equivalent to reaching a web server without the Domain Name Service (by using an IP address instead of a URL). You may want to do this if you do not want to use the IceGrid Registry for some reason.

Start Up the Infrastructure

Start the IceStorm server but make sure that the IceGrid Registry is NOT running (See Quick-Start Guide for instructions).

Modify the global configuration file ~/.orcarc to disable adapter registration (we comment out the line corresponding to the Locator info).

# Standard Ice Configuration for Orca
#Ice.Default.Locator=IceGrid/Locator:default -p 12000

Connect Two Components

First, copy default configuration files for the Laser2d and LaserMon components.

$ mkdir -p ~/sys/tutedirect; cd ~/sys/tutedirect
$ cp [ORCA-INSTALL]/share/orca/cfg/laser2d.cfg .
$ cp [ORCA-INSTALL]/share/orca/cfg/lasermon.cfg .
The Server

Edit laser2d.cfg file:

  • Configure the component to accept connections on a specific port (we will use port 15000 in this tutorial) instead of a random one assigned by the operating system.
  • Change driver library to 'libHydroLaserScanner2dFake.so'.
  • Tell the component to ignore the fact the registry is not there on activation by setting the Orca.Component.RequireRegistry property to zero.

The config file should now contain the following lines:

Laser2d.Endpoints=tcp -t 5000 -p 15000
...
Laser2d.Config.DriverLib=libHydroLaserScanner2dFake.so
...
Orca.Component.RequireRegistry=0

Start the server.

$ laser2d
The Client

Start a new shell where we will run the client LaserMon. This time we have to tell it explicitely where to find the LaserScanner2d interface instead of relying on the Registry to supply this information. As in the case of the server, we disable registry pinging on activation. This lasermon.cfg file should contain these lines:

LaserMon.Requires.LaserScanner2d.Proxy=laserscanner2d:tcp -p 15000
...
Orca.Component.RequireRegistry=0

Start the client.

$ lasermon

You should see the scans scroll by on the screen, just as in the Quick-Start Guide tutorial.

What's Next

If everything works, check out more Orca Tutorials.

 

Webmaster: Tobias Kaupp (tobasco at users.sourceforge.net)


Generated for Orca Robotics by  doxygen 1.4.5