UrbiOpenSourceContestProjects

Kecsap

I look into having a Urbi 2 port for Aibo (ERS-7). The old URBI 1.5 engine is not open-source, so it would be nice to have a fully open-source stack for this robot dog.

Please note: There is no any warranty regarding the software you can download from this page.

Prerequisites

1. Toolchain

The old toolchain for Aibo is based on binutils 2.15/gcc 3.3.6/newlib 2.15. This version of the gcc is pretty old and made almost impossible to move to Urbi 2. It was desired to update to a more recent gcc 4.x compiler because of the heavy template and exception usage in Urbi 2. After a longer period, I was able to create a binutils 2.17/gcc 4.1.2/newlib 2.15 toolchain. There was some problems to make the exception handling work, but the process was successful in the end.

The packaged toolchain sources can be downloaded from here: New toolchain for Aibo

2. Boost

The Boost is an unavoidable dependency for the Urbi 2. The work involved to make the Boost headers compatible with Aibo and cross-compile a few modules, needed for Urbi 2.

The modified, packaged Boost sources can be downloaded from here: Boost 1.43 for Aibo

Urbi 2.3 SDK for Aibo

First, I did the Urbi 2 gcc 3.x compatible, but it turned out that there are limitations with gcc 3.x which can not be worked around. After I moved to gcc 4.x, the backward compatibility was dropped.

The largest part of the development was the modification of the Urbi 2 software to make it Aibo compatible. The dev environment for Aibo does not contain the standard Unix/Linux APIs for networking and other low-level functionalities, but it provides special a Sony API (Open-R) to reach the necessary parts of the operating system on the robot dog (Aperios).

I cut the unnecessary parts of the Urbi 2 away or made into conditional on configuration or compilation phases. To make the rest of the Urbi 2 Aibo-compatible, I added support with Open-R API. The work also involved the fixing problems of the cross-compilation, because Aibo's processor is a MIPS IV, RM-7000.

To have basic verification of the Urbi, I put efforts to execute the Urbi 2 tests against the remote server on Aibo and when the tests passed successfully, the basics of the Urbiscript language are executable on Aibo.

The final changes are around a 200 kB patch against the original software. The changes are conditional, the same code base can be still compiled for other robots or in a x86 native server on a computer.

The modified Urbi 2.3 sources can be downloaded from here: Urbi SDK 2.3 for Aibo

Urbi server for Aibo

The last step of the development to write the Urbi drivers for the devices on Aibo and build the Urbi 2 server. This work is not fully done because there are performance problems with the Urbi server when it executes some Urbi scripts in real-time. Some Aibo-specific performance optimizations has been done already to resolve this problem:

  • The old toolchain was only able to build binaries with -O2. Now, the new toolchain compiles with full speed optimization (-O3) the Urbi server.
  • I was able to reduce the Urbi 2 server binary size by ~46 % using different optimizations.
  • A special coroutine stack policy in libsched has been developed for Aibo to reduce the memory consumption of the Urbi 2 server. This optimization reduced the initial memory consumption by ~2.5 Mb.

Further investigation is in progress.

I can not publish the source code of the server yet caused by legal restrictions, but the binary version of a memory stick with an alpha version of the Urbi server for Aibo can be downloaded from here: Urbi 2.3 server for Aibo (alpha)

In action

The following video demonstrates how the Urbi 2 server works on Aibo. I recommend switching to fullscreen to see the Urbi commands executed on the console.

What happens:

  • Creating a new object "a" on the server and assign a value.
  • Switching on/off the motors.
  • Query and set motor values.
  • Moving a joint in a for cycle -> waving with a leg.

Please note: There is no any warranty regarding the software you can download from this page.

Options: