Skip to content

Updating Turtlebot to Ubuntu 16.04

Harley White edited this page Aug 27, 2018 · 11 revisions

Warning: Be sure to back up any work on the computer before you update it, as it will erase the disk.

Preparing the Boot Drive

If you already have a boot drive, skip this part.

Download this Ubuntu .iso file and put it onto the drive.

Installing 16.04

  1. Insert the boot drive into a USB port on the laptop you are updating.
  2. Start up the laptop and hold F12.
  3. When the menu comes up, select the USB option.
  4. After it boots up, run the "Install Ubuntu" program on the desktop.
  5. Select a language, connect to a wi-fi network (this can be done later as well, if you need a username and password it must be done elsewhere), choose to install updates and third party software.
  6. Choose to erase the disk. (This is the recommended option), then choose "Install now" and "Continue".
  7. Set up the settings on the next pages however you want. (Tufts Turtlebots use the username "turtlebot" and the standard passward. I've been naming the computers "turtlebot-[number]-[name]", as in "turtlebot-1-leonardo", but that isn't official yet.)
  8. When installation is finished, click "Restart now".

Setting everything up

  1. Connect to wi-fi again.
  2. Run setup.sh from here to install a lot of important packages. (You can just make a new file and paste it in yourself, then do ./setup.sh in the command line.) Install the additional tutorials packages as well.
  3. Run these commands to set up the .bashrc:

sh -c "echo \"export TURTLEBOT_3D_SENSOR=astra\" >> ~/.bashrc"

sh -c "echo \"source ~/catkin_ws/devel/setup.bash\" >> ~/.bashrc"

sh -c "echo \"source /opt/ros/kinetic/setup.bash\" >> ~/.bashrc"

sh -c "echo \"export TURTLEBOT_BATTERY=/sys/class/power_supply/BAT1\" >> ~/.bashrc"

  1. Close and re-open the terminal.
  2. Run the following commands to set up the catkin workspace and download this package and its dependencies.

sudo apt-get install -y linux-headers-generic

sudo sh -c 'echo "deb-src http://us.archive.ubuntu.com/ubuntu/ xenial main restricted

deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-updates main restricted

deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse

deb-src http://security.ubuntu.com/ubuntu xenial-security main restricted" > \

/etc/apt/sources.list.d/official-source-repositories.list'

sudo apt-get update

sudo apt-get install -y ros-kinetic-librealsense

sudo apt-get install -y ros-kinetic-librealsense-camera

sudo apt-get install -y ros-kinetic-turtlebot

sudo apt-get install -y ros-kinetic-turtlebot-navigation

sudo apt-get install -y ros-kinetic-turtlebot-apps

sudo apt-get install -y ros-kinetic-turtlebot-interactions

sudo apt-get install -y ros-kinetic-turtlebot-simulator

sudo apt-get install -y ros-kinetic-audio-common

sudo wget https://raw.githubusercontent.com/orbbec/ros_astra_camera/master/56-orbbec-usb.rules -P /etc/udev/rules.d/

rosrun kobuki_ftdi create_udev_rules

sudo service udev reload

sudo service udev restart

mkdir -p ~/catkin_ws/src/dependencies

cd ~/catkin_ws/

catkin_make

cd src

git clone https://github.com/jsinapov/tufts_service_robots.git

cd dependencies

git clone --branch kinetic https://github.com/wg-perception/people.git

  1. cd back to the catkin_ws folder and do catkin_make to build everything.

Testing and troubleshooting

  1. Test that the camera works first with roslaunch astra_launch astra.launch If you get an error, try unplugging the sensor and plugging it in again.
  2. Test that the robot works by roslaunching turtlebot_bringup minimal.launch, turtlebot_navigation gmapping_demo.launch, and turtlebot_rviz_launchers view_teleop_navigation.launch
  3. Test the tbot2 code: tbot2_launch tbot2.launch, tbot2_launch amcl_navigation.launch. Also launch tbot2_launch leg_detector while the others are running, and add the /visualization_marker topic to the RViz viewer to test if the leg detector works.