For ROS diamondback on Natty click here.
ROS on Gumstix Overo with Ubuntu Lucid
This howto summarizes the process of compiling ROS for Ubuntu on the Gumstix. ROS is natively compiled on the Gumstix and all dependencies are installed as Ubuntu packages.
This is a straight forward solution and doesn't involve the process of cross-compilation. The only drawback is that the native compilation takes some time.
We use the Overo COM with a Tobi expansion board which is hooked up to the internet via Ethernet.
Setting up Ubuntu Lucid on Gumstix + ROS Dependencies
Ubuntu provides a tool to generate a rootfs for arm based systems. This will be used here to set up a lucid rootfs. We assume that you have already set up the Gumstix and prepared an SD card holding a FAT partition with a recent u-boot, MLO and the 2.6.34 kernel (see Gumstix documentation) as well as the ext3 partition where the Ubuntu image will go.
The next steps are done on a regular computer running Ubuntu (must be Lucid = Ubuntu 10.04 - newer version probably work). First, install rootstock
sudo aptitude install rootstock
Second, Rootstock is used to build the rootfs image for the arm system. With "--seed" option you can specify additional packages to install into rootfs. This is used here to add the ros dependencies.
sudo rootstock --fqdn overo --login ubuntu --password 123 --imagesize 2G --seed openssh-server,vim,build-essential,python-yaml,cmake,subversion,wget,python-setuptools,pkg-config,python-dev,ntp,libboost-dev,libboost-all-dev,libapr1,libapr1-dev,libaprutil1,libaprutil1-dev,liblog4cxx10,liblog4cxx10-dev
If a very small image is wanted, build rootfs without "--seed" option. Rosdep can later be used to install anything necessary to build ROS once Ubuntu is running on the Gumstix.
If you wish to login through serial terminal add "--serial ttyS2". For connecting to wireless with Overo Air you should add "wireless-tools" and "wpasupplicant" to seed string. You will also need to install modules compiled for relavent kernel and obtain copies of the Marvel libertas_sdio wireless firmware binaries. See Here for firmware binaries and wifi connection info.
Rootstock now fetches packages, builds your image and installs dependencies (uses debootstrap and qemu).
When the rootfs is finished, extract the tarball to ext3 partition on SD card of Gumstix.
Boot the Gumstix, login with user and pw specified before. Set up Ethernet connection to Internet. Set up system as needed (sshd, user, ...).
Getting and compiling ROS
Prepare build an get ROS
From now on work as root on the Gumstix or use sudo.
Make folders for ros (do not move the ros root folder after compilation, this breaks paths of linked libraries e.g. rospack)
mkdir -p /opt/ros/cturtle/ros
Checkout ros cturtle
svn co https://code.ros.org/svn/ros/stacks/ros/tags/cturtle /opt/ros/cturtle/ros
Create setup.sh as usual and source
Prevent build of rxtools which we will never use on Gumstix
If you want to exclude stuff from build add ROS_NOBUILD where needed.
Go to ros main folder and start compilations of ros (takes ~ 2-3h)
roscd time rosmake
Once everything is build you are ready to use ROS. Everything works as usual.
After initial compilation put ROS_NOBUILD in every folder that has been build. You need to delete all of them if you update ros and want to rebuild ROS. In that case don't forget to add ROS_NOBUILD to rxtools again...
Check first where ROS_NOBUILD will be added
cd /opt/ros/cturtle/ros && find | grep CMakeCache.txt$ | sed -e "s+build/CMakeCache.txt+ROS_NOBUILD+g"
then create ROS_NOBUILD files in all folder where “build/CMakeCache.txt” is present → thus package was build
cd /opt/ros/cturtle/ros && find | grep CMakeCache.txt$ | sed -e "s+build/CMakeCache.txt+ROS_NOBUILD+g" | xargs touch
Some packages will have throw SIGILL during serialization. (eg. imu_node) This can be fixed by adding -msoft-float to build flags. This is obviously not ideal as you lose the hardware floating point processor (if it has it). However, this issue hasn't entirely been fixed yet - see here for some details.