Recommended Setup with Ubuntu Xenial and ROS Kinetic

This page describes how to setup ROS Kinetic and Ubuntu 16.06 Xenial Server on an Olimex A20 Micro board. This board offers 3 UART ports that need to be configured.

  1. Get Vanilla Xenial Server: http://www.armbian.com/olimex-micro/
  2. Copy image to SD card
  3. Follow http://wiki.ros.org/kinetic/Installation/Ubuntu which also works with ARM devices like the A20.
  4. Permanent switch back to upstart: “Install the upstart-sysv package, which will remove ubuntu-standard and systemd-sysv (but should not remove anything else – if it does, yell!), and run sudo update-initramfs -u. After that, grub's “Advanced options” menu will have a corresponding “Ubuntu, with Linux … (systemd)” entry where you can do an one-time boot with systemd. If you want to switch back to systemd, install the systemd-sysv and ubuntu-standard packages. ”
U-Boot will not boot the OS if something is sending data to UART0!
power information can be found here (cat the files): /sys/power/axp_pmu
  1. Remove UART0 from the console (to which it is attached to by default). Guide here: https://raspberrypihobbyist.blogspot.ch/2012/08/raspberry-pi-serial-port.html
  2. Verify that UART6 and UART7 (on UEXT1 and UEXT2 respectively) are correctly defined in the FEX file
  3. “The UART6, which is wired to the UEXT1 connector seems to correspond to the /dev/ttyS1 device and UART7 is wired to the UEXT2 connector corresponding to /dev/ttyS2 device in the debian linux.” - Source
  4. IMU is connected to /dev/ttyS2
  5. LIDAR is connected to /dev/ttyS1
  6. Calibrate Adafruit 10-DOF IMU as follows: rover@micro:~/RTIMULib/Linux/RTIMULibCal/Output$ ./RTIMULibCal then copy ini file to octanis1_description/params
if you experience compiler hangs, try limiting the catkin_make jobs: VERBOSE=true catkin_make -j1
All the following steps are done inside the catkin workspace (Octanis1-ROS repository) on the actual flight hardware with LIDAR and IMU attached. Make sure you source both setup.bash files!


  • <fc #ff0000> run export ROS_HOSTNAME=$(hostname -I) on ALL ROS instances and ALL terminals running nodes/launchfiles (MASTER and SLAVES) </fc>
  • sudo apt-get install ros-kinetic-tf
  • sudo apt-get install ros-kinetic-roslint
  • sudo apt-get install ros-kinetic-robot-state-publisher
  • sudo apt-get install ros-kinetic-robot-localization
  • sudo apt-get install ros-kinetic-mavros
  • sudo apt-get install ros-kinetic-rosbridge-suite
  • disable console use of ttyS0 port in boot.cmd and regenerate the boot.scr
  • sudo systemctl disable serial-getty@ttyS0.service
  • You can set export ROS_MASTER_URI=IP_ADDRESS_OF_ROS_MASTER on the Olimex. This allows you to run roscore on a computer that has rviz. The laptop running rviz can be made to share it's “internet connection” to the Olimex via Ethernet.
  • Install RTIMULib (required for “romainreignier/rtimulib_ros”)

What you need to run to be ready to scan the ground profile:

  1. Running IMU publisher rosrun bosch_imu_driver bosch_imu_node.py _port:=/dev/ttyS2 _frame_id:=IMU
  2. Running the LIDAR publisher rosrun xv_11_laser_driver neato_laser_publisher _port:=/dev/ttyS1 _frame_id:=LIDAR
  3. Running the robot_state_publisher with URDF file roslaunch octanis1_description description.launch
  4. Running the ekf_localization_node with YAML config file roslaunch octanis1_description ekf_state.launch
  5. Running the shutdown function roslaunch octanis1_description shutdown.launch

Stereo Vision

  1. sudo apt-get install ros-kinetic-camera-info-manager-py libcamera-info-manager-dev
  2. Download libuvc from github and run catkin_make

LIDAR 2 PointCloud

  1. sudo apt-get install ros-kinetic-octomap

Easy Install from Octanis1 Repository (WIP)

  1. clone Octanis1-ROS
  2. $ ./scripts/install.sh
  3. sudo service ros-system-daemon start

A python script started from monit listens for a GPIO high on pin XX on the Olimex A20 Micro and shuts down the OS gracefully. The following must be completed for the script to run:

- pip install pyA20

Alternative Method

You can download a precompiled Debian Jessie image here ( for Flash memories of 8Go or greater ): lalalal To get a working device proceed as follow:

  • Unzip the image
  • Connect the flash card and unmount the partitions
  • Burn the “.img” on the Flash memory with for instance: dd if=/PATH/TO/A20.img of=/dev/mmcblk0 bs=1M
  • On the flash file system, modify /etc/network/interfaces accordingly to your network settings

That is it ! You now have a working Jessie distribution working on your A20 board. Root access is available with the username: root and the password: olimex. This custom image comes with the PWM module enabled and ROS Indigo installed under ~/ros_catkin_ws.

In case you want to specifically edit the module configuration of the board (eg. disable the power hungry HDMI support), you need to regenerate the modules and firmware directories and update them to the Flash memory. To do so, you have to recompile part of the Linux Kernel. The following steps are here to guide you through the process.

First of all, you need to clone the repository for linux Sunxi used on the A20 and checkout to the tested version:

The device Firmware and module drivers can be regenerated for a custom configuration. To do so first the default configuration for the board must be loaded. Here you can download the default configuration file a20_defconfig.tar.gz. Unzip this file and copy it into the linux_sunxi directory as follow: cp a20_defconfig /home/linux-sunxi/arch/arm/configs/ and load the configuration with make ARCH=arm a20_defconfig.

Now that the modules and firmware directories are properly generated, you just have to upload them to the Flash. Connect the Flash memory and mount the second partition (7.9Go). From your linux_sunxi directory proceed as follow:

  • # rm -rf /$MOUNTPOINT/lib/modules/*
  • # rm -rf /$MOUNTPOINT/lib/firmware/*
  • # cp -rfv ./out/lib/modules/* /$MOUNTPOINT/lib/modules/
  • # cp -rfv ./out/lib/firmware/* /$MOUNTPOINT/lib/firmware/
  • # sync
  • Unmount the device

You can now use your device and your A20 board will boot with the newly updated firmware and enabled drivers.

RedHat distributions are not using the same compiler as Debian based. On a RedHat distribution first install the compiler for arm: sudo dnf install gcc-arm-linux-gnu. Then perform as indicated in the previous points replacing all the instances of arm-linux-gnueabihf- by arm-linux-gnu-.
The kernel used by the a20_olinuxino_micro is an old one (3.4.104+) and as such does not compile well with gcc5+. To manage to compile with a gcc5+, a few manual fixes must be applied to the repository.

  • orb/olimexa20.txt
  • Last modified: 6 years ago
  • by sam