An organization maintained by RoboLab (Universidad de Extremadura), Aston University, ISIS (Universidad de Málaga) and many other collaborators from the Google Summer of Code program.
RoboComp is an open-source Robotics framework providing the tools to create and modify software components that communicate through public interfaces. Components may require, subscribe, implement or publish interfaces in a seamless way. Building new components is done using two domain-specific languages, IDSL and CDSL. With IDSL you define an interface and with CDSL you specify how the component will communicate with the world. With this information, a code generator creates C++ and/or Python sources, based on CMake, that compile and execute flawlessly. When some of these features have to be changed, the component can be easily regenerated and all the user-specific code is preserved thanks to a simple inheritance mechanism.
If you already have RoboComp installed, jump to tutorials to start coding!
❓ If you have a question please look for it in the FAQ.
- Installation from source
- Testing the installation using the RCIS robotics simulator
- Testing the installation using the Coppelia Simulator
- Next steps
- Known issues
Table of contents generated with markdown-toc
We recommend installing:
- Yakuake for terminal management
- Qt Designer or Qt Creator for designing Qt interfaces
sudo apt install yakuake qt6-tools-devTested in Ubuntu 20.04, 22.04 and 24.04, with Python3.10 and Python3.12
Note: RoboComp is not compatible with Ubuntu 16.04. RoboComp needs to be compiled using C++11. Ice libraries with C++11 support are only available for zeroc-ice 3.7 and the packages for this version are only available since Ubuntu 18.04.
Note: RoboComp is not compatible with Ubuntu 18.04. RoboComp needs to be compiled using cmake >= 3.16. It's not available in Ubuntu 18.04.
Note: If you have installed Anaconda in your system. Then you need to change the python from anaconda to default.
Warning
If you are using Ubuntu 24.04, you may need a Python virtual environment. It can be created with:
sudo apt install python3-venv
mkdir ~/software 2> /dev/null; cd ~/software && python3 -m venv pip_venv
echo "PATH="$HOME/software/pip_venv/bin:\$PATH"" >> ~/.bashrcYou can install RoboComp using the script robocomp_install.sh.
It allows you to change the RoboComp installation path and also install Cortex.
wget https://raw.githubusercontent.com/robocomp/robocomp/development/robocomp_install.sh && bash robocomp_install.shBefore you begin the installation, make sure you have the following prerequisites installed on your system:
sudo apt update
sudo apt install python3 python3-pip cmake vim git wget libopenscenegraph-dev libgsl-dev qt6-base-dev qt6-declarative-dev qt6-scxml-dev libqt6statemachineqml6 libqt6statemachine6 libbz2-dev libssl-dev zeroc-icebox zeroc-ice-all-dev libzeroc-icestorm3.7 libeigen3-dev meld
pip install vcstool PySide6 zeroc-ice
# Install libQGLViewer
mkdir ~/software 2> /dev/null; git clone https://github.com/GillesDebunne/libQGLViewer.git ~/software/libQGLViewer
cd ~/software/libQGLViewer && qmake6 *.pro && make -j12 && sudo make install && sudo ldconfig && cd -
# Install tomlplusplus
git clone https://github.com/marzer/tomlplusplus.git ~/software/tomlplusplus
cd ~/software/tomlplusplus && cmake -B build && sudo make install -C build -j12 && cd -- Download the Robocomp.repos file:
wget https://raw.githubusercontent.com/robocomp/robocomp/development/robocomp.repos- Configure environment variables, you can change the Robocomp path here:
echo "export ROBOCOMP=$HOME/robocomp" >> ~/.bashrc #Change HERE if you prefer another installation path.
echo "export PATH=\$PATH:$HOME/.local/bin" >> ~/.bashrc
source ~/.bashrc- Import RoboComp packages:
vcs import $ROBOCOMP < robocomp.repos --recursive
cd $ROBOCOMP
ln -s core/cmake cmake
ln -s core/classes classes
mkdir components- Install RoboComp command-line tools:
pushd . && cd $ROBOCOMP/tools/cli/ && pip install . && popdsudo ln -s /usr/include/eigen3/Eigen/ /usr/include/Eigen- Add an alias for rcnode and clean compile to your .bashrc:
echo "alias rcnode='bash $ROBOCOMP/tools/rcnode/rcnode.sh&'" >> ~/.bashrc
echo "alias cbuild='cmake -B build && make -C build -j$(nproc)'" >> ~/.bashrc
source ~/.bashrcIf you are going to develop with Robocomp it's recommendable to install the following packages too:
sudo apt-get install yakuake
git clone https://github.com/ryanhaining/cppitertools ~/software/cppitertools
cd ~/software/cppitertools && cmake -B build && sudo make install -C build -j$JOBS && cd -Done! Now let's have some fun.
To test RoboComp with Coppelia you need to:
- Install Coppelia Robotics and Pyrep. There are detailed instructions here
- Run the bridge, i.e. omniPyrep.py and see that Coppelia starts Ok.
- Connect your new component to the ports offered in omniPyrep.py or
- Connect a joystick or XBox pad to omniRep.py using this component
The software of the robots using RoboComp is composed of different components working together, communicating among them. What we just installed is just the core of RoboComp (the simulator, a component generator, and some libraries). To have other features like joystick control we have to run additional software components available from other repositories, for example, robocomp-robolab:
cd ~/robocomp/components
git clone https://github.com/robocomp/robocomp-robolab.git
The RoboLab's set of basic robotics components are now downloaded. You can see them in ~/robocomp/components/robocomp-robolab/components
If you have a joystick around, connect it to the USB port and:
cd ~/robocomp/components/robocomp-robolab/components/hardware/external_control/joystickComp
cmake .
make
cd bin
sudo addgroup your-user dialout // If you find permissions issues in Ubuntu
check the config file in the component's etc folder and make sure that the port matches the DifferentialRobot endpoint in RCIS.
bin/joystick etc/config
Your joystick should be now running. It will make the robot advance and turn at your will. If it does not work,
check where the joystick device file has been created (e.g., /dev/input/js0). If it is not /dev/input/js0, edit ~/robocomp/components/robocomp-robolab/components/hardware/external_control/joystickComp/etc/config change it accordingly and restart. Note that you might want to save the config file to the component's home directory so it does not interfere with future GitHub updates.
If you don't have a JoyStick install this component,
cd ~/robocomp/components/robocomp-robolab/components/hardware/external_control/keyboardrobotcontroller
cmake .
make
src/keyboardrobotcontroller.py etc/config
and use the arrow keys to navigate the robot, the space bar to stop it and 'q' to exit.
Note 1: You must have your simulator running in a terminal and only then you can run a component in another terminal. You will get an error message if you run the above component without having RCIS already running.
Note 2: If you have anaconda installed (for python 3), It is recommended to uninstall anaconda first and then install robocomp. (It is only applicable if you have faced errors while running above commands.)
We are now moving to more advanced robotics simulators that can reduce the gap between simulation and deployment. Our first choice now is Webots. To install it follow the instructions in their page. To use if from RoboComp components you can clone the repository into ~/robocomp/ and build it (cmake and make). Go through its Webots2Robocomp.cdsl file to see all the interfaces it offers. Go through the etc/config files to check the ports where they are offer webots-bridge ed. There is another repository with some worlds (.wbt files) that you can load into Webots with our robot Shadow, webots-shadow Clone it in ~/robocomp and load one of the available worlds.
Start webots_bridge to activate the Webots interface and try to connect your new component to the Shadow robot and its 360º camera and 3D Lidar.
You can find more tutorials on RoboComp in tutorials
Drop comments and ask questions in:
Please, report any bugs with the github issue system: Robocomp Issues
If you have any suggestions to improve the repository, like features or tutorials, please contact us on or create a feature request here.
- Compatibility problem between pyparsing version and Robocomp tools:
- One of the main tools of Robocomp, robocompdsl is using pyparsing and the current code doesn't work with 2.4 version of this library. With the previous commands, we are installing the 2.2 version (python-pyparsing=2.2.0+dfsg1-2). If you have a more recent version of pyparsing installed with apt or pip we recommend you to uninstall it and install the 2.2 version. You can check your current version of pyparsing with this command:
python3 -c "import pyparsing; print(pyparsing.__version__)"- Ubuntu 18.04 and CMake > 3.16
- Robocomp is currently using the syntax for cmake 3.16. It's the default version in Ubuntu 20.04, but it's not available in Ubuntu 18.04.