Skip to content

Latest commit

 

History

History
418 lines (299 loc) · 14.9 KB

INSTALL.md

File metadata and controls

418 lines (299 loc) · 14.9 KB

Installation

This document contains the build and installation instructions for the Generic Robotics Library. While there is a lot of functionality supported by grl, most dependencies are optional. A complete list of dependencies and their categories can be found in the BasisProject.cmake file.

Automated setup scripts that put code in ~/src can be found in the robotics_setup repository.

This software has an optional runtime dependency on V-REP and ROS, independently or together.

Ubuntu 14.04 and 16.04 Automated Installation

This will do an automated build the minimal KUKA Driver code in the ~/src folder. It supports use with ROS indigo and kinetic, or direct use as a library.

ROS Users:

We recommend installing iiwa_stack in addition to grl for full ROS integration.

Also take a look at costar_stack which uses grl and provides full blown system integration tools for many typical robot arm tasks such as pick and place operations.

Install Steps:

  1. Setup git as explained in these instructions
  2. Enable connecting to github with ssh as explained in these instructions
  3. Run the following in terminal:
    # first prevent [python permission errors](http://stackoverflow.com/a/40767020/99379)
    sudo chown -R $USER /usr/local/lib/python2.7
    cd ~
    mkdir src
    cd src
    git clone https://github.com/ahundt/robotics_setup.git
    cd robotics_setup
    ./grl_kuka.sh
  1. Follow the iiwaKukaRobotSetup Tutorial for grl
  2. You should now have the KUKA FRI zip in ~/src/grl/data/FRI-Client-SDK_Cpp.zip.
  3. Re-run ./grl_kuka.sh to build with FRI.

You're Done!

Ubuntu 14.04 Manual Installation

These instructions are for manually installing the ubuntu 14.04 package dependencies for grl.

sudo apt-get install libtool pkg-config build-essential autoconf automake
sudo apt-get install libboost-all-dev libeigen3-dev libopencv-dev
# CMake
sudo apt-get install cmake
# google-glog + gflags
sudo apt-get install libgoogle-glog-dev
# BLAS & LAPACK
sudo apt-get install libatlas-base-dev
# Eigen3
sudo apt-get install libeigen3-dev

# SuiteSparse and CXSparse (needed for grl, optional for ceres)
# - However, if you want to build Ceres as a *shared* library (recommended for grl), you must
#   add the following PPA:
sudo add-apt-repository ppa:bzindovic/suitesparse-bugfix-1319687
sudo apt-get update
sudo apt-get install libsuitesparse-dev

# - If you want to build Ceres as a *static* library
#   you can use the SuiteSparse package in the main Ubuntu package
#   repository:
sudo apt-get install libsuitesparse-dev

clone, build and install ceres:

git clone https://ceres-solver.googlesource.com/ceres-solver
cd ceres-solver
mkdir build
cd build
cmake ..
sudo make install
cd ../..
git clone https://github.com/google/flatbuffers.git
cd flatbuffers
mkdir build
cd build
cmake ..
sudo make install
cd ../..
git clone https://github.com/ahundt/grl.git
cd grl
mkdir build
cd build
cmake ..
sudo make install
cd ../..

Homebrew Installation for OS X and Linux

The easy installation instructions work on OS X via homebrew and Ubuntu 14.04 Linux via Linuxbrew.

ROS users:

Install ROS before following these instructions.

Linux users:

Please note that on Linux these instructions will build many dependencies from source and install them in ~/.linuxbrew, so if you need to use specific versions that are already installed these instructions may not work for you! ROS users, this may mean you!

Also on linux you may want to use brew install libname --env=inherit so it uses your native environment variable configuration.

