Skip to content

Commit

Permalink
Add more messages and services
Browse files Browse the repository at this point in the history
  • Loading branch information
Victor Lopez committed Sep 18, 2020
1 parent 91e1767 commit bef08e2
Show file tree
Hide file tree
Showing 7 changed files with 56 additions and 0 deletions.
9 changes: 9 additions & 0 deletions controller_manager_msgs/CMakeLists.txt
Expand Up @@ -14,8 +14,16 @@ find_package(ament_cmake REQUIRED)
find_package(builtin_interfaces REQUIRED)
find_package(rosidl_default_generators REQUIRED)

set(msg_files
msg/ControllerState.msg
)
set(srv_files
srv/ListControllers.srv
srv/ListControllerTypes.srv
srv/LoadController.srv
srv/ReloadControllerLibraries.srv
srv/SwitchController.srv
srv/UnloadController.srv
)

if(BUILD_TESTING)
Expand All @@ -24,6 +32,7 @@ if(BUILD_TESTING)
endif()

rosidl_generate_interfaces(${PROJECT_NAME}
${msg_files}
${srv_files}
DEPENDENCIES builtin_interfaces
ADD_LINTER_TESTS
Expand Down
5 changes: 5 additions & 0 deletions controller_manager_msgs/msg/ControllerState.msg
@@ -0,0 +1,5 @@
string name
string state
string type
# To be implemented
# controller_manager_msgs/HardwareInterfaceResources[] claimed_resources
6 changes: 6 additions & 0 deletions controller_manager_msgs/srv/ListControllerTypes.srv
@@ -0,0 +1,6 @@
# The ListControllers service returns a list of controller types that are known
# to the controller manager plugin mechanism.

---
string[] types
string[] base_classes
5 changes: 5 additions & 0 deletions controller_manager_msgs/srv/ListControllers.srv
@@ -0,0 +1,5 @@
# The ListControllers service returns a list of controller names/states/types of the
# controllers that are loaded inside the controller_manager.

---
ControllerState[] controller
10 changes: 10 additions & 0 deletions controller_manager_msgs/srv/LoadController.srv
@@ -0,0 +1,10 @@
# The LoadController service allows you to load a single controller
# inside controller_manager

# To load a controller, specify the "name" of the controller.
# The return value "ok" indicates if the controller was successfully
# constructed and initialized or not.

string name
---
bool ok
11 changes: 11 additions & 0 deletions controller_manager_msgs/srv/ReloadControllerLibraries.srv
@@ -0,0 +1,11 @@
# The ReloadControllerLibraries service will reload all controllers that are available in
# the system as plugins


# Reloading libraries only works if there are no controllers loaded. If there
# are still some controllers loaded, the reloading will fail.
# If this bool is set to true, all loaded controllers will get
# killed automatically, and the reloading can succeed.
bool force_kill
---
bool ok
10 changes: 10 additions & 0 deletions controller_manager_msgs/srv/UnloadController.srv
@@ -0,0 +1,10 @@
# The UnloadController service allows you to unload a single controller
# from controller_manager

# To unload a controller, specify the "name" of the controller.
# The return value "ok" indicates if the controller was successfully
# unloaded or not

string name
---
bool ok

0 comments on commit bef08e2

Please sign in to comment.