Getting Started:

Documentation

https://ethz-adrl.github.io/ct/ct_doc/doc/html/getting_started.html

Installation:

OS: Ubuntu 20.04, Ubuntu 18.04.

This tutorial assumes that you have installed catkin and ROS melodic or noetic.

Reference:

Quickstart · ethz-adrl/control-toolbox Wiki

Step1 :

#install dependencies
sudo apt-get update
sudo apt-get install libeigen3-dev
sudo apt-get install libboost-all-dev
sudo apt-get install doxygen
#create workspace
source /opt/ros/melodic/setup.bash
mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/
catkin build
#If you get "catkin: command not found" then use this
# sudo apt-get install python3-catkin-tools 

#Clone repos
cd ~/your_workspace/src
git clone <https://github.com/ANYbotics/kindr.git>
git clone <https://github.com/ethz-adrl/control-toolbox.git>

Step2 : In the “/home/<username>/<workspace>/src/control-toolbox/ct_models/CMakeLists.txt” add these lines in it.

list(APPEND CMAKE_PREFIX_PATH "/opt")
find_package(blasfeo QUIET)
find_package(hpipm QUIET)

Step3 : Install Other dependencies

cd /home/<username>/<workspace>/src/control-toolbox/ct

## In all the below files, add sudo before all the rm commands and also whereever it is failing.
./install_cmake.sh
./install_cppadcg.sh
./install_deps.sh
./install_hpipm.sh

#sometimes installing the above command will remove some packages in ros so re install it.
sudo apt install ros-noetic-desktop-full

Step4 : Build the workspace. Go to workspace folder and then do

catkin build -DCMAKE_BUILD_TYPE=Release

Refer to the reference section given above for running examples and documentation

These issues might occur:

  1. NO blasfeo or hpipm

    https://blog.csdn.net/weixin_37532614/article/details/109051291

  2. No executable found with ex_NLOC or ex_kalmannfilter

    Open /home/haasith/ct_ws/src/control-toolbox/ct_optcon/examples/CMakeLists.txt and uncomment the lines related to ex_NLOC and etc.

  3. Matplotlib issue

    pip install matplotlib

    Try installing matplotlib, that might solve the issue.

  4. qmake: could not find a Qt installation of '’

    sudo apt-get install qt5-default

  5. Could NOT find GTest

    sudo apt-get install libgtest-dev