Testing operation in Linux

Once the install has completed successfully, OpenRTM-aist-Java can be tested using the included sample components. These are typically stored in the following location:

  • /OpenRTM-aist/<version>/examples

If you built from source, they can also be found in the source directory:

  • /OpenRTM-X.X.X-Java/installer/resources/Source/examples

We will use the SimpleIO components to check that OpenRTM-aist-Java has built and installed correctly.

SimpleIO sample component set

This set contains the ConsoleInComp and ConsoleOutComp components. ConsoleInComp receives numbers as input from the console and sends them over an OutPort. ConsoleOutComp receives numbers via an InPort and prints them to the console. They use this very simple I/O to illustrate the basics of RT Components. Connect the OutPort of ConsoleInComp to the InPort of ConsoleOutComp and activate them.

The explanation below assumes the sample components are in /usr/share/OpenRTM-aist/examples/python.

Test using the sample components

Start the name server

First, a name server that the components can register on must be started. OpenRTM-aist-Java provides a shell script to start orbd, the Java CORBA naming service. If omniORB was installed as a package in Linux, it will often add the name server as a system service. This can be used instead of orbd. You can check if this is the case on your system using the ps command:

 $ ps ax | grep omni
 1550  ?        Sl     0:00 /usr/bin/omniNames -errlog /var/log/omniorb4-nameserver.log
 18418 pts/2    S+     0:00 grep --color=auto omni

If omniNames is not executing, the command will produce something like this (or no output at all):

 $ ps ax | grep omni
 18418 pts/2    S+     0:00 grep --color=auto omni

To start omniNames manually, use the start-orbd.sh command (found in OpenRTM-aist/1.0/examples):

 $ sh /home/openrtm/OpenRTM-aist/1.0/examples/start-orbd.sh
 Starting Java CORBA naming service (orbd).

orbd is a blocking program, not a daemon.

If IPv6 is configured on the system, the host name localhost may not function properly. In that case, replace localhost with 127.0.0.1.

Start ConsoleInComp

Open a new terminal and start ConsoleInComp.

 $ sh /home/openrtm/OpenRTM-aist/1.0/examples/ConsoleInComp
 
 Creating a component: "ConsoleIn"....
 succeed.
 =================================================
  Component Profile
 -------------------------------------------------
 InstanceID:     ConsoleIn0
 Implementation: ConsoleIn
 Description:    Console input component
 Version:        1.0
 Maker:          Noriaki Ando, AIST
 Category:       example
   Other properties   
 =================================================
 =================================================
 Port0 (name): 
 ConsoleIn0.out
 -------------------------------------------------
 - properties -
 port.port_type:DataOutPort
 dataport.data_type:TimedLong
 dataport.subscription_type:new, flush, periodic
 dataport.dataflow_type:push,pull
 dataport.interface_type:corba_cdr
 -------------------------------------------------
 
   

Start ConsoleOutComp

In the same way, start ConsoleOutComp.

 $ sh /home/openrtm/OpenRTM-aist/1.0/examples/ConsoleOutComp
  
 Creating a component: "ConsoleOut"....
 succeed.
 =================================================
  Component Profile
 -------------------------------------------------
 InstanceID:     ConsoleOut0
 Implementation: ConsoleOut
 Description:    Console output component
 Version:        1.0
 Maker:          Noriaki Ando, AIST
 Category:       example
   Other properties   
 =================================================
 =================================================
 Port0 (name): 
 ConsoleOut0.in
 -------------------------------------------------
 - properties -
 port.port_type:DataInPort
 dataport.data_type:TimedLong
 dataport.subscription_type:Any
 dataport.dataflow_type:push,pull
 dataport.interface_type:corba_cdr
 -------------------------------------------------

Start RTSystemEditor

You can use RTSystemEditor to connect the two components and activate them. Download the all-in-one Eclipse package from here and extract it.

RTSystemEditor requires Java Development Kit 7. Install it according to the instructions below, or use an equivalent such as OpenJDK as provided by your distribution. Refer to this page for details on starting RTSystemEditor.

Browsing the name server

Connect to the name server and browse the registered components. You can connect to a name server using the Name Service View on the left side of RTSystemEditor. Click the plug icon to connect to a name server and enter its address (localhost or localhost:2809) in the dialog box. The default port for omniNames and orbd is 2809.

unix100_NameServer_en.png
Connecting to a name server

Drag the RT Components registered on the name server into the system editor. In the name service view, select the ConsoleIn0 and ConsoleOut0 items and drag them into the editor in the middle. Now click and drag between the small boxes at the side of each component, dragging from one component to the other and releasing. The connection dialog will appear. Accept it with all defaults to make a connection between the components.

unix100_oneditor_en.png
Editing a system with RTSystemEditor

Click the green "Play" button in the toolbar to activate all components in the system editor.

Confirming data transfer

After connecting the ports of ConsoleInComp and ConsoleOutComp, the terminal for ConsoleInComp will display:

 Please input number: 

Enter a number and press enter. This number should fit within a short int. Look at the ConsoleOutComp terminal. The number you entered should have been printed out. If this is the case, OpenRTM-aist is functioning correctly.

Download

latest Releases : 2.0.0-RELESE

2.0.0-RELESE Download page

Number of Projects

Choreonoid

Motion editor/Dynamics simulator

OpenHRP3

Dynamics simulator

OpenRTP

Integrated Development Platform

AIST RTC collection

RT-Components collection by AIST

TORK

Tokyo Opensource Robotics Association

DAQ-Middleware

Middleware for DAQ (Data Aquisition) by KEK