Skip to content

Commit d0d5fe6

Browse files
committed
updating installation tutorial
1 parent 5ad6f61 commit d0d5fe6

File tree

2 files changed

+88
-43
lines changed

2 files changed

+88
-43
lines changed

ct_doc/doc/DoxygenLayout.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@
44
<!-- >test <-->
55
<navindex>
66
<tab type="mainpage" visible="yes" title="Home"/>
7-
<tab type="user" url="../../../ct_core/doc/html/index.html" title="Core module"/>
8-
<tab type="user" url="../../../ct_optcon/doc/html/index.html" title="Optimal Control"/>
9-
<tab type="user" url="../../../ct_rbd/doc/html/index.html" title="Robot Module"/>
10-
<tab type="user" url="../../../ct_models/doc/html/index.html" title="Models"/>
117
<tab type="pages" visible="yes" title="" intro=""/>
128
<tab type="modules" visible="no" title="Modules" intro=""/>
139
<tab type="namespaces" visible="yes" title="">
@@ -24,7 +20,11 @@
2420
<tab type="filelist" visible="yes" title="" intro=""/>
2521
<tab type="globals" visible="yes" title="" intro=""/>
2622
</tab>
27-
<tab type="examples" visible="yes" title="" intro=""/>
23+
<tab type="examples" visible="yes" title="" intro=""/>
24+
<!--tab type="user" url="../../../ct_core/doc/html/index.html" title="Core module"/-->
25+
<!--tab type="user" url="../../../ct_optcon/doc/html/index.html" title="Optimal Control"/-->
26+
<!--tab type="user" url="../../../ct_rbd/doc/html/index.html" title="Robot Module"/-->
27+
<!--tab type="user" url="../../../ct_models/doc/html/index.html" title="Models"/-->
2828
</navindex>
2929

3030
<!-- Layout definition for a class page -->

ct_doc/doc/installation.dox

