Skip to content

Commit

Permalink
Working Chaining Controller #1
Browse files Browse the repository at this point in the history
  • Loading branch information
Blebot0 committed Jun 8, 2023
1 parent 4a70aa0 commit 7e6b567
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion chaining_controller/launch/cart_example_effort.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def generate_launch_description():
"control",
"load_controller",
"--set-state",
"active",
"inactive",
"chained_controller",
],
output="screen",
Expand Down
2 changes: 2 additions & 0 deletions chaining_controller/src/chained_controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ chaining_controller::ChainedController::on_export_reference_interfaces()

bool chaining_controller::ChainedController::on_set_chained_mode(bool chained_mode)
{
RCLCPP_INFO(get_node()->get_logger(), "CHAINED MODE ACTIVE");

chained_mode = true;
return chained_mode;
}
Expand Down
4 changes: 3 additions & 1 deletion chaining_controller/src/effort_controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,10 @@ chaining_controller::EffortController::command_interface_configuration() const
get_node()->get_logger(), "Command Interface EffortController. No Command Interface Required");

controller_interface::InterfaceConfiguration command_interfaces_config;
command_interfaces_config.type = controller_interface::interface_configuration_type::NONE;
command_interfaces_config.type = controller_interface::interface_configuration_type::INDIVIDUAL;

command_interfaces_config.names.push_back(
std::string("chained_controller/") + hardware_interface::HW_IF_EFFORT);
return command_interfaces_config;
}

Expand Down

0 comments on commit 7e6b567

Please sign in to comment.