Skip to content

Commit

Permalink
Cleanup package.xml und clarify tests of JTC. (#889)
Browse files Browse the repository at this point in the history
* Cleanup package.xml und clarify tests of JTC.

* Update joint_trajectory_controller/package.xml

Co-authored-by: Bence Magyar <[email protected]>

---------

Co-authored-by: Bence Magyar <[email protected]>
(cherry picked from commit 1d0d753)

# Conflicts:
#	joint_trajectory_controller/package.xml
  • Loading branch information
destogl authored and mergify[bot] committed Dec 12, 2023
1 parent af241b1 commit dd13bc4
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
20 changes: 10 additions & 10 deletions joint_trajectory_controller/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,28 @@
<version>2.29.0</version>
<description>Controller for executing joint-space trajectories on a group of joints</description>
<maintainer email="[email protected]">Bence Magyar</maintainer>
<maintainer email="[email protected]">Jordan Palacios</maintainer>
<maintainer email="[email protected]">Karsten Knese</maintainer>
<maintainer email="[email protected]">Dr. Denis Štogl</maintainer>
<maintainer email="[email protected]">Christoph Froehlich</maintainer>

<license>Apache License 2.0</license>

<buildtool_depend>ament_cmake</buildtool_depend>

<build_depend>angles</build_depend>
<build_depend>pluginlib</build_depend>
<build_depend>realtime_tools</build_depend>

<exec_depend>angles</exec_depend>
<exec_depend>pluginlib</exec_depend>
<exec_depend>realtime_tools</exec_depend>

<depend>angles</depend>
<depend>backward_ros</depend>
<depend>controller_interface</depend>
<depend>control_msgs</depend>
<depend>control_toolbox</depend>
<depend>hardware_interface</depend>
<depend>pluginlib</depend>
<depend>rclcpp</depend>
<depend>rclcpp_lifecycle</depend>
<<<<<<< HEAD
=======
<depend>realtime_tools</depend>
<depend>rsl</depend>
<depend>tl_expected</depend>
>>>>>>> 1d0d753 (Cleanup package.xml und clarify tests of JTC. (#889))
<depend>trajectory_msgs</depend>
<depend>generate_parameter_library</depend>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -215,21 +215,21 @@ class TrajectoryControllerTest : public ::testing::Test
}

void SetPidParameters(
double p_default = 0.0, double ff_default = 1.0, bool angle_wraparound_default = false)
double p_value = 0.0, double ff_value = 1.0, bool angle_wraparound_value = false)
{
traj_controller_->trigger_declare_parameters();
auto node = traj_controller_->get_node();

for (size_t i = 0; i < joint_names_.size(); ++i)
{
const std::string prefix = "gains." + joint_names_[i];
const rclcpp::Parameter k_p(prefix + ".p", p_default);
const rclcpp::Parameter k_p(prefix + ".p", p_value);
const rclcpp::Parameter k_i(prefix + ".i", 0.0);
const rclcpp::Parameter k_d(prefix + ".d", 0.0);
const rclcpp::Parameter i_clamp(prefix + ".i_clamp", 0.0);
const rclcpp::Parameter ff_velocity_scale(prefix + ".ff_velocity_scale", ff_default);
const rclcpp::Parameter ff_velocity_scale(prefix + ".ff_velocity_scale", ff_value);
const rclcpp::Parameter angle_wraparound(
prefix + ".angle_wraparound", angle_wraparound_default);
prefix + ".angle_wraparound", angle_wraparound_value);
node->set_parameters({k_p, k_i, k_d, i_clamp, ff_velocity_scale, angle_wraparound});
}
}
Expand Down

0 comments on commit dd13bc4

Please sign in to comment.