Setup Instructions:

  1. Setup brew for OS X or Linux
  2. Linux only - add linuxbrew to your ~/.bashrc or ~/.zshrc: export PKG_CONFIG_PATH="/usr/bin/pkg-config:$HOME/.linuxbrew/bin/pkg-config" export PKG_CONFIG_LIBDIR="/usr/lib/pkgconfig:$HOME/.linuxbrew/lib/pkgconfig" export PATH="$HOME/.linuxbrew/bin:$PATH" export MANPATH="$HOME/.linuxbrew/share/man:$MANPATH" export INFOPATH="$HOME/.linuxbrew/share/info:$INFOPATH"
  3. Check that it is setup correctly brew help should output the homebrew help.
  4. OS X only - install Homebrew Cask brew install caskroom/cask/brew-cask
brew tap homebrew/science # [homebrew-science](http://brew.sh/homebrew-science/) contains many scientific libraries, such as OpenCV and pcl
brew tap homebrew/robotics # [homebrew-robotics](https://github.com/ahundt/homebrew-robotics) contains software packages needed by grl.
brew install grl

Done! (unless you need kuka drivers)

Extra steps for KUKA iiwa drivers

There are a few additional steps to get the KUKA iiwa drivers up and running. First run the following:

brew uninstall grl # we need to do some manual steps so remove the auto installed version (dependencies stay)
mkdir -p ~/local/src
cd ~/local/src
git clone https://github.com/ahundt/grl.git
cd grl

The grl code will now be in ~/local/src/grl.

Now follow the instructions in:

KUKA LBR iiwa Java Setup

ROS Users:

We recommend installing iiwa_stack in addition to grl for full ROS integration.

Also take a look at costar_stack which is integrated with grl and provides full blown system integration tools for many typical robot arm tasks such as pick and place operations.

Build Dependencies

Many dependencies are optional based on the functionality you wish to use. Details about what dependencies are for what functionality are below this table.

While there is a lot of functionality supported by grl, most dependencies are optional. A complete list of dependencies and their categories can be found in the BasisProject.cmake file.

Basic Build Dependencies

Package Version Language Description
Sunrise Connectivity Suite >= 3.0 Java Provided by KUKA, Eclipse based Java platform
Fast Robot Interface SDK >= 3.0 C++ Provided by KUKA, drivers for fast robot control
CMake BASIS >= 3.2 C++ Meta-project which makes it easy to create sharable software and libraries that work together.
Boost >= 1.54.0 C++ Collection of general use C++ libraries.
Eigen >= 3.2 C++ C++ template library for linear algebra.
Google Flatbuffers >= 1.7 Java/C++ High Performance Message Serialization Library
spdlog >= 0.11 C++ Super Fast C++ Logging Library
V-REP >= 3.2 C++ Recommended robot simulation library (Optional)

Hand Eye Calibration Dependencies

Optional unless you wish to perform Hand Eye Calibration.

Package Version Language Description
CAMODOCAL ? C++ CamOdoCal: Automatic Intrinsic and Extrinsic Calibration
ceres-solver >= 1.11 C++ Nonlinear Optimization library developed by google
BLAS ? ? Standard linear algebra APIs, see ceres-solver install instructions
gtest >= 1.7.0 C++ Google's C++ test framework used by ceres-solver
glog >= 0.3.4 C++ Google's C++ logging framework used by ceres-solver

KUKA Driver Dependencies

Standalone driver C++ dependencies:

    Threads            # pthreads, see CMake documentation
    ZeroMQ      # zeromq.org https://github.com/zeromq/libzmq
	AZMQ        # https://github.com/zeromq/azmq
	FlatBuffers # google flatbuffers https://github.com/google/flatbuffers
	Boost{program_options,filesystem,unit_test_framework,system,regex,coroutine,log,chrono}
    Nanopb             # Used in Kuka Fast Robot Interface (comes in FRI zip file)

KUKA software

You must follow the instructions at https://ahundt.github.io/grl/howto/iiwaKukaRobotSetup.html to correctly setup the software KUKA provides.

Optional

ROS    # for ROS driver http://www.ros.org/
V-REP  # for V-REP driver http://coppeliarobotics.com

Hand Eye Calibration Dependencies

	Eigen3             # Linear Algebra eigen.tuxfamily.com
    CAMODOCAL          # used for hand eye calibration plugin https://github.com/hengli/camodocal
    Ceres              # http://ceres-solver.org/ used in arm hand eye calibration

Pivot Calibration Dependencies

TRTK               # Transform Registration Toolkit, for pivot calibration https://github.com/RWTHmediTEC/TRTK

Arm Path Planning

Constrained Optimization based arm path planning dependencies:


    CisstNetlib        # https://github.com/jhu-cisst/cisstNetlib  used for inverse kinematics plugin
    cisst{cisstNumerical,cisstOSAbstraction,cisstVector,cisstCommon} # https://github.com/jhu-cisst/cisst used for inverse kinematics plugin
    sawConstraintController #  used for inverse kinematics plugin https://github.com/jhu-saw/sawConstraintController

Vision

    PCL                # point cloud library, for vision components >=1.7 recommended https://github.com/PointCloudLibrary/pcl
    freenect2          # kinect v2 drivers, for vision components https://github.com/OpenKinect/libfreenect2

UR5 Robot arm

Not yet fully implemented/tested.

    ur_modern_driver   # Universal Robots Arm Device Driver https://github.com/ThomasTimm/ur_modern_driver/

Extra Notes on dependencies

Here are some extra notes if you're planning to install dependencies manually.

Required dependencies

BLAS (Ubuntu package: libblas-dev) Boost >= 1.4.0 (Ubuntu package: libboost-all-dev) CUDA >= 4.2 Eigen3 (Ubuntu package: libeigen3-dev) glog OpenCV >= 2.4.6 SuiteSparse >= 4.2.1 # note CERES dependencies above Optional dependencies

GTest OpenMP

Standard cmake-basis build steps

you probably don't want to follow these steps

These are generic instructions for libraries that use cmake-basis. I suggest following the easy install instructions instead!

For general build and installation instructions which apply to any software developed on top of the CMake Build system And Software Implementation Standard (BASIS), please refer to the respective BASIS Installation Guide which is part of the CMake BASIS documentation.

The common steps to build, test, and install software based on CMake, including this software, are as follows:

  1. Extract source files.
  2. Create build directory and change to it.
  3. Run CMake to configure the build tree.
  4. Build the software using selected build tool.
  5. Test the built software.
  6. Install the built files.

On Unix-like systems with GNU Make as build tool, these build steps can be summarized by the following sequence of commands executed in a shell, where $package and $version are shell variables which represent the name of this package and the obtained version of the software.

$ tar xzf $package-$version-source.tar.gz
$ mkdir $package-$version-build
$ cd $package-$version-build
$ ccmake -DBASIS_DIR:PATH=/path/to/basis ../$package-$version-source

| Press 'c' to configure the build system and 'e' to ignore warnings.
| Set CMAKE_INSTALL_PREFIX and other CMake variables and options.
| Continue pressing 'c' until the option 'g' is available.
| Then press 'g' to generate the configuration files for GNU Make.

$ make
$ make test    (optional)
$ make install (optional)

An exhaustive list of minimum build dependencies, including the build tools along detailed step-by-step build, test, and installation instructions can be found in the corresponding "Building the Software from Sources" section of the BASIS how-to guide on software installation.

Please refer to this guide first if you are uncertain about above steps or have problems to build, test, or install the software on your system. If this guide does not help you resolve the issue, please contact Andrew Hundt ATHundt@gmail.com. In case of failing tests, please attach the output of the following command:

$ ctest -V >& test.log

In the following, only package-specific CMake settings available to configure the build and installation of this software are documented.

Binary Distribution Package

Please see the corresponding section of the BASIS Installation Guide.

CMake Options

(no additional CMake options considered by this package)

Advanced CMake Options

(no additional advanced CMake options considered by this package)