ICub Simulator Installation

From Wiki for iCub and Friends
Revision as of 12:35, 12 June 2020 by Ngenesio (talk | contribs) (→‎SDL)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

iCub Simulation


Parts of the RobotCub software and the iCub simulator depend on external libraries. Here we keep track of the list of libraries needed and documentation for installing them.

The typical RobotCub software dependencies, see Chapter 6 of the iCub manual ( for instructions on how to install these dependencies.

The iCub Simulator needs extra libraries:

  • ODE (Open Dynamic Engine)
  • SDL (Simple DirectMedia Layer)


We assume you have prepared your system as in the Chapter 6 of the manual (

Important: the iCub installation binaries provide all the dependencies and the simulator so you no longer need to follow the steps below. To install the simulator you can follow the iCub installation instructions in the manual.


Instructions for different systems are reported below.

Common notes:

The simulator now supports version >= 0.10built as single or double precision. Double precision is recommended and important if planning to import 3D models into the simulator.

Single precision is much faster and uses less memory but you might encounter more numerical errors. The double precision was suggested as you would have more accuracy and stability, the downside is that it works a bit slower.

--enable-libccd option is necessary if you want cylinder-cylinder collisions support. This is handy for example for bimanual tasks - all iCub fingers are cylinders.


 sudo apt-get install libglut3 libglut3-dev libode-dev


Install vcpkg and then:

 vcpkg install ode


Install homebrew and then

 brew install ode


The new simulator requires the SDL (Simple DirectMedia Layer) drawing libraries.


In Linux Debian/Ubuntu just install libsdl1.2-dev. No environment variables will be needed.

 sudo apt-get install libsdl1.2-dev


Install sdl via vcpkg:

 vcpkg install sdl1


Install sdl via homebrew:

 brew install sdl


The latest version of the iCub simulator can be found in $ICUB_ROOT/main/src/simulators/iCubSimulation.

To know how to use the simulator refer to the README file included with the source code. (Also available in this manual as Simulator README).

To compile the simulator

If the required libraries are correctly installed, icub simulator will be compiled correctly when compiling iCub software. Make sure you execute the install_applications target.

To run the simulator run iCub_SIM, it will then pick up the default configuration files if make install_applications is used. Alternatively specify the configuration file on the command line.

Drawstuff dependencies

The dependency on these routines has now been removed. For old notes see here.