Packages and installers for the Python edition of OpenRTM-aist are provided for many operating systems and distributions to allow easy installation. OpenRTM-aist can also be installed by downloading and compiling the source directly.
The following pages describe installing the Python edition of OpenRTM-aist in various environments.
Openrtm.org provides an MSI package for installing the Python edition of OpenRTM-aist, its prerequisites such as omniORBpy, and the RTSystemEditor tool all at once on Windows.
Download the msi package from download site of openrtm.org. The msi package contains tools such as omniORBpy and RTSystemEditor that are required, but Python needs to be installed in advance. From version 1.1.2, all 3 languages (C++, Java, Python) + tools (Eclipse + rtshell) are bundled with one Windows installer. We recommend that you uninstall the older version in advance. Also, please see the notation of deficit notation in download site.
For the procedure, OpenRTM-aist in 10 minutes! page.
The installer performs the following tasks.
RTM_BASE=C:\Program Files (x86)\OpenRTM-aist\ RTM_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1.2\ RTM_VC_VERSION=vc12 RTM_JAVA_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1.2\ OMNI_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1.2\omniORB\4.2.1_vc12\ OpenCV_DIR=C:\Program Files (x86)\OpenRTM-aist\1.1.2\OpenCV2.4.11\ OpenRTM_DIR=C:\Program Files (x86)\OpenRTM-aist\1.1.2\cmake\
C:\Program Files (x86)\OpenRTM-aist\1.1.2\bin\vc12\ C:\Program Files (x86)\OpenRTM-aist\1.1.2\omniORB\4.2.1_vc12\bin\x86_win32\ C:\Program Files (x86)\OpenRTM-aist\1.1.2\OpenCV2.4.11\x86\vc12\bin\
We provide a script to check the setting of the installation environment. We will explain how to use the script and what you can check on the following page.
- Installation checking script
The file is installed with the following structure.
Executing script to check the above setting of the installation environment saves the directory where Python is installed by the tree command and the OpenRTM-aist directory structure under Program Files to the log file As you do, you can check the details.
<python_install_dir> + omniORB dll, various commands + rtcd, rtcprofile etc. OpenRTM-aist related commands | + Lib | + site-packages | + OpenRTM_aist: OpenRTM-aist Python module | + RTM_IDL: IDL file | | + omniORB related Python module
<install_dir> + OpenRTM-aist + 1.x.x :Old version runtime + <version> + bin: dll, lib, various commands + cmake: OpenRTMConfig.cmake + coil: coil header file + Components + CXX: + Examples: C ++ sample components + OpenCV: OpenCV C ++ Sample Component + Java: Java sample component + Python: Python sample component + etc: rtc.conf sample + ext: ComponentObserverConsumer + jar: + jre: OpenJDK JRE + omniORB + OpenCV + rtm: OpenRTM-aist header file + idl: OpenRTM-aist header file... + util + OpenRTP: + RTSystemEditor: + rtc-template:
When installation is finished, proceed to operation check.
(G)** What is windows_installer_test.bat
(G)This is a script to check the Windows environment settings where OpenRTM-aist is installed. It was created to check the OpenRTM-aist 1.1.2 version installation environment, but it can also be used in environments where previous versions are installed.
(G)The result is output to the log file just by executing the script by double-clicking, and the following contents can be confirmed.
(G)You can download from the following location.
(G) windows_installer_test.bat | http://svn.openrtm.org/openrtm-msi-buildtool/trunk/openrtm_msi/test_scripts/windows_installer_test.bat |
(G)Double-click the downloaded windows_installer_test.bat file. The command prompt screen will be displayed during execution, but it will disappear when it is finished.
(G)The installed directory structure is written to the log file using the tree command. & br; (G)If the Cygwin tree command is installed in the environment, adjust the following settings at the beginning of the script to the environment. If% CYGWIN_DIR% \ bin \ tree.exe does not exist, use the standard Windows tree command.
(G)When the Cygwin tree command is installed, the log “yymmdd-hhmmss_'Python directory'-dir.tree” of the installation directory structure of OpenRTM-aist-Python and rtshell becomes compact. This is because you can specify how many levels down the directory in the output specification. (G)Since the standard tree command for Windows cannot specify the hierarchy, all the structures from the top of the Python directory where OpenRTM-aist-Python is installed are targeted. Therefore, only the directory name is output to the log.
set CYGWIN_DIR=C:\Cygwin64
(G)All execution results are output to the log file. The output destination is under the log folder (created automatically if there is none) in the same directory as the script.
(G)You can use this script by running it on a USB memory and checking the results on another PC.
(G) Log file name | Description |
(G)yymmdd-hhmmss.log | Main log file |
(G)yymmdd-hhmmss_pfile.tree | This is output when C: \ Program Files \ OpenRTM-aist exists. You can check the OpenRTM-aist directory structure using the tree command. & br; Even if the 64-bit version of OpenRTM-aist has already been uninstalled, this log file will be output if the directory remains because there are files such as rtc ***. log. The |
(G)yymmdd-hhmmss_pfile_x86.tree | This is output when C: \ Program Files (x86) \ OpenRTM-aist exists. You can check the OpenRTM-aist directory structure using the tree command. & br; Even if the 32-bit version of OpenRTM-aist has already been uninstalled, this log file may be output for the same reason as the 64-bit version. |
(G) yymmdd-hhmmss_'Python directory'-dir.tree | This is output when OpenRTM-aist-Python is installed. You can check the Python directory structure (G)where OpenRTM-aist-Python and rtshell are installed using the tree command. & br; If the installation destination is C: \ Python27, the log file name will be yymmdd-hhmmss_Python27-dir.tree. |
(G)The directory existence of “C: \ Program Files \ OpenRTM-aist” and “C: \ Program Files (x86) \ OpenRTM-aist” is checked. Even if OpenRTM-aist has already been uninstalled, the directory will remain if files (rtc ***. Log, etc.) generated after installation exist. Even if the directory is “exist!”, If C ++, Python, Java Examples are “not installed”, this case can be considered. Check the tree file.
*-*-*-*-*-*-* check OpenRTM-aist installed directory *-*-*-*-*-*-* [[check]] "C:\Program Files\OpenRTM-aist" directory --- not exist! [[check]] "C:\Program Files (x86)\OpenRTM-aist" directory --- exist! --- RTM_VERSION = 1.1.2 Result ⇒ log\20160906-141617_pfile_x86.tree --- C++ Examples (1.1.2) ⇒ installed --- Python Examples (1.1.2) ⇒ installed --- Java Examples (1.1.2) ⇒ installed
*-*-*-*-*-*-* check OpenRTM-aist installed directory *-*-*-*-*-*-* [[check]] "C:\Program Files\OpenRTM-aist" directory --- not exist! [[check]] "C:\Program Files (x86)\OpenRTM-aist" directory --- exist! --- RTM_VERSION = 1.1 Result ⇒ log\20160906-133745_pfile_x86.tree --- C++ Examples (1.1) ⇒ installed --- Python Examples (1.1) ⇒ installed --- Java Examples (1.1) ⇒ not installed
*-*-*-*-*-*-* check OpenRTM-aist installed directory *-*-*-*-*-*-* [[check]] "C:\Program Files\OpenRTM-aist" directory --- exist! --- RTM_VERSION = 1.1.2 Result ⇒ log\20160907-104846_pfile.tree --- C++ Examples (1.1.2) ⇒ installed --- Python Examples (1.1.2) ⇒ installed --- Java Examples (1.1.2) ⇒ installed --- This PC is 32bit OS.
*-*-*-*-*-*-* check system environment variables *-*-*-*-*-*-* RTM_BASE=C:\Program Files (x86)\OpenRTM-aist\ RTM_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1.2\ RTM_VC_VERSION=vc12 RTM_JAVA_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1.2\ OMNI_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1.2\omniORB\4.2.1_vc12\ OpenCV_DIR=C:\Program Files (x86)\OpenRTM-aist\1.1.2\OpenCV2.4.11\ OpenRTM_DIR=C:\Program Files (x86)\OpenRTM-aist\1.1.2\cmake\
(G) Environment variable RTM_BASE is not defined (G) RTM_ROOT = C: \ Program Files (x86) \ OpenRTM-aist\1.1\ (G) RTM_JAVA_ROOT = C: \ Program Files \ OpenRTM-aist\1.1\
OMNI_ROOT=C:\Program Files (x86)\OpenRTM-aist\1.1\omniORB\4.1.7_vc10\ OpenCV_DIR=C:\Program Files (x86)\OpenRTM-aist\1.1\OpenCV2.4.9\
*-*-*-*-*-*-* check Path *-*-*-*-*-*-* C:\Program Files (x86)\OpenRTM-aist\1.1.2\bin\vc12\ C:\Program Files (x86)\OpenRTM-aist\1.1.2\omniORB\4.2.1_vc12\bin\x86_win32\ C:\Program Files (x86)\OpenRTM-aist\1.1.2\OpenCV2.4.11\x86\vc12\bin\
*-*-*-*-*-*-* check Path *-*-*-*-*-*-* C:\distribution\opencv3.0.0\build\x86\vc10\bin C:\Program Files (x86)\OpenRTM-aist\1.1\bin\ C:\Program Files (x86)\OpenRTM-aist\1.1\omniORB\4.1.7_vc10\bin\x86_win32\ C:\Program Files (x86)\OpenRTM-aist\1.1\OpenCV2.4.9\x86\vc10\bin
*-*-*-*-*-*-* check Python installed directory *-*-*-*-*-*-* C:\Python27\ ----OpenRTM-aist-Python installed. C:\Python27\ ----rtshell installed. C:\Python27_x64\ ----OpenRTM-aist-Python not installed. C:\Python27_x64\ ----rtshell installed. C:\Python35_x64\ ----OpenRTM-aist-Python not installed. C:\Python35_x64\ ----rtshell not installed. C:\Python35\ ----OpenRTM-aist-Python not installed. C:\Python35\ ----rtshell not installed.
*-*-*-*-*-*-* check OpenRTM-aist-Python installed directory *-*-*-*-*-*-* Result ⇒ log\20160906-141617_Python27-dir.tree
*-*-*-*-*-*-* check OpenRTM-aist-Python installed directory *-*-*-*-*-*-* Result ⇒ log\20160906-171616_Python26-dir.tree Result ⇒ log\20160906-171616_Python27-dir.tree
*-*-*-*-*-*-* check Custom installed lists *-*-*-*-*-*-* [1] C++ : Runtime Environment [2] C++ : Development Environment [3] C++ : Examples RTC [4] C++ : OpenCV RTC [5] OpenCV [6] Python : Examples RTC [7] Java : Runtime Environment [8] Java : Examples RTC [9] Tools : OpenRTP [10] Tools : RTSystemEditorRCP [11] Tools : JRE [12] OpenRTM-aist old Runtime : 1.0.0 [x86 only] [13] OpenRTM-aist old Runtime : 1.1.0 [14] OpenRTM-aist old Runtime : 1.1.1 [15] IDL
(G) List of folder paths (G) Volume serial number is 9CF9-3755
C:\PROGRAM FILES (X86)\OPENRTM-AIST ├─1.0.0 │ └─vc9 │ └─bin │ coil.dll : └─1.1.2 ├─bin │ │ cmakeconfgen.py
deb packages for installing the Python edition of OpenRTM-aist on Debian GNU Linux and Ubuntu Linux are available. The supported Debian/Ubuntu versions are listed on the download page. The Debian/Ubuntu versions may change without notice.
There are two methods available for installing:
Download the pkg_install_python_ubuntu.sh or pkg_install_python_debian.sh install script provided on the download page of openrtm.org and execute it with root permissions. This script will install the necessary dependencies using apt-get.
Installing all the packages needed for development with OpenRTM-aist takes some work. For new users, using the install script is recommended. However, this will install all packages used by OpenRTM-aist, even though you may not need them. Expert users should consider installing manually using apt-get or synaptic.
Follow these steps to use the install script.
> wget [pkg_install_python_???.sh download URL] > su # sh pkg_install1_python_ubuntu.sh // Answer "y" or "Y" to the questions to proceed.
Openrtm.org provides a package repository for use with apt-get. This is not included in the default package repository, so it must be added to the apt-get settings by hand. Add one of the following lines to the file "/etc/apt/sources.list" (root permissions will be required):
> su # vi /etc/apt/sources.list # Edit "sources.list"
deb http://www.openrtm.org/pub/Linux/ubuntu/ (code name) main
deb http://www.openrtm.org/pub/Linux/debian/ (code name) main
"(code name)" is the code name of your version of Debian or Ubuntu Linux. It must be one of the following.
version | code name |
Debian GNU Linux | |
Debian 7.0 | wheezy |
Debian 8.0 | jessie |
Debian 9.0 | stretch |
Ubuntu | |
Ubuntu 14.04 | trusty |
Ubuntu 16.04 | xenial |
Ubuntu 16.10 | yakkety |
Ubuntu 17.04 | zesty |
Next, run these commands to install OpenRTM-aist.
> su # apt-get update # apt-get install python # apt-get install omniORB-servers omniORBpy omniORBpy-devel omniORBpy-standarda # apt-get install OpenRTM-aist-Python OpenRTM-aist-Python-example
Answer "y" or "Y" to the questions to proceed.
It is possible to freeze OpenRTM-aist at the installed version. To do so, edit the file "/etc/apt/preferences" and append the following lines (this example is for version 1.0):
Package: OpenRTM-aist-Python Pin: version 1.0.*
For more details, see http://www.debian.org/doc/manuals/apt-howto/ch-apt-get.en.html#s-pin.
Check the install was successful using the following command.
$ dpkg -l 'openrtm*' Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad) ||/ Name Version Description +++-==========================-============================================================================================== ri openrtm-aist-python 1.0.0-release0 OpenRTM-aist, RT-Middleware distributed by AIST ri openrtm-aist-python-exampl 1.0.0-release0 OpenRTM-aist, RT-Middleware distributed by AIST
The packages contain the following files.
OpenRTM-aist-Python includes the Python modules and several commands.
/usr/bin/rtcprof_python /usr/bin/rtcd_python
/usr/lib/python<version>/dist-packages/OpenRTM_aist/examples/rtc.conf.sample
/usr/lib/python<version>/dist-packages/OpenRTM_aist/*
/usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtcprof /usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtcd /usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtc-template /usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtm-naming
openrtm-aist-python-example contains sample components.
/usr/share/OpenRTM-aist/examples/python/SimpleIO/ /usr/share/OpenRTM-aist/examples/python/SimpleService/ ...
When installation is finished, proceed to operation check.
An RPM package for installing the Python edition of OpenRTM-aist on Fedora Linux is available. The supported Fedora Linux versions are listed on the download page. The Fedora Linux versions may change without notice.
There are two methods available for installing:
Download the pkg_install_python_fedora.sh install script provided on the download page of openrtm.org and execute it with root permissions. This script will install the necessary dependencies using apt-get.
Installing all the packages needed for development with OpenRTM-aist takes some work. For new users, using the install script is recommended. However, this will install all packages used by OpenRTM-aist, even though you may not need them. Expert users should consider installing manually using yum.
Follow these steps to use the install script.
> wget [pkg_install_python_fedora.sh download URL] > su # sh pkg_install1_python_fedora.sh // Answer "y" or "Y" to the questions to proceed.
Openrtm.org provides a package repository for use with apt-get. This is not included in the default package repository, so it must be added to the apt-get settings by hand. Create a file called /etc/yum.repos.d/openrtm.repo (root permissions will be required), and add the following lines to it.
[openrtm] name=Fedora $releasever - $basearch failovermethod=priority baseurl=http://www.openrtm.org/pub/Linux/Fedora/releases/$releasever/Fedora/$basearch/os/Packages enabled=1 gpgcheck=0 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora file:///etc/pki/rpm-gpg/RPM-GPG-KEY
After making the file above, execute these commands to install with yum. Answer y to the questions to proceed.
> su # yum install python # yum install omniORB-servers omniORBpy omniORBpy-devel omniORBpy-standard # yum install OpenRTM-aist-Python OpenRTM-aist-Python-example
Check the install was successful using the following command.
# rpm -qa | grep OpenRTM-aist-Python OpenRTM-aist-Python-example-1.0.0-RELEASE.fcx.i386 OpenRTM-aist-Python-1.0.0-RELEASE0.fcx.i386
The packages contain the following files.
OpenRTM-aist-Python includes the Python modules and several commands.
/usr/bin/rtcprof_python /usr/bin/rtcd_python
/usr/lib/python<version>/dist-packages/OpenRTM_aist/examples/rtc.conf.sample
/usr/lib/python<version>/dist-packages/OpenRTM_aist/*
/usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtcprof /usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtcd /usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtc-template /usr/lib/python<version>/dist-packages/OpenRTM_aist/utils/rtm-naming
OpenRTM-aist-Python-example contains sample components.
/usr/share/OpenRTM-aist/examples/python/SimpleIO/ /usr/share/OpenRTM-aist/examples/python/SimpleService/ ...
When installation is finished, proceed to operation check.
RPM packages for installing the Python edition of OpenRTM-aist on Vine Linux are available. The supported Vine Linux versions are listed on the download page. The Vine Linux versions may change without notice.
There are two methods available for installing:
Download the pkg_install_python_vine.sh install script provided on the download page of openrtm.org and execute it with root permissions. This script will install the necessary dependencies using apt-get.
Installing all the packages needed for development with OpenRTM-aist takes some work. For new users, using the install script is recommended. However, this will install all packages used by OpenRTM-aist, even though you may not need them. Expert users should consider installing manually using apt-get or synaptic.
Follow these steps to use the install script.
> wget [pkg_install_python_vine.sh download URL] > su # sh pkg_install1_python_vine.sh // Answer "y" or "Y" to the questions to proceed.
Openrtm.org provides a package repository for use with apt-get. This is not included in the default package repository, so it must be added to the apt-get settings by hand. Add the following line to the file /etc/apt/sources.list (root permissions will be required):
rpm http://www.openrtm.org/pub/Linux/Vine/apt x.x/$(ARCH) main
Replace x.x with your Vine Linux version. For example, use 5.0 for Vine 5.0:
rpm http://www.openrtm.org/pub/Linux/Vine/apt 5.0/$(ARCH) main
Next, run these commands to install OpenRTM-aist.
> su # apt-get update # apt-get install python # apt-get install omniORB-servers omniORBpy omniORBpy-devel omniORBpy-standarda # apt-get install OpenRTM-aist-Python OpenRTM-aist-Python-example
Answer y or Y to the questions to proceed. You can replace the apt-get command with the synaptic command.
Check the install was successful using the following command.
# rpm -qa | grep OpenRTM-aist-Python OpenRTM-aist-Python-example-1.0.0-RELEASE.vlXX OpenRTM-aist-Python-1.0.0-RELEASE0.vlXX
The packages contain the following files.
OpenRTM-aist-Python includes the Python modules and several commands.
/usr/bin/rtcprof_python /usr/bin/rtcd_python
/usr/lib/python<version>/site-packages/OpenRTM_aist/examples/rtc.conf.sample
/usr/lib/python<version>/site-packages/OpenRTM_aist/*
/usr/lib/python<version>/site-packages/OpenRTM_aist/utils/rtcprof /usr/lib/python<version>/site-packages/OpenRTM_aist/utils/rtcd /usr/lib/python<version>/site-packages/OpenRTM_aist/utils/rtc-template /usr/lib/python<version>/site-packages/OpenRTM_aist/utils/rtm-naming
OpenRTM-aist-Python-example contains sample components.
/usr/share/OpenRTM-aist/examples/python/SimpleIO/ /usr/share/OpenRTM-aist/examples/python/SimpleService/ ...
When installation is finished, proceed to operation check.
For those who wish to install from a source package, it is possible to build OpenRTM-aist-python manually.
The OpenRTM-aist (Python version) source package for Windows is distributed separately from the source for Linux. The contents of the source code are exactly the same but the following parts are different.
Original is source code of subversion repository, from its source code, on Linux,
Two types,
On Windows,
It is configured to create only one type of.
The necessary tools and libraries for building are:
Python 2.7 is required. Please obtain the latest version from the following site and install it.
When launching the installer, there are some parts to select in the wizard, You can install by default.
The omniORBpy library is necessary to build the Python edition of OpenRTM-aist. omniORBpy can be obtained from the link below. Source packages and binaries are available. However, openrtm.org provides a pre-built binary installer that may be more convenient.
When you unzip the ZIP file, the directory tree shown below should be expanded. Please place the files under each directory in the Python directory as indicated below. The version of omniORBpy is described as x.y, and the version of Python as X.Y.
+ omniPRBpy-x.y + bin + x86_win32 -> both exe and dll go directly under C:\PythonXY + doc -> may be deleted + examples -> may be deleted + idl -> may be deleted but it may be placed under C:\PythonXY\Lib\site-packages\omniORB\idl + lib + python -> directly below C:\PythonXY\Lib\site-packages directory and files + x86_win32 -> .pyd directly under C:\PythonXY\Lib\site-packages
Download a source package, named OpenRTM-aist-Python-X.X.X.zip, and extract it in a suitable directory.
Start a command prompt and change to the directory where you extracted the source code. Execute the following commands.
> OpenRTM-aist-Python-X.X.X > python setup.py build
Once everything has built successfully, execute the following command to install it.
> python setup.py install
This completes the installation of OpenRTM-aist.
For distributions that do not yet have a pre-built package available, or for users who wish to alter the OpenRTM-aist source themselves, it is possible to build OpenRTM-aist from source.
The Python edition of OpenRTM-aist uses the distutils module to build, allowing it to be built in a variety of environments.
OpenRTM-aist-Python has been tested and confirmed to work on the following distributions.
It should be possible to build and use OpenRTM-aist-Python on other versions of Linux/UNIX.
OpenRTM-aist-Python-1.0.0 depends on the folloowing environmental tools and libraries.
Install these dependencies according to their individual documentations. Installing them into standard locations such as /usr and /usr/local will make compiling OpenRTM-aist-Python easier.
Download the OpenRTM-aist-Python source code from the download page.
Extract the source code from the OpenRTM-aist-Python-X.X.X.tar.gz file into a suitable location.
$ tar xvzf OpenRTM-aist-Python-X.X.X.tar.gz $ cd OpenRTM-aist-Python-X.X.X
OpenRTM-aist uses autotools for building. It can be built in the same way as any other distutils-based package.
$ python setup.py build [options]
The usable options are listed in the help:
$ python setup.py --help
When the build completes successfully, use this command to install:
$ su # python setup.py install
This completes the installation.
The OpenRTM-aist-Python source code is stored in a publicly-available Subversion repository. This source code can be checked out and built.
Checkout the source from the repository as below.
$ svn co http://www.openrtp.jp/openrtm/svn/OpenRTM-aist-Python/trunk/OpenRTM-aist-Python A OpenRTM-aist-Python/OpenRTM_aist A OpenRTM-aist-Python/OpenRTM_aist/CorbaPort.py A OpenRTM-aist-Python/OpenRTM_aist/__init__.py A OpenRTM-aist-Python/OpenRTM_aist/Guard.py A OpenRTM-aist-Python/OpenRTM_aist/RTM_IDL A OpenRTM-aist-Python/OpenRTM_aist/RTM_IDL/RTC.idl A OpenRTM-aist-Python/OpenRTM_aist/RTM_IDL/Manager.idl ... A OpenRTM-aist-Python/installer/WixUI_es-es.wxl A OpenRTM-aist-Python/installer/WixUI_fr-fr.wxl A OpenRTM-aist-Python/installer/WixUI_de-de.wxl A OpenRTM-aist-Python/installer/WixUI_cs-cz.wxl A OpenRTM-aist-Python/installer/WixUI_da-dk.wxl Checked out revision 349.
After checking out, a directory called OpenRTM-aist-Python will have been created. Change to this directory.
$ ls OpenRTM-aist-Python $ cd OpenRTM-aist-Python $ ls MANIFEST.in OpenRTM-aist.pth README setup.py MANIFEST_examples.in OpenRTM_aist/ installer/
Use setup.py to build and install.
$ python setup.py build
By executing the command shown below, a source package such as those available at openrtm.org can be created. In order to make a distribution package, some additional tools are necessary, such as doxygen, latex, and qkc.
$ python setup.py sdist
$ ls -l dist/OpenRTM-aist-Python-* -rw-rw-r-- 1 openrtm openrtm 2721202 2月 24 16:43 OpenRTM-aist-Python-1.1.0.tar.gz -rw-rw-r-- 1 openrtm openrtm 4686452 2月 24 16:43 OpenRTM-aist-Python-1.1.0.zip
The following packages are created:
Once the installer has completed successfully, OpenRTM-aist can be tested using the included sample components. These are typically stored in one of the following locations:
We will use the SimpleIO components to check that OpenRTM-aist has built and installed correctly.
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 OpenRTM-aist-python has been installed using the MSI package and the sample components are available in the Start Menu. Right-clicking on the OpenRTM-aist entry in the Start Menu and selecting "Open" will make accessing these more convenient.
First, a name server that the components can register on must be started. Start it using the shortcut in the Start Menu at [OpenRTM-aist 1.1] > [Tools] > [Start Naming Service].
A console like the following will open.
There are cases where the name server console screen does not open. In this case, there are several causes as below, so investigate the cause and take appropriate action.
The msi installer provided by openrtm.org contains omniORBpy, but if you select Custom installation you can also install OpenRTM - aist - Python without installing omniORBpy.
Also, if installing manually, omniORBpy may not be included, so please make sure omniORBpy is installed.
The file to start the name server is C:\Program Files (x86)\OpenRTM-aist\1.1\bin\rtm-naming.py. (When installing with 32 bit version msi)
Opening the console screen in this directory and running python rtm-naming.py will start up the name server, but if you can not start by double clicking rtm-naming.py, please check the python you are installing.
If you install both 32-bit and 64-bit Python, it seems that the one you installed earlier can be associated with a py file, so installing Python with the same architecture as the OpenRTM-aist-Python installer may be fixed first I do not.
In rare cases, the host name or address settings of the machine may be incorrect, causing the name server to start incorrectly. Informing omniNames.exe of the correct IP can resolve this problem. Set the OMNIORB_USEHOSTNAME environment variable in the following way (the example assumes the host's IP is 192.168.0.11):
Variable name: OMNIORB_USEHOSTNAME Variable value: 192.168.0.11
After starting the name server, start some suitable components. The OpenRTM-aist-Python start menu folder contains a sub-folder called "Examples," which contains many components as shown below.
Start ConsoleIn.py and ConsoleOut.py, causing two consoles to open.
Sometimes the component consoles do not open. There are several possible causes for this, described below.
There may be an error in the rtc.conf file, preventing the components from starting. Confirm the contents of the rtc.conf file in C:\Program Files\OpenRTM-aist\1.0\examples\Python\SimpleIO. For example, the corba.endpoint/corba.endpoints settings should match the host address of the current computer.
Try creating a minimal rtc.conf, as below.
corba.nameservers: localhost
RTSystemEditor can be started from the Start Menu: [OpenRTM-aist] > [Tools] > [RTSystemEditor].
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 is 2809.
The name server running on localhost will appear in the Name Service View. Open the tree branches by clicking the arrows to find the two components you started.
Open a system editor using the new system editor button in the toolbar . The editor will open in the central pane. Drag the components from the name service view into the editor.
The OutPort of ConsoleIn0 is displayed on its right-hand side . Drag from this to the InPort on the ConsoleOut0 component to connect these data ports. The connection dialog will be displayed. Click "OK" to accept the defaults and connect the components.
A line indicating the connection will appear between the two ports. Next, click the [Activate All] button in the toolbar. This will activate all components in the editor at once. Active components will appear green.
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.
Other sample components are included in the installed OpenRTM-aist-Python. They can all be used in the same way as the above example.
ConsoleIn.py | Receive numbers from the console and send them over an OutPort. Connect it to ConsoleOut.py to use. |
ConsoleOut.py | Receive numbers over an InPort and print them in a console. Connect it to ConsoleIn.py to use. |
SequenceIn.py | A component to output various simple data types (short, long, float, double, and sequences). Connect it to SequenceOut.py to use. |
SequenceOut.py | Display various simple data types received over an InPort. Connect it to SequenceIn.py to use. |
MyServiceProvider.py | Provides a simple service, MyService. Connect it to MyServiceConsumer.py to use. |
MyServiceConsumer.py | Consumes a simple service, MyService. Connect it to MyServiceProvider.py to use. |
ConfigSample.py | Sample demonstrating configuration parameters. Modify the configuration parameters in RTSystemEditor or with rtconf to see the effect. |
TkMobileRobotSimulator.py | Simple mobile robot simulator. Receive velocities via an InPort, provide position via an OutPort. |
NXTRTC.py | LEGO MindStorms interface component. Command velocities via an InPort, receive infra-red sensor information and odometry via an OutPort. |
AutoControl.py | Calculate velocities for a mobile robot. Receive robot odometry information via an InPort, calculate the speed and provide it via an OutPort. |
Composite.py | Sample composite component. Combines the Motor, Controller and Sensor components into a single composite component. |
Motor.py | Sample component for the composite component sample. |
Controller.py | Sample component for the composite component sample. |
Sensor.py | Sample component for the composite component sample. |
Slider.py | Sample GUI component using Tk. Provides the value of sliders over an OutPort. |
TkMotorComp.py | Sample GUI component using Tk. Displays the values received via an InPort in the GUI. |
TkLRFViewer.py | Sample GUI component using Tk. Draws laser data in the GUI. |
TkJoystickComp.py | Sample GUI component using Tk. Provides a virtual joystick. |
Once the installer has completed successfully, OpenRTM-aist-Python can be tested using the included sample components. These are typically stored in one of the following locations:
If you built from source, they can also be found in the source directory:
We will use the SimpleIO components to check that OpenRTM-aist has built and installed correctly.
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-1.1/example/python.
First, a name server that the components can register on must be started. If omniORBpy was installed as a package in Linux, it will often add the name server as a system service. 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 rtm-naming command:
$ rtm-naming Starting omniORB omniNames: ubuntu910:2809 Thu Dec 3 18:52:14 2009: Starting omniNames for the first time. Wrote initial log file. Read log file successfully. Root context is IOR:010000002b00000049444c3a6f6d672e6f72672f436f734e616d696e672f4e616d696e67436f6e746578744578743a312e30000001000000000000007400000001010200100000003139322e3136382e3130302e31323500942600000b0000004e616d6553657276696365000300000000000000080000000100000000545441010000001c0000000100000001000100010000000100010509010100010000000901010003545441080000004e8a174b01000fef Checkpointing Phase 1: Prepare. Checkpointing Phase 2: Commit. Checkpointing completed.
An RTC configuration file, rtc.conf, must be created for the test. First, make a suitable working directory. This example will create a directory called RTCwork below the home directory. Change to this directory and create a file called "rtc.conf".
$ cd ~/RTCwork $ vi rtc.conf
Add the following lines to this file. Note that you cannot use the rtc.conf in share/OpenRTM-aist/examples/ for this example.
corba.nameservers: localhost naming.formats: %h.host_cxt/%n.rtc logger.enable: NO example.ConsoleOut.config_file: consout.conf example.ConsoleIn.config_file: consin.conf
If your system is configured to use IPv6, using localhost may not function correctly. In that case, use 127.0.0.1 instead.
Open a new terminal and start ConsoleInComp, making sure it uses the rtc.conf you created.
$ python /usr/share/OpenRTM-aist/examples/python/SimpleIO/ConsoleIn.py -f ~/RTCwork/rtc.conf comp_args: ConsoleIn
If using the samples directly from a source directory:
$ python <source_dir>/OpenRTM_aist/examples/SimpleIO/ConsoleIn.py -f ~/RTCwork/rtc.conf
In the same way, start ConsoleOutComp.
$ python /usr/share/OpenRTM-aist/examps/python/SimpleIO/ConsoleOut.py -f ~/RTCwork/rtc.conf comp_args: ConsoleOut
If using the samples directly from a source directory:
$ python <source_dir>/OpenRTM_aist/examples/SimpleIO/ConsoleOut.py -f ~/RTCwork/rtc.conf
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 6. 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.
Please start RTSystemEditor referring to the page of here.
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 is 2809.
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.
Click the green [Play] button in the toolbar to activate all components in the system editor.
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.