|
|
Line 1: |
Line 1: |
| == Ubuntu Server 8.04 Installation ==
| | ''See [[pc104/Archive]] for information on the Ubuntu Server installation and tests that we performed to get rid of the laptop dependency. There are a couple of unresolved issues with that method (dragonfly cameras and Canbus), therefore for now we went back to the original setup, explained below.'' |
|
| |
|
| On 2009-05-21, we installed Ubuntu '''Server''' 8.04 'Hardy Heron' on a brand new 4GB Flash IDE memory.
| | The pc104 CPU board that is attached to our iCub boots from a read-only memory. |
|
| |
|
| First of all, we changed the BIOS setting ''First Boot Device'' to: USB-CDROM. We had a Ubuntu Server 8.04 CD inside the drive. (It is apparently possible to boot and install directly from a Flash memory, but a CDROM installation is easier.)
| | After booting, it mounts a part of the hard-disk of icubsrv (the laptop, IP address 10.10.1.51). |
|
| |
|
| Here is our configuration on Ubuntu Server 8.04:
| | After that, it runs the scripts that are found in /exports/code-pc104/pc104/hooks. |
| * hostname: pc104
| | You can use those scripts for making some configuration permanent on pc104 and/or to run programs. |
| * automatic partitioning (which will partition the 4GB drive into an ext3 and a swap partition)
| | They set up the yarp namespace, start yarp run, configure the keys for passwordless log-ins, etc. |
| * username: icub
| |
| * no HTTP proxy
| |
| * software selection: OpenSSH (which includes scp to copy files among machines), nothing else
| |
| | |
| After a while, the CDROM will eject automatically. Remove it and, after reboot, change the BIOS boot sequence settings to the default, which is:
| |
| * Primary Boot Device: Hard Disk
| |
| * Second Boot Device: Disabled
| |
| * Third Boot Device: Disabled
| |
| | |
| At this point we have a minimal Linux system (474MB).
| |
| | |
| === Network ===
| |
| | |
| Change the IP to 10.10.1.50 by editing /etc/network/interfaces in the following way:
| |
| auto lo
| |
| iface lo inet loopback
| |
| | |
| auto eth0
| |
| iface eth0 inet static
| |
| address 10.10.1.50
| |
| netmask 255.255.255.0
| |
| network 10.10.1.0
| |
| broadcast 10.10.1.255
| |
| gateway 10.10.1.254
| |
| | |
| Add the following lines in /etc/hosts (besides the already-existing lines):
| |
| 10.10.1.52 chico2
| |
| 10.10.1.1 cortex1
| |
| 10.10.1.2 cortex2
| |
| 10.10.1.3 cortex3
| |
| 10.10.1.4 cortex4
| |
| 10.10.1.5 cortex5
| |
| 10.10.1.6 cortex6
| |
| | |
| Then, copy the content of directory ~/.ssh/ from a machine we have used in the past to connect to pc104 (e.g., icubsrv or chico2) to the pc104 itself. This will permit passwordless login sessions, necessary for yarprun and demos.
| |
| On the other machines of the network which we use to connect to pc104 (e.g., chico2, cortex cluster) you might need to delete a line of your ~/.ssh/known_hosts file (the "offending line" which contains an old key -- follow the ssh error message and just delete that line).
| |
| Now, passwordless logins to pc104 should be no problem from the other machines.
| |
| | |
| == After the installation ==
| |
| | |
| Install the following packages:
| |
| sudo apt-get install gcc g++ cmake make cvs subversion ssh libace-dev libgsl0-dev
| |
| | |
| Write this at the bottom of ~/.bashrc
| |
| YARP_DIR=/home/icub/yarp2/
| |
| export YARP_DIR
| |
| YARP_ROOT=$YARP_DIR
| |
| export YARP_ROOT
| |
| | |
| Then, before the following line of /etc/bash.bashrc
| |
| [ -z "$PS1" ] && return
| |
| add this:
| |
| # per-user environment variables (non-interactive and interactive mode)
| |
| source $HOME/.bash_env
| |
| | |
| Now create a file ~/.bash_env (used by non-interactive sessions, namely commands launched via yarprun from another machine) containing these variables:
| |
| export ICUB_DIR=/home/icub/iCub
| |
| export ICUB_ROOT=$ICUB_DIR
| |
| export PATH=$PATH:/home/icub/iCub/bin
| |
| | |
| == Additional RobotCub software ==
| |
| | |
| === iCub: downloading the repository ===
| |
| | |
| In /home/icub, do:
| |
| cvs -d vislab@cvs.robotcub.org:/cvsroot/robotcub co iCub
| |
| | |
| For now, don't compile iCub but start installing YARP instead.
| |
| | |
| === YARP ===
| |
| | |
| Type this from our homedir:
| |
| cvs -d:pserver:anonymous@yarp0.cvs.sourceforge.net:/cvsroot/yarp0 login
| |
| cvs -z3 -d:pserver:anonymous@yarp0.cvs.sourceforge.net:/cvsroot/yarp0 co -P yarp2
| |
| cd yarp2
| |
| | |
| Enter yarp2/conf and do:
| |
| cp ExternalModules.cmake.template ExternalModules.cmake
| |
| then write the following lines in ExternalModules.cmake:
| |
| SET(EXTERNAL_MODULES icub)
| |
| SET(icub_DIR "/home/icub/iCub/src/modules")
| |
| | |
| We now have to install two FireWire IEEE-1394 libraries needed by dragonfly and dragonfly2: '''libraw1394''' and '''libdc1394'''. Rather than installing the Ubuntu packages, we compile them manually. Do these two sequences of commands from icub's home dir (pay attention to the path option given to ./configure). First '''libraw1394''':
| |
| | |
| wget http://www.linux1394.org/dl/libraw1394-2.0.2.tar.gz ''<-- or a newer version from http://www.linux1394.org/''
| |
| tar xzvf libraw1394-2.0.2.tar.gz
| |
| cd libraw1394-2.0.2/
| |
| ./configure --prefix=/usr
| |
| make
| |
| sudo make install
| |
| | |
| Now, as for '''libdc1394''', we follow the instructions in $ICUB_DIR/src/modules/dragonfly2/linux/readme.txt:
| |
| wget http://downloads.sourceforge.net/libdc1394/libdc1394-2.1.0.tar.gz?modtime=1200479950&big_mirror=0
| |
| tar xzvf libdc1394-2.1.0.tar.gz
| |
| cd libdc1394-2.1.0/
| |
| | |
| ./configure --prefix=/usr
| |
| which must say
| |
| Configuration (libdc1394):
| |
| libraw1394 support (Linux legacy): Enabled ''<-- required by yarpdev. If you obtain 'Disabled', check the libraw1394 installation''
| |
| Juju support (Linux new): Enabled
| |
| Mac OS X support: Disabled (Mac OS not detected)
| |
| Windows support: Disabled (Windows not detected)
| |
| IIDC-over-USB support: Disabled (libusb-1.0 not found)
| |
| | |
| and finally
| |
| make
| |
| sudo make install
| |
| | |
| Note: by default, in Ubuntu, only the administrator has access to the FireWire camera device files in /dev. So we need to manually add user icub into the video and disk groups:
| |
| sudo usermod -a -G video icub
| |
| sudo usermod -a -G disk icub
| |
| | |
| TODO: fix libdc1394 (yarpdev is giving "Can't set DC1394_CAPTURE_FLAGS_DEFAULT", both with dragonfly and dragonfly2)
| |
| TODO: fix the following modules -> lib_plxapi (Canbus)
| |
| | |
| Now
| |
| ccmake .
| |
| | |
| In CMake, type 'c' (whenever necessary) and turn on the following modules only:
| |
| CREATE_DEVICE_LIBRARY_MODULES
| |
| CREATE_LIB_MATH
| |
| | |
| ENABLE_icubmod_canmotioncontro
| |
| ENABLE_icubmod_dragonfly2
| |
| ENABLE_icubmod_icubarmcalibrat
| |
| ENABLE_icubmod_icubheadcalibra
| |
| ENABLE_icubmod_icublegscalibra
| |
| ENABLE_icubmod_pcan
| |
| ENABLE_icubmod_xsensmtx
| |
| | |
| ENABLE_yarpmod_serial
| |
| ENABLE_yarpmod_serialport
| |
| MERGE_DEVICE_LIBRARY_MODULES
| |
| | |
| === iCub: compiling and installing ===
| |
| | |
| Enter iCub/ and do:
| |
| ccmake .
| |
| c
| |
| | |
| Enable these modules only:
| |
| BUILD_IN_ROOT
| |
| (to be completed)
| |
| | |
| == Old setup (prior to 2009-05-21) ==
| |
| | |
| pc104 booted from a read-only memory.
| |
| | |
| after booting, it mounted a part of the hard-disk of icubsrv (the laptop, IP address 10.10.1.51).
| |
| | |
| after that, it ran the scripts that are found in /exports/code-pc104/pc104/hooks.
| |
| you can use those scripts for making some configuration permanent on pc104 and/or to run programs.
| |
| they set up the yarp namespace, they start yarp run, configure the keys for passwordless log-ins, etc.
| |
|
| |
|
| [[Category:Vislab]] | | [[Category:Vislab]] |