Installation on Linux

From Simspark
Jump to: navigation, search

Contents


Fedora

The most easy way on Fedora systems to install simspark, is to open a terminal and type "yum install rcssserver3d" (if you want to develop agents using rcssserver3d's libraries, "run yum install rcssserver3d rcssserver3d-devel" instead). Thanks to the community members, the simspark packages have been included in Fedora's repositories as a part of Fedora Robotics SIG activities, as an effort to allow for easy development of robotics applications on Fedora.

In case you wanted to do the hard way (compile the simulator from source), continue reading:

  1. Install dependencies:
  2. There are dependencies for the simulator, ie. other libraries that simulator uses. These are:

    boost: A collection of (currently) 58 libraries for multiple purposes. This is a giant library...
    boost-devel: Development files for using boost library
    FreeType (which should be installed by default for X Window System)
    FreeType-devel
    ruby: A dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write.
    ruby-devel: Development files for using ruby language
    SDL: (A multimedia library, installed by default): Preferably all the SDL packages
    SDL-devel: Development files for using SDL
    DevIL: (Developers Image library)
    DevIL-devel: Development files for using DevIL
    ode: Open Dynamics Engine, A physics engine
    ode-devel: Development files to use for developing applications to use ode

    If you have a ready internet connection, you can have it done like this with yum:

         $ sudo yum -y install boost boost-devel freetype freetype-devel freeglut freeglut-devel ruby ruby-devel SDL* DevIL DevIL-devel ode ode-devel
    

    Otherwise, the best option is to download the packages from one of Fedora mirrors. This link points to the list of all Fedora mirrors, Pick one of the mirrors, and search and download the packages listed above, then install it.
    If there was error installing them, check these two: 1) Are you root? or at least doing it with sudo? 2) Does the package need any other dependency? you can guess it by rpm output

    • I forgot to say to newbies: installation is like this: If you are in graphic mode (X Window System), find the package on installation media, double click it, otherwise, login to a terminal, go to installation media's directory, and type rpm -ivh <filename>


  3. Now its the time for simulator itself:
  4. Get the latest simspark package (take a look at downloading page if you don't know where to get it) and extract it. There are 4 folders, which currently they need to be built seperately. The building process is described below, it is the same for all the packages. First you should open a terminal and change to spark folder, and execute these commands:

     $ mkdir build
     $ cd build
     $ cmake ..
     $ make
     $ sudo make install
    


    Then change folder to rcssserver3d, execute the commands. Next is the simspark-utilitis, and last is optional, rsgedit.

    • Note for newbies: DO NOT TYPE THE $ SIGN! It is indicator of shell prompt.


Congratulations, your build is complete!

Ubuntu

I. Easiest way to install simspark and rcssserver3d is using the ubuntu robocup repository. You can simply install the server using following instructinos:

     [ You should enable the Universe and Multiverse repositories before! ]
     $ sudo apt-add-repository ppa:gnurubuntu/rubuntu
     $ sudo apt-get update
     $ sudo apt-get install rcssserver3d

rcssserver3d-dev and simspark-dev are also available at the repository. If the new version of simspark & server has been released, you can upgrade them by:

     $ sudo apt-get update && sudo apt-get install rcssserver3d

II. Another way is to get the sources of the server and compile them. This small HowTo explains how to install the Robocup 3D simspark simulation server on Ubuntu (so not the old spheres server using spades). This work Hardy Heron (8.04) and Intrepid Ibex (8.10). The steps should be similar on other debian based distributions especially Debian itself, so hopefully it's also useful for other people.

Requirement

  1. Enable Universe and Multiverse repositories:
  2.      $ sudo gedit /etc/apt/sources.list
         [ Follow instructions in the file to enable the Universe and Multiverse repositories, save and exit ]
         $ sudo apt-get update
    

  3. Install dependencies:
  4.      $ sudo apt-get install g++ subversion cmake libfreetype6-dev libode-dev libsdl-dev ruby ruby-dev libdevil-dev libboost-dev libboost-thread-dev libboost-regex-dev libboost-system-dev
    

  5. Download the latest simspark and rcssserver3d packages as described here, or if you want to use latest code in SVN repository, check out the source from the source forge SVN repository:
  6.      $ svn co https://simspark.svn.sourceforge.net/svnroot/simspark simspark
    

  7. Configure the package, generate build files and install the package:
  8. Simspark:

         $ cd simspark/trunk/spark
         $ mkdir build
         $ cd build
         $ cmake ..
         $ make
         $ sudo make install
         $ sudo ldconfig
    
    • Note: type 'make uninstall' to uninstall the package

    Rcssserver3D:

         [ set to the rcssserver3d directory (trunk/rcssserver3d) ]
         $ mkdir build
         $ cd build
         $ cmake ..
         $ make
         $ sudo make install
         $ sudo ldconfig
    
    • Note: type 'make uninstall' to uninstall the package

  9. Make sure the linker can find your shared libraries:
  10.      $ sudo gedit /etc/ld.so.conf
         [ add the line '/usr/local/lib' if it isn't already there, save and close ]
         $ sudo ldconfig
    

  11. Run the simulation:
  12.      $ simspark
    

  13. Run test agent:
  14.      $ rcssagent3d
    

Optional

Documentations

  1. Install dependencies:
  2.      $ sudo apt-get install tetex-extra latex2html imagemagick
         [ for developers manual ]
         $ sudo apt-get install doxygen
         [ for API documentations ]
    

  3. Create documentations:
  4.      [ in build directories of spark and rcssserver3d type ]
         $ make pdf
         $ make doc
         [ to create user (user-manual.pdf) and developer (devel.pdf) manual and API documentations ]
    

Rsgedit

  1. Install dependencies:
  2.      $ sudo apt-get install libwxgtk2.8-dev
    

  3. Configure the package, generate build files and install the package:
  4.      [ set to the rsgedit direcditory (trunk/rsgedit) ]
         $ mkdir build
         $ cd build
         $ cmake ..
         $ make
         $ sudo make install
    

  5. Run rsgedit:
  6.      $ rsgedit
    

Simspark-utilities

  1. Configure the package, generate build files and install the package:
  2.      [ set to the simspark-utilities directory (trunk/simspark-utilities) ]
         $ mkdir build
         $ cd build
         $ cmake ..
         $ make
         $ sudo make install
    

  3. Run utilities:
  4.      $ gendot
         $ monitorspark
         $ sampleagent
         $ samplesim
    

Arch Linux

  • Install yaourt to use aur. See Archlinux wiki for details
  • Install server with the following command and follow instructions
     $ yaourt -S rcssserver3d

Generic Linux Instructions

Installing Ruby

Download Ruby version 1.8.0 or newer (tested and working with versions 1.8.6 and 1.9) and then configure with parameter --enable-shared.

Installing Boost

Download latest Boost version and install it. You should at least build these libraries: regex, thread and date_time

Installing ODE

Download and install any of the working versions.(0.11 or higher). For better stability, configure with option --enable-double-precision. For 64-bit system, configure with CFLAGS and CXXFLAGS set to "-g -O2 -fPIC".

Other dependencies

These libraries are also needed. They are usually available in your distribution's repositories:

FreeType, SDL, DevIL,

Installing Simspark and Rcssserver3d

Get the latest simspark package (take a look at downloading page if you don't know where to get it) and extract it. There are 4 packages which should be built separately. simspark and rcssserver3d packages are required, others are optionsl. The building process is described below, it is the same for all the packages. First you should open a terminal and change to simspark folder, and execute these commands:

 $ mkdir build
 $ cd build
 $ cmake ..
 $ make
 $ sudo make install


Then change folder to rcssserver3d, execute the commands. If you want to build optional packages, you can then build simspark-utilitis and rsgedit using similar instructions.

  • Note for newbies: DO NOT TYPE THE $ SIGN! It is indicator of shell prompt.


Congratulations, your build is complete!

Running the simulation

For running rcssserver3d, the easiest way is to run rcsoccersim3d:

$ rcsoccersim3d

Click on the Kerosin window that appears and drag the mouse on the window to change your view of field.

To run a sample agent, you can run:

$ rcssagent3d

You should see a humanoid agent in the field.

Personal tools