This is an old revision of the document!
Installation and Setup
Prerequisites
We use Ubuntu 14.04 LTS or 16.04 LTS on the host machine. Other distributions are supported but not documented here. Further, you have to patch the kernel with a realtime patch as described in https://rt.wiki.kernel.org/index.php/Main_Page. It is possible to work without the realtime patch. However, the latency of the system will be much worse and will depend greatly on the load of other programs running on the system.
To use EEROS on the host machine the following packages have to be installed:
$ apt-get install git make cmake g++
Please make sure to use a g++ version of at least 4.8.
If you are not only doing simulations you will have to install further software in order to communicate with your underlying hardware. This could be libraries supporting EtherCAT, CANOpen, comedi or flink. In addition to one of this libraries you need the appropriate eeros wrapper library.
Getting the Sources with a Script
Setting up the correct way of compiling EEROS can be quite cumbersome. We strongly recommend to use our scripts. How to setup these scripts depends on your platform. What to you want to do with EEROS?
- Run examples, use with the simulator → see Use on the Host
- Run on the host together with ROS → see use_with_ros
- Run on the host with comedi → see Use with Comedi
- Use it on the BeagleBone blue board → see Use on a Beaglebone Blue Board
- Use it on the cb20 board with flink → see https://wiki.ntb.ch/infoportal/embedded_systems/imx6/cb
- Use it with EtherCAT on x86 platform → see https://wiki.ntb.ch/infoportal/embedded_systems/ethercat/start
Getting the Scripts
Create a new and empty directory and download the scripts from
$ git clone https://github.com/eeros-project/eeros-build-scripts.git
- Copy all files from the cloned directory into your working directory. This is the place where you want to have all necessary repositories together with your appplication.
- Edit the
config.sh.in
file. Choose an appropriate toolchain file. The toolchain file basically determines which compiler you are going to use. If you work on the host and want to use the standard compiler you can omit this toolchain file. See arm_toolchain for an example of a toolchain file. - Choose a meaningful name for the build and install directory.
- Comment or uncomment the necessary hardware libraries. The script will fetch those left uncommented.
- Change the name of your application directory so that it fits your application. Per default a simple motor control will be downloaded. If you don't want to download this, please comment these two lines out. If you have another application in a repository, change the name accordingly.
Now you can run the clone
script
$ ./clone.sh
After this you can continue with Compile.
Getting the Sources Manually
Clone the eeros source repository:
$ git clone https://github.com/eeros-project/eeros-framework.git
Checkout a stable version of EEROS:
$ cd eeros-framework $ git checkout v0.5
In addition to the eeros library you need to install libraries for hardware access together with the appropriate eeros wrapper libraries, see Installing Hardware Libraries.