Skip to content

Commit 7d56442

Browse files
authored
fixing structure
1 parent 26a130b commit 7d56442

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

doc/writing_new_controller.rst

+5-2
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@ The following is a step-by-step guide to create source files, basic tests, and c
3434
3. Define a unique namespace for your controller. This is usually a package name written in ``snake_case``.
3535

3636
4. Define the class of the controller, extending ``ControllerInterface``, e.g.,
37+
3738
.. code:: c++
38-
class ControllerName : public controller_interface::ControllerInterface
39+
40+
class ControllerName : public controller_interface::ControllerInterface
3941

4042
5. Add a constructor without parameters and the following public methods overriding the ``ControllerInterface`` definition: ``init``, ``command_interface_configuration``, ``state_interface_configuration``, ``on_configure``, ``on_activate``, ``on_deactivate``, ``update``.
4143
For exact definitions check the ``controller_interface/controller_interface.hpp`` header or one of the controllers from `ros2_controllers <https://github.com/ros-controls/ros2_controllers>`_.
@@ -105,8 +107,9 @@ The following is a step-by-step guide to create source files, basic tests, and c
105107
4. Add ament dependencies needed by the library. You should add at least those listed under 1.
106108

107109
5. Export for pluginlib description file using the following command:
108-
.. code:: cmake
109110

111+
.. code:: cmake
112+
110113
pluginlib_export_plugin_description_file(controller_interface <controller_name>.xml)
111114
112115
6. Add install directives for targets and include directory.

0 commit comments

Comments
 (0)