THIS PAGE IS PROBABLY A BIT OUTDATED. MORE RECENT INFORMATION CAN BE FOUND IN THE GIT REPOSITORY!
This page will walk you through the installation of iCub's software. You can find most of the information on the web; here we provide the pointers to the things you need to do to make it fast and easy. If you are having problems, ask Serena Ivaldi.
Before starting, we list the useful links:
We hereby assume you're using Ubuntu 12.04. In case you want to upgrade to Ubuntu 14.04:
We advice to install all source code in your home folder, and change the installation prefix during cmake compilation.
For example, for the user "icub" you may set the following installation prefix:
This way you will have:
/home/icub/software/src : folder where you put icub, yarp, ...
/home/icub/software/bin : binaries
/home/icub/software/lib : libraries
.. and so on. This requires to update the LD_LIBRARY_PATH and PATH environment variables, which you can easily do when you install the software.
You should prepare your machine first by installing the useful packages/libraries:
sudo apt-get install doxygen cmake g++ mercurial pkg-config build-essential
For yarp you only need ACE:
sudo apt-get install libace-dev
For iCub software you need some additional libraries (opencv, gfortran, ode, gtk, ..):
sudo apt-get install cmake-curses-gui sudo apt-get install libncurses5-dev libgtkmm-2.4-dev libglademm-2.4-dev libgsl0-dev libode-dev libsdl1.2-dev sudo apt-get install libcv-dev libopencv-dev libhighgui-dev libcvaux-dev libopencv-gpu-dev libopencv-highgui-dev libopencv-core-dev sudo apt-get install gfortran [for Ubuntu 12] sudo apt-get install libqt3-mt-dev [for Ubuntu 14] sudo apt-get install libqt4-dev libqt4-gui libqt4-qt3support
the last package is necessary to install IPOPT:
For Gazebo and CoDyCo software you will need to install some libraries
sudo apt-get install libprotoc-dev libprotobuf-dev protobuf-compiler libqt4-dev libtar-dev libcurl4-openssl-dev sudo apt-get install libcegui-mk2-dev libopenal-dev libtbb-dev libswscale-dev libavformat-dev libavcodec-dev sudo apt-get install libgts-dev libltdl3-dev playerc++ libxml2-dev libfreeimage-dev freeglut3-dev sudo apt-get install libogre-1.8-dev sudo apt-get install libtinyxml-dev sudo apt-get install libboost-dev libboost-system-dev libboost-all-dev sudo apt-get install libeigen3-dev
The bashrc file should be modified to include a number of environmental variables. We suggest to create a file called bashrc_icub and put it in /home/icub/software. If you followed our advice about where to put the sources, then you can copy-paste the following lines in the bashrc_icub file:
echo "Exporting iCub environment variables from specific file.." export ICUB_INSTALL_PREFIX=/home/icub/software export YARP_ROOT=$ICUB_INSTALL_PREFIX/src/yarp export YARP_DIR=$YARP_ROOT/build export YARP_CONF=/home/icub/.yarp export YARP_ROBOT_NAME=iCubDarmstadt01 export ICUB_ROOT=$ICUB_INSTALL_PREFIX/src/icub-main export ICUB_DIR=$ICUB_ROOT/build export YARP_DATA_DIRS=$ICUB_INSTALL_PREFIX/share/yarp:$ICUB_INSTALL_PREFIX/share/iCub:$ICUB_INSTALL_PREFIX/share/ICUBcontrib export IPOPT_DWN_DIR=$ICUB_INSTALL_PREFIX/src/Ipopt export IPOPT_DIR=$ICUB_INSTALL_PREFIX/src/Ipopt/build export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/home/icub/software/lib/pkgconfig/ export PATH=$PATH:$ICUB_INSTALL_PREFIX/bin:$ICUB_INSTALL_PREFIX/scripts export LD_LIBRARY_PATH=$ICUB_INSTALL_PREFIX/lib:$IPOPT_DIR/lib export GAZEBO_PLUGIN_PATH=$GAZEBO_PLUGIN_PATH:$ICUB_INSTALL_PREFIX/lib export GAZEBO_MODEL_PATH=$GAZEBO_MODEL_PATH:$ICUB_INSTALL_PREFIX/src/icub_gazebo echo "Welcome $YARP_ROBOT_NAME!"
This file should be included in the .bashrc file, inside your home folder. To do this, add these lines at the top of the .bashrc file:
# iCub software if [ -f /home/icub/software/bashrc_icub ]; then . /home/icub/software/bashrc_icub fi
Make sur these lines are added before this line: [ -z "$PS1" ] && return
Gazebo was selected as the official CoDyCo simulator, and is now the official iCub simulator. You can find the tutorials and more information on GazeboSim.org.
You can choose the standard download via apt-get, check their wiki pages for installation. Remember to install also the development library.
You can also install the simulator from sources, as you get to use different physical engines: ODE, Bullet, SimBody and DARTS.
To control the iCub, you need yarp and iCub's main software (icub-main).
There are other software repositories related to iCub that may be useful (not mandatory, but good to know):
To install the yarp plugins for using Gazebo as simulator, do:
export CODYCO_SUPERBUILD_ROOT=$ICUB_INSTALL_PREFIX/src/codyco-superbuild export PATH=$PATH:$ICUB_INSTALL_PREFIX/bin:$ICUB_INSTALL_PREFIX/scripts:$CODYCO_SUPERBUILD_ROOT/build/install/bin:$CUDA_DIR/bin:$OPT_INSTALL_PREFIX/bin export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ICUB_INSTALL_PREFIX/lib:$CODYCO_SUPERBUILD_ROOT/build/install/lib:$CUDA_DIR/lib64:$CUDA_DIR/lib:$IPOPT_DIR/lib:$OPT_INSTALL_PREFIX/lib
=> Before the codyco-superbuild, there was a long list of modules to download, such as: You can then proceed with the installation of:
sudo apt-get install update-manager-core
sudo apt-get update sudo apt-get upgrade sudo do-release-upgrade --check-dist-upgrade-only --devel-release
sudo do-release-upgrade -d