Lines changed: 83 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,17 @@
11
/*!
22

33
\page install_guide Installation
4+
45
@tableofcontents
56

67
\section req Requirements:
78

9+
\subsection req-system System Requirements
810
- Ubuntu 16.04 or 18.04
911
- a compiler with C++14 support, e.g. gcc or clang
1012

1113

12-
\section dep Get Required Dependencies
14+
\subsection req-dependencies Required Dependencies
1315
- install <a href="http://eigen.tuxfamily.org/index.php?title=Main_Page">Eigen 3</a> via
1416
\code{.sh}
1517
sudo apt-get update
@@ -31,28 +33,87 @@
3133
\endcode
3234

3335
\section build Building the CT
34-
- VARIANT A, if you are a ROS-user: build the CT using catkin tools
35-
\code{.sh}
36-
cd ~/your_workspace
37-
catkin build -DCMAKE_BUILD_TYPE=Release -DBUILD_EXAMPLES=true
38-
\endcode
39-
- Now, try to run the examples, e.g. the optimal control and optimal filtering examples:
40-
\code{.sh}
41-
cd ~/catkin_ws/src
42-
catkin build -DCMAKE_BUILD_TYPE=Release -DBUILD_EXAMPLES=true
43-
rosrun ct_optcon ex_NLOC
44-
rosrun ct_optcon ex_KalmanFiltering
45-
\endcode
46-
- VARIANT B, if you prefer plain cmake.
47-
First, make sure you build and install the kindr-library, see <a href="https://github.com/ANYbotics/kindr#building">kindr</a> here.
48-
Then go to the CT and run the build script:
49-
\code{.sh}
50-
cd ../control-toolbox/ct
51-
chmod 775 build_ct.sh
52-
./build_ct.sh -DCMAKE_BUILD_TYPE=Release -DBUILD_EXAMPLES=true
53-
\endcode
54-
- This creates a /build subdirectory in every single CT-project, where the examples will be located.
36+
\subsection build-ros For ROS or catkin users
37+
\subsubsection build-ros-main Compiling the Library
38+
It is assumed that you have a valid catkin-workspace set up, e.g. using <a href="https://catkin-tools.readthedocs.io/en/latest/">catkin tools</a>.
39+
Then, execute the following steps.
40+
\code{.sh}
41+
cd ~/your_workspace
42+
catkin build -DCMAKE_BUILD_TYPE=Release
43+
\endcode
44+
45+
\subsubsection build-ros-examples Building and running examples
46+
To build an run the examples, e.g. the optimal control and optimal filtering examples:
47+
\code{.sh}
48+
cd ~/your_workspace
49+
catkin build -DCMAKE_BUILD_TYPE=Release -DBUILD_EXAMPLES=true
50+
source devel/setup.bash
51+
rosrun ct_optcon ex_NLOC
52+
rosrun ct_optcon ex_KalmanFiltering
53+
\endcode
54+
55+
\subsubsection build-ros-tests Building and running the unit tests
56+
To build an run the unit tests:
57+
\code{.sh}
58+
cd ~/your_workspace
59+
catkin build -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=true
60+
catkin run_tests
61+
\endcode
62+
63+
\subsubsection build-ros-doc Building the documentation
64+
To build the documentation execute
65+
\code{.sh}
66+
catkin build ct_doc -v --make-args doc
67+
\endcode
68+
This will build the documentation. The index.html can be found in ct_doc/doc/html
69+
70+
71+
72+
\subsection build-cmake Using plain cmake.
73+
\subsubsection build-cmake-main Compiling the Library
74+
First, make sure you build and install the kindr-library, see <a href="https://github.com/ANYbotics/kindr#building">here</a>.
75+
Then go to your local clone of the control toolbox and run the build script:
76+
\code{.sh}
77+
cd your_workspace/control-toolbox/ct
78+
chmod 775 build_ct.sh
79+
./build_ct.sh -DCMAKE_BUILD_TYPE=Release
80+
\endcode
81+
82+
\subsubsection build-cmake-examples Building and running examples
83+
Then go to your local clone of the control toolbox and run the build script with the following flags.
84+
\code{.sh}
85+
cd your_workspace/control-toolbox/ct
86+
./build_ct.sh -DCMAKE_BUILD_TYPE=Release -DBUILD_EXAMPLES=true
87+
\endcode
88+
This creates a /build subdirectory in every single CT-project, where the examples will be located.
89+
For running the nonlinear optimal control or filtering examples, for instance, go to your workspace an run
90+
\code{.sh}
91+
./src/control-toolbox/ct_optcon/build/examples/ex_NLOC
92+
./src/control-toolbox/ct_optcon/build/examples/ex_KalmanFiltering
93+
\endcode
5594

95+
\subsubsection build-cmake-tests Building and running the unit tests
96+
To build an run the unit tests:
97+
\code{.sh}
98+
cd your_workspace/control-toolbox/ct
99+
./build_ct.sh -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=true
100+
\endcode
101+
102+
\subsubsection build-cmake-doc Building the documentation
103+
\code{.sh}
104+
cd your_workspace/control-toolbox/ct
105+
chmod 775 build_doc.sh
106+
./build_doc.sh
107+
\endcode
108+
The index.html can be found in ct_doc/doc/html
109+
110+
\subsubsection build-cmake-cleanup Clean up
111+
In order to clean up the build workspaces, run the clean script
112+
\code{.sh}
113+
cd your_workspace/control-toolbox/ct
114+
chmod 775 clean_ct.sh
115+
./clean_ct.sh
116+
\endcode
56117

57118

58119
\section opt_dep Optional Dependencies and Bindings
@@ -110,20 +171,4 @@ Build Flag | Default value | Description
110171
-DHPIPM=\<BOOL> | FALSE | Compile with HPIPM support (set $BLASFEO_DIR and $HPIPM_DIR environment variables)
111172

112173

113-
114-
\section build_doc Build this Documentation
115-
To build the documentation do
116-
\code{.sh}
117-
catkin build ct_doc -v --make-args doc # build the doc
118-
\endcode
119-
This will build the documentation. The index.html can be found in ct_doc.
120-
121-
122-
\section run_tests Run Unit Tests
123-
The unit tests are writte as <a href="http://code.google.com/p/googletest/">Google Tests</a>.
124-
To run unit tests and verify operation execute
125-
\code{.sh}
126-
catkin run_tests
127-
\endcode
128-
129174
*/

0 commit comments

Comments
 (0)