Difference between revisions of "Compilation on the pc104/icub-head with the robotology-superbuild"
(Created page with "right|50px right|150px Compilation on the computer contained in the head of the iCub robot (called pc104 or icub-head) follows...")
m (Straversaro moved page Compilation on the icub-head with the robotology-superbuild to Compilation on the pc104/icub-head with the robotology-superbuild)
Revision as of 17:47, 17 June 2018
Compilation on the computer contained in the head of the iCub robot (called pc104 or icub-head) follows the same procedure described in the documentation for installing the software on Linux documentation.
The main difference is that in addition you need to enable certain flags in CMake that enable compilation of some hardware YARP devices. Some of these devices are generic and open source and are available in yarp; others are available in icub-main because they are specific to the robot and in certain case require proprietary code (the API shipped with the hardware).
Prepare your system
The Debian Linux that comes installed on the pc104 is already configured. Before you go ahead make sure the Debian Live on the pc104 is configured to use git.
Section 9.1 gives more details on the pc104 Debian and instructions on how to update it.
After booting the pc104/icub-head you should be able to login using ssh and the icub user.
Let's call ROBOT_CODE the folder in which the source code was downloaded, then verify that the YARP_ROBOT_NAME and YARP_DATA_DIRS environment variables are present and correctly set-up.
Important: double check that the environment variable YARP_ROBOT_NAME exists and matches the name of your robot (e.g. iCubAberystwyth01).
If something is missing check the pc104 installation instructions.
Getting YARP, iCub sources and Robots configurations
You should be aware that in default installations the Linux on the pc104 mounts a directory from the laptop/server. This is visible from /usr/local/src/robot and should normally contain the software repositories in the following directories:
If for some reasons you don't have these directories you have to download the repositories from git:
cd /usr/local/src/robot git clone https://github.com/robotology/robotology-superbuild.git
Don't change the location of the repositories because the environment on the pc104/icub-head is already configured by assuming the above directories.
Compile the necessary software
Move with the terminal in /usr/local/src/robot/robotology-superbuild directory, and create the build directory:
Clean the cache and generate makefiles:
rm CMakeCache.txt ccmake ..
You need to specify the following options to compile the hardware device required by the robot:
CMAKE_BUILD_TYPE: Release ROBOTOLOGY_ENABLE_ICUB_ROBOT_ETH, set to ON ROBOTOLOGY_ENABLE_ICUB_ROBOT_CAN, set to ON
Configure (hit c).
Generate makefiles (hit g).
Compile all the necessary software:
Do not run make install, the superbuild will already take care of installing all its subprojects in /usr/local/src/robot/robotology-superbuild/build/install
Check available devices
To verify the procedure type:
among the others the list should contains also the hardware devices of the robot like:
Device "dragonfly2", C++ class DragonflyDeviceDriver2, wrapped by "grabber" Device "pcan", C++ class PlxCan, has no network wrapper ...
Configuring your Robot
In case you want to tune/modify any robot parameters, remember to create first your local copies:
yarp-config robot --import $YARP_ROBOT_NAME
Now you should have editable copies in ~/.local/share/yarp/robots/$YARP_ROBOT_NAME.
Further documentation is available at https://github.com/robotology/robots-configuration.