0. Introduction

I decided to write this tutorial because I find some issues when I firstly installed ROS on my TinkerBoard, so maybe this page can help someone else to use this tool. This tutorial works with TinkerOS 1.4 and TinkerOS 1.8 (you can find it on the TinkerOS official page).

In this tutorial I assume that you alreay know how to connect to your TinkerBoard, either connecting it to a external screen or using a SSH connection and open a terminal.

1. Downloading and installing

In order to compile ROS for your device you’ll need to download some tool so type:

sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
sudo apt install dirmngr #needed if using TinkerOS 1.8
sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116

This will add the ROS repository to your repositories list. Now you have to update the repos and install the packages:

sudo apt-get update
sudo apt-get install -y python-rosdep python-rosinstall-generator python-wstool python-rosinstall build-essential cmake

Once you installed everything, you have to initialize ROS. So:

sudo rosdep init
rosdep update

Now you have to create an enviroment where you’ll compile ROS and download and compile the external parts:

mkdir -p ~/ros_catkin_ws
cd ~/ros_catkin_ws

rosinstall_generator ros_comm --rosdistro kinetic --deps --wet-only --tar > kinetic-ros_comm-wet.rosinstall

wstool init src kinetic-ros_comm-wet.rosinstall

mkdir -p ~/ros_catkin_ws/external_src
cd ~/ros_catkin_ws/external_src
wget http://sourceforge.net/projects/assimp/files/assimp-3.1/assimp-3.1.1_no_test_models.zip/download -O assimp-3.1.1_no_test_models.zip
unzip assimp-3.1.1_no_test_models.zip
cd assimp-3.1.1
cmake .
make -j4 -w
sudo make install

The last part is the installation itself. You have to type:

cd ~/ros_catkin_ws
rosdep install -y --from-paths src --ignore-src --rosdistro kinetic -r # if using TinkeOS 1.4
rosdep install -y --from-paths src --ignore-src --rosdistro kinetic -r --skip-keys='sbcl' # if using TinkeOS 1.8
sudo ./src/catkin/bin/catkin_make_isolated --install -DCMAKE_BUILD_TYPE=Release --install-space /opt/ros/kinetic

In order to run ROS without sourcing the “setup.bash” file, just add one line at the end of the ~/.bashrc file by typing this:

echo "source /opt/ros/kinetic/setup.bash" >> ~/.bashrc

That’s it!

2. Notes

I had some errors while installing packages with “apt-get install”. The terminal said:

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
    LANGUAGE = (unset),
    LC_ALL = "en_US.UTF-8",
    LC_PAPER = "it_IT.UTF-8",
    LC_ADDRESS = "it_IT.UTF-8",
    LC_MONETARY = "it_IT.UTF-8",
    LC_NUMERIC = "it_IT.UTF-8",
    LC_TELEPHONE = "it_IT.UTF-8",
    LC_TIME = "it_IT.UTF-8",
    LC_NAME = "it_IT.UTF-8",
    LANG = "C.UTF-8"

To solve it, just send:

sudo dpkg-reconfigure locales
sudo locale-gen en_US en_US.UTF-8
echo "export LC_ALL="en_US.UTF-8"" >> ~/.bashrc