There is an easy way to install ROS (Robotic Operating System) on a Raspberry Pi 3. I’ve been experimenting with Docker recently. Docker is a tool that allows you to download multiple programs, and their settings, simultaneously. Most of the issues I’ve had with setting up ROS were just mistakes in configuration files. Misspelling words, putting files in the wrong locations or not having the right dependencies. Your first thought might be to write an install script to simplify the install. However you quickly run into problems the next time the OS is upgraded or anything moves. Docker solves these problems since the Docker container holds everything. It has the programs, environmental variables and dependencies. There are still some small tricks getting Docker to talk to your hardware but I have created some simple scripts to bridge the gap.

Step 1: Parts

You will need a Raspberry Pi 3.

It's possible that this may work on a earlier version of Raspberry Pi but it has not been tested.

Step 2: Install HypriotOS on Your Raspberry Pi 3

HypriotOs is a alternative to Raspbian. Its main purpose it to work with Docker. It is a very minimal OS, without X windows installed. X windows isn’t needed any way. It would just slow your robot down. You can download HypriotOS here. Follow their instructions to setup your wifi. Here is how I set it up on linux. Don’t forget to put in your ssid and wifi password.

git clone https://github.com/hypriot/flash.git
./flash/Linux/flash -s MY_SSID -p MY_WIFIPASSWORD https://downloads.hypriot.com/hypriotos-rpi-v1.0.0.img.zip

Step 3: Use Your Favorite Ssh Program to Connect to the Raspberry Pi 3

User name is ‘pirate‘ and password is ‘hypriot‘.

ssh pirate@black-pearl.local

If you haven't used ssh before here is an instructable.

Step 4: Clone the Gobbit Repo

Gobbit is a Robot chassis that I like. Even though the software is written for the Gobbit, it should work well with many other robots with some small modifications. Especially if your also using an L298n motor driver. This is basically a bunch of scripts that download Docker containers and set them to run on startup. If you want to see what they do just read the .sh files (bash scripts).

git clone https://github.com/frankjoshua/gobbit

Step 5: Run the Install Script

This may take a while depending on your network speed. Mine took about 10 minutes. The docker containers are about 1GB. Mostly due to ROS.

sudo ~/gobbit/setup/setup.sh

When the ROS Raspberry Pi reboots it should be running a ROS master. You can control the robot using any system that can send ROS messages. Check out this blog on how to control ROS with PocketBot. It’s the easiest way we know of.

Step 6: Test With PocketBot

You can get PocketBot on Google Play.

Gotcha: Android doesn’t seem to recognize .local addresses.

About This Instructable




Bio: Co-Founder of Tesseract Mobile.
More by frankjoshua:ROS Rasberry Pi 3 Android Telepresence Robot 
Add instructable to: