Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
installation [2016/01/28 11:37] – [CRAM installation] gkazhoya | installation [2022/09/15 12:56] – [Windows Install] arthur | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== CRAM installation ====== | ====== CRAM installation ====== | ||
- | If you get into problems, please consult the [[/ | + | ===== Prerequisites |
- | + | ||
- | ===== CRAM v0.2 (recommended) | + | |
- | + | ||
- | This is a guide for installing the main CRAM packages. It covers installing the packages you need to get the system up and running to the point where you can run and test it in a simulation mode. Setting up the system on a real robot is more complex (mostly involving the usual ROS-based platform setup) and is out of scope of this guide. | + | |
- | + | ||
- | ==== Prerequisites | + | |
== OS and ROS == | == OS and ROS == | ||
- | The recommended setup is Ubuntu | + | The recommended setup is Ubuntu |
This is the setup under which the CRAM team is working and it is best supported. | This is the setup under which the CRAM team is working and it is best supported. | ||
- | The core components | + | Most CRAM components should also work on older Ubuntu versions under ROS Kinetic etc. but with no guarantee. If you encounter any incompatibilities / bugs, [[/ |
- | If you don't have the latest version of ROS, [[http:// | + | If you don't have the latest version of ROS, [[http:// |
Don't forget to source the environment setup file and | Don't forget to source the environment setup file and | ||
Line 31: | Line 25: | ||
$ sudo apt-get install ros-DISTRO-roslisp-repl | $ sudo apt-get install ros-DISTRO-roslisp-repl | ||
</ | </ | ||
+ | |||
+ | where '' | ||
For information on how to use the IDE check the [[http:// | For information on how to use the IDE check the [[http:// | ||
Line 38: | Line 34: | ||
You will need those for setting up the ROS workspace and checking out code. | You will need those for setting up the ROS workspace and checking out code. | ||
+ | __**18.04 / Melodic: | ||
<code bash> | <code bash> | ||
$ sudo apt-get install python-rosinstall python-wstool | $ sudo apt-get install python-rosinstall python-wstool | ||
</ | </ | ||
+ | __**20:04 / Noetic:**__ | ||
+ | <code bash> | ||
+ | $ sudo apt-get install python3-wstool | ||
+ | </ | ||
+ | ===== Installation ===== | ||
+ | < | ||
+ | If you are new to CRAM and are curious to test the ideas behind it, you can try the [[/ | ||
- | ==== ROS workspace setup ==== | + | If you want to see the full power of CRAM, [[/ |
- | CRAM is a big system | + | Please note that [[/ |
+ | If you first tried the minimal version and are now curious | ||
+ | |||
+ | ==== Minimal installation ==== | ||
+ | |||
+ | This is a guide for installing the core CRAM packages. It installs the prerequisites of [[/ | ||
+ | |||
+ | In the '' | ||
+ | |||
+ | <code bash> | ||
+ | $ git clone https://github.com/ | ||
+ | $ git clone https://github.com/cram2/ | ||
+ | $ rosdep install --ignore-src --from-paths cram_3rdparty cram_core | ||
+ | $ cd .. && catkin_make | ||
+ | </ | ||
+ | |||
+ | Now you just need to [[/ | ||
+ | |||
+ | ==== Full installation ==== | ||
+ | |||
+ | --></ | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | This is a guide for installing the main CRAM packages. It covers installing the packages you need to get the system up and running to the point where you can run and test it in a simulation mode. Setting up the system on a real robot is more complex (mostly involving the usual ROS-based platform setup) and is out of scope of this guide. | ||
- | (If you don't like the idea of having | + | Nevertheless, |
+ | |||
+ | === ROS workspace setup === | ||
+ | |||
+ | Skip this part if you already have a ROS workspace. | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | < | ||
+ | We recommend to create separate chained (overlaid) ROS workspaces | ||
We recommend to create 3 new workspaces chained as following: | We recommend to create 3 new workspaces chained as following: | ||
Line 60: | Line 99: | ||
<code bash> | <code bash> | ||
- | $ mkdir -p ~/ | + | $ mkdir -p ~/ |
- | $ cd ~/ | + | $ cd ~/ |
$ catkin_make | $ catkin_make | ||
$ source devel/ | $ source devel/ | ||
Line 85: | Line 124: | ||
- | ==== KnowRob installation | + | === KnowRob installation === |
The knowledge base workspace will be used for installing KnowRob, which is a knowledge management system that CRAM uses for retrieving knowledge mostly about the environment, | The knowledge base workspace will be used for installing KnowRob, which is a knowledge management system that CRAM uses for retrieving knowledge mostly about the environment, | ||
Line 92: | Line 131: | ||
$ sudo apt-get install ros-DISTRO-rosjava # where DISTRO is Indigo or Jade etc. | $ sudo apt-get install ros-DISTRO-rosjava # where DISTRO is Indigo or Jade etc. | ||
$ rosdep update | $ rosdep update | ||
- | $ cd ~/ | + | $ cd ~/ |
$ wstool init | $ wstool init | ||
$ wstool merge https:// | $ wstool merge https:// | ||
$ wstool update | $ wstool update | ||
- | $ rosdep install --ignore-src --from-paths | + | $ rosdep install --ignore-src --from-paths |
- | $ cd ~/ | + | $ cd ~/ |
$ catkin_make | $ catkin_make | ||
</ | </ | ||
+ | --></ | ||
- | ==== CRAM installation ==== | ||
- | Check out and compile all the necessary repositories. | + | If you don't have a ROS workspace, please create one. For example, you can do the following: |
<code bash> | <code bash> | ||
- | $ cd ~/ | + | $ mkdir -p ~/ |
- | $ wstool init | + | $ cd ~/ |
- | $ wstool merge https:// | + | |
- | $ wstool update | + | |
- | $ cd ~/ | + | |
- | $ rosdep update | + | |
- | $ rosdep install --ignore-src --from-paths src/ | + | |
$ catkin_make | $ catkin_make | ||
+ | $ source devel/ | ||
</ | </ | ||
- | Note that the '' | + | We create |
- | Before executing this step you can edit your '' | + | |
- | If the compilation went through you're ready for some awesome programming! We recommend to go through the [[/ | + | If during '' |
- | + | Here is a hint: you need to source the ROS environment for '' | |
- | If something went wrong consult the [[/ | + | |
- | + | ||
- | + | ||
- | ---- | + | |
- | ---- | + | |
- | + | ||
- | + | ||
- | + | ||
- | ===== CRAM v0.1 (legacy) ===== | + | |
- | + | ||
- | ==== Basic ==== | + | |
- | + | ||
- | You'll have to perform the following steps: | + | |
- | + | ||
- | === Install ROS === | + | |
- | + | ||
- | If you don' | + | |
- | Currently supported versions of ROS in CRAM are Hydro and Groovy. \\ | + | |
- | Don't forget | + | |
<code bash> | <code bash> | ||
- | $ sudo rosdep init | + | $ source / |
- | $ rosdep update | + | |
</ | </ | ||
+ | where '' | ||
- | === Install roslisp addons === | + | Execute these commands and continue from the '' |
- | Install roslisp_common and roslisp_repl: | + | Now if you execute '' |
- | <code bash> | + | Don't forget |
- | $ sudo apt-get install ros-hydro-roslisp-common | + | |
- | $ sudo apt-get install ros-hydro-roslisp-repl | + | |
- | </ | + | |
- | + | ||
- | The source code can be found on GitHub: \\ | + | |
- | // | + | |
- | // | + | |
- | + | ||
- | === Install cram_core === | + | |
- | <code bash> | + | |
- | + | ||
- | The source code is hosted on GitHub: \\ | + | |
- | // | + | |
- | + | ||
- | You're done. | + | |
- | + | ||
- | ---- | + | |
- | + | ||
- | ==== For Developers ==== | + | |
- | + | ||
- | If you're planning | + | |
- | + | ||
- | === Set up your ROS environment === | + | |
- | + | ||
- | Install the '' | + | |
<code bash> | <code bash> | ||
- | $ sudo apt-get install python-rosinstall | + | source |
- | $ sudo apt-get install python-wstool | + | |
</ | </ | ||
- | Set up your ROS workspaces. Until all the CRAM packages get catkinized, you will need both catkin and rosbuild workspaces (need more details: check [[installation: | ||
- | === Get the CRAM sources into your workspace | + | === CRAM and dependencies installation (ROS Noetic Ubuntu 20.04) |
- | Go to your catkin workspace and use wstool to pull the source | + | Please checkout |
<code bash> | <code bash> | ||
- | $ cd MY_CATKIN_WORKSPACE_PATH/src | + | $ sudo apt install ros-noetic-roslisp-repl |
+ | $ sudo apt-get install python-rosinstall python-wstool | ||
+ | $ cd ~/workspace/src | ||
$ wstool init | $ wstool init | ||
- | $ wstool | + | $ wstool |
- | $ wstool | + | $ wstool |
+ | $ cd ~/workspace/ | ||
+ | $ rosdep update | ||
+ | $ rosdep install | ||
+ | $ catkin_make | ||
</ | </ | ||
- | where '' | ||
- | If you already called '' | ||
- | '' | + | === CRAM and dependencies installation (ROS Melodic Ubuntu 18.04) === |
- | Finally, let ROS acknowledge the new packages, | + | Check out and compile all the necessary repositories: |
<code bash> | <code bash> | ||
+ | $ cd ~/ | ||
+ | $ wstool init | ||
+ | $ wstool merge https:// | ||
$ wstool update | $ wstool update | ||
- | $ rospack profile | + | $ cd ~/workspace/ros |
- | $ source | + | $ rosdep update |
- | </code> | + | $ rosdep install --ignore-src --from-paths src/ -r |
- | + | ||
- | < | + | |
- | $ cd .. (i.e. cd MY_CATKIN_WORKSPACE_PATH) | + | |
$ catkin_make | $ catkin_make | ||
- | $ catkin_make install | ||
</ | </ | ||
- | === Get ready for development === | + | Note that the '' |
- | + | ||
- | Before you open emacs you might want to configure it, at least set up the clipboard properly to enable copy/paste from/to other apps. That is described in the [[http:// | + | |
- | + | ||
- | Open your emacs and enjoy the repl animation ;) | + | |
+ | For ROS melodic and the current packages, one thing needs to be fixed. The package '' | ||
<code bash> | <code bash> | ||
- | $ roslisp_repl & | + | roscd octomap |
+ | sudo nano package.xml | ||
</ | </ | ||
- | Compiling packages using the ROS build system is not enough for code written in Lisp. To compile the CRAM packages that you want to use in Lisp, type the following | + | Now remove |
- | + | < | |
- | < | + | < |
- | , | + | |
- | r-l-s | + | |
- | cram_NAME | + | |
- | RET | + | |
</ | </ | ||
- | where NAME is e.g. '' | ||
- | You're ready for some awesome Lisp programming. Check out the [[doc/ | + | The installation is finished, please continue to the section |
If something went wrong consult the [[/ | If something went wrong consult the [[/ | ||
- | ---- | + | === CRAM and dependencies installation (ROS Kinetic Ubuntu 16.04) === |
- | ==== For Advanced CRAM Development ==== | + | Check out and compile all the necessary repositories: |
- | + | ||
- | If you need more than just the core functionality of CRAM but also the other major components, **in addition to the above-mentioned steps** do the following: | + | |
- | + | ||
- | === Get the source of other CRAM components === | + | |
- | + | ||
- | Go to your catkin workspace (or rosbuild workspace depending on the package) | + | |
- | Please note that they are currently in active development.\\ | + | |
- | '' | + | |
<code bash> | <code bash> | ||
- | $ cd ~/ | + | $ cd ~/ |
- | $ wstool | + | $ wstool |
+ | $ wstool merge https://raw.githubusercontent.com/cram2/cram/master/ | ||
$ wstool update | $ wstool update | ||
- | $ rospack profile | + | $ touch iai_maps/ |
- | $ source setup.bash | + | $ cd ~/workspace/ |
- | </code> | + | $ rosdep |
- | + | $ rosdep install | |
- | where NAME: '' | + | |
- | + | ||
- | === Compile the packages === | + | |
- | + | ||
- | Rosmake and install the CRAM packages you want to use: | + | |
- | + | ||
- | <code bash> | + | |
- | $ rosdep | + | |
- | $ rosmake cram_NAME | + | |
- | $ rosdep install --from-paths src -i -y # in the workspace root | + | |
- | </ | + | |
- | + | ||
- | The above commands might not work on the catkin metapackages that you've put into your workspace just now, so you might want to build them using catkin: | + | |
- | <code bash> | + | |
- | $ cd ~/ | + | |
$ catkin_make | $ catkin_make | ||
</ | </ | ||
- | Some of the CRAM packages have external dependencies. Most of them will be resolved using the '' | + | Note that the '' |
- | The '' | + | < |
+ | Before executing this step you can edit your '' | ||
+ | --></ | ||
- | Don't forget | + | If something went wrong consult the [[/ |
- | <code lisp> | ||
- | (ros-load: | ||
- | </ | ||
- | Sometimes a restart of your Lisp environment is necessary after a '' | + | === CRAM and dependencies installation (ROS Indigo Ubuntu 14.04) === |
- | If your package didn't compile continue reading to get the missing dependencies. | + | CRAM uses the newest version of the Lisp compiler which is not available on 14.04. |
- | + | That is not a problem as we can install it ourselves. | |
- | === cram_highlevel === | + | For that please download |
- | + | Then extract the archive (in Nautilus, the file browser, it will be '' | |
- | The packages in '' | + | |
<code bash> | <code bash> | ||
- | $ sudo apt-get install ros-hydro-cmake-modules | + | $ cd ~/Downloads/sbcl-1.3.1-x86-64-linux && sh install.sh |
- | $ roscd | + | |
- | $ wstool set rosjava_jni --git https://github.com/ | + | |
- | $ rosws merge https:// | + | |
- | $ wstool update | + | |
- | $ rospack profile | + | |
- | $ source ~/.bashrc | + | |
- | $ rosdep install rosjava_jni | + | |
- | $ rosmake rosjava_jni | + | |
- | $ rosdep install knowrob | + | |
- | $ rosmake knowrob | + | |
</ | </ | ||
- | In order to use '' | + | < |
+ | KnowRob seems to have some issues with Java 7, so if the compilation step below complains about rosjava or gradle, [[https://askubuntu.com/questions/464755/how-to-install-openjdk-8-on-14-04-lts|please install Java 8]]. | ||
+ | --></ | ||
- | One of the major features of KnowRob utilized in CRAM are the semantic maps of the environment. The main maps used for the indoor scenarios in the CRAM development team can be found in the '' | + | Next step is to check out and compile all the necessary repositories: |
<code bash> | <code bash> | ||
- | $ cd MY_CATKIN_WORKSPACE/src | + | $ cd ~/ |
- | $ wstool | + | $ wstool |
+ | $ wstool merge https://raw.githubusercontent.com/cram2/cram/ | ||
$ wstool update | $ wstool update | ||
- | $ cd .. | + | $ cd ~/ |
+ | $ rosdep update | ||
+ | $ rosdep install --ignore-src --from-paths src/ | ||
$ catkin_make | $ catkin_make | ||
</ | </ | ||
- | <code bash> | + | Note that the '' |
- | $ sudo apt-get install ros-hydro-map-server | + | |
- | $ roscd | + | |
- | $ wstool set iai_maps --git https:// | + | |
- | $ wstool update | + | |
- | $ rospack profile | + | |
- | $ source | + | |
- | $ rosmake iai_maps | + | |
- | </ | + | |
- | The '' | + | If something went wrong consult |
- | <code bash> | + | |
- | $ sudo apt-get install ros-hydro-navigation | + | |
- | </code> | + | |
- | If you have a problem | + | ==== Windows Install ==== |
+ | - Enable Hardware Virtualization in your BIOS settings | ||
+ | - [[https:// | ||
+ | - Enable the WSL 2 feature in '' | ||
+ | - Set Firewall to allow WSL comunication. Easiest way is by disabling Firewall for public networks, or add a rule for WSL. | ||
+ | - [[https:// | ||
+ | - Import the image into WSL from Powershell with < | ||
+ | - Set the image as default with < | ||
+ | - Launch Ubuntu-20.04 from the windows menu. | ||
+ | - '' | ||
+ | - '' | ||
- | If you're getting '' | + | Happy hacking! |
- | If there will be a problem with '' | + | === How to launch |
- | <code bash> | + | - '' |
- | | + | - '' |
- | | + | |
- | PATH=$PATH: | + | |
- | export PATH | + | |
- | </ | + | |
- | === cram_physics | + | ===== Get ready for development ===== |
- | Another | + | Before you open emacs you might want to configure it, at least set up the clipboard properly to enable copy/paste from/to other apps. That is described |
+ | |||
+ | Open your emacs and wait until "ROS welcomes | ||
<code bash> | <code bash> | ||
- | $ sudo apt-get install ros-hydro-moveit-full-pr2 | + | $ roslisp_repl & |
- | $ rospack profile | + | |
- | $ source ~/.bashrc | + | |
</ | </ | ||
- | '' | + | Compiling packages using the ROS build system |
- | === cram_pr2 === | + | < |
- | + | , | |
- | '' | + | r-l-s |
- | + | | |
- | < | + | RET |
- | $ cd MY_CATKIN_WORKSPACE/ | + | |
- | $ wstool set iai_common_msgs | + | |
- | $ wstool update iai_common_msgs | + | |
- | $ cd .. | + | |
- | $ catkin_make | + | |
</ | </ | ||
+ | where NAME is e.g. '' | ||
- | === roslisp === | + | You're ready for some awesome programming! We recommend |
- | + | ||
- | If you for some reason will want to have the sources of the ROS Lisp packages, they can be found here: '' | + | |
- | + | ||
- | === .rosinstall === | + | |
- | The '' |