Please follow the below steps carefully.
Open a shell on the laptop (icubsrv)
cd /exports/code-pc104
And make sure the is not a folder named iCub, if there is, please move away the folder:
mv iCub iCub.cvs
Get the yarp source code from the repositories
cd /exports/code-pc104 svn co https://robotcub.svn.sourceforge.net/svnroot/robotcub/trunk/iCub
IMPORTANT: At this point you do not have to complie
Note: double check that the environment variable ICUB_ROBOTNAME exists and matches the name of our robot (e.g. iCubMunich01). If not add the following line in /home/icub/.bashcrc
export ICUB_ROBOTNAME=iCubMunich01
Create the $ICUB_DIR directory that should point to /usr/local/src/robot/iCub/main/build
mkdir $ICUB_DIR cd $ICUB_DIR
If you are upgrading the iCub repository, clean the cahe before generating the makefiles:
rm CMakeCache.txt
Generate the makefiles
ccmake ../
Hit 'c' to configure and enable the following flags:
CMAKE_BUILD_TYPE, set to, Release
Hit 'c' to configure. And a long list of devices (in the form of ENABLE_icubmod_*) will appear. You need to enabled the following:
ENABLE_icubmod_canmotioncontrol ENABLE_icubmod_dragonfly2 ENABLE_icubmod_logpolarclient ENABLE_icubmod_logpolargrabber ENABLE_icubmod_xsensmtx ENABLE_icubmod_icubarmcalibrator ENABLE_icubmod_icubheadcalibrator ENABLE_icubmod_icublegscalibrator ENABLE_icubmod_icubarmcalibratorj8 ENABLE_icubmod_icubhandcalibrator
Hit 'c' to configure, and enable the following:
ENABLE_icubmod_cartesiancontrollerclient ENABLE_icubmod_cartesiancontrollerserver
For our previous iCub, Version iCub 1.0 (before 12/Nov/2012), we needed to enable the following
ENABLE_icubmod_pcan: iCub 1.0
For the new iCub, version ??? if iCub>iCub 1.1.1
ENABLE_icubmod_cfw2can ENABLE_icubmod_skinprototype
and if iCub > iCub 1.x.2 enable (very unlikely, since the neck is not getting upgrade, please verify)
ENABLE_icubmod_icubheadcalibratorV2
Hit 'c' to configure
cd $ICUB_DIR make make install_applications
DO NOT run “sudo make install”, the current instructions assume that the binaries are not installed in system directories.
It may be a good idea to update the firmware, please check this page: Firmware upgrade
To verify the procedure type:
icubmoddev --list
among the others the list should contains also the new devices:
Device “dragonfly2”, C++ class DragonflyDeviceDriver2, wrapped by “grabber” Device “pcan”, C++ class PlxCan, has no network wrapper …
CMake Possible errors:
pcan/ecan fails to detect API(s): check that you have unpacked plxCanApi/esdCanApi in /usr/local/src/robot/drivers. cmake uses the environment variables PLXCANAPI_DIR/ESDCANAPI_DIR to locate these libraries. If you the pc104 has a Debian Live image >= 1.4 these should be already set, otherwise you have to do it manually. Add the following to your bashrc file in /home/icub
cd gedit .bashrc
and add the following variables:
ESDCANAPI_DIR=/usr/local/src/robot/drivers/esdCanApi PLXCANAPI_DIR=/usr/local/src/robot/drivers/plxCanApi CWF2CANAPI_DIR=/usr/local/src/robot/drivers/cfw002