Skip to content

Commit

Permalink
Merge branch 'master' into add-pid-controller
Browse files Browse the repository at this point in the history
  • Loading branch information
destogl authored May 4, 2023
2 parents 12cd6b6 + 6793e02 commit 0850668
Show file tree
Hide file tree
Showing 61 changed files with 525 additions and 182 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,3 @@

---
name: Pull request
about: Create a pull request
title: ''
labels: ''
assignees: ''

---

Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:

1. Limited scope. Your PR should do one thing or one set of things. Avoid adding “random fixes” to PRs. Put those on separate PRs.
Expand Down
10 changes: 7 additions & 3 deletions .github/reviewer-lottery.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,16 @@ groups:
- rosterloh
- progtologist
- arne48
- christophfroehlich
- DasRoteSkelett
- Serafadam
- sgmurray
- harderthan
- jaron-l
- malapatiravi
- homalozoa
- erickisos
- sachinkum0009
- qiayuanliao
- homalozoa
- anfemosa
- jackcenter
- VX792
Expand All @@ -31,6 +34,7 @@ groups:
- aprotyas
- peterdavidfagan
- duringhof
- VanshGehlot
- bijoua29
- lm2292
- LukasMacha97
- mcbed
2 changes: 1 addition & 1 deletion .github/workflows/ci-coverage-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
}
}
colcon-mixin-repository: https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml
- uses: codecov/[email protected].2
- uses: codecov/[email protected].3
with:
file: ros_ws/lcov/total_coverage.info
flags: unittests
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci-format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4.5.0
- uses: actions/setup-python@v4.6.0
with:
python-version: '3.10'
- name: Install system hooks
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci-ros-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ jobs:
linter: [cpplint]
steps:
- uses: actions/checkout@v3
- uses: ros-tooling/setup-ros@0.6.1
- uses: ros-tooling/action-ros-lint@v0.1
- uses: ros-tooling/setup-ros@master
- uses: ros-tooling/action-ros-lint@master
with:
distribution: rolling
linter: cpplint
Expand Down
9 changes: 9 additions & 0 deletions admittance_controller/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@
Changelog for package admittance_controller
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

3.7.0 (2023-05-02)
------------------

3.6.0 (2023-04-29)
------------------
* Renovate load controller tests (`#569 <https://github.com/ros-controls/ros2_controllers/issues/569>`_)
* Fix docs format (`#589 <https://github.com/ros-controls/ros2_controllers/issues/589>`_)
* Contributors: Bence Magyar, Christoph Fröhlich

3.5.0 (2023-04-14)
------------------
* Misplaced param init in admittance_controller (`#547 <https://github.com/ros-controls/ros2_controllers/issues/547>`_)
Expand Down
5 changes: 1 addition & 4 deletions admittance_controller/doc/userdoc.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.. _joint_trajectory_controller_userdoc:
.. _addmittance_controller_userdoc:

Admittance Controller
======================
Expand All @@ -8,9 +8,6 @@ The controller implements ``ChainedControllerInterface``, so it is possible to a

The controller requires an external kinematics plugin to function. The `kinematics_interface <https://github.com/ros-controls/kinematics_interface>`_ repository provides an interface and an implementation that the admittance controller can use.

Parameters:



ROS2 interface of the controller
---------------------------------
Expand Down
2 changes: 1 addition & 1 deletion admittance_controller/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>admittance_controller</name>
<version>3.5.0</version>
<version>3.7.0</version>
<description>Implementation of admittance controllers for different input and output interface.</description>
<maintainer email="[email protected]">Denis Štogl</maintainer>
<maintainer email="[email protected]">Bence Magyar</maintainer>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,9 @@ TEST(TestLoadAdmittanceController, load_controller)
ros2_control_test_assets::minimal_robot_urdf),
executor, "test_controller_manager");

ASSERT_NO_THROW(
cm.load_controller("load_admittance_controller", "admittance_controller/AdmittanceController"));
ASSERT_EQ(
cm.load_controller("load_admittance_controller", "admittance_controller/AdmittanceController"),
nullptr);
}

int main(int argc, char ** argv)
Expand Down
11 changes: 11 additions & 0 deletions diff_drive_controller/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@
Changelog for package diff_drive_controller
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

3.7.0 (2023-05-02)
------------------
* Fix wrong publish timestamp initialization (`#585 <https://github.com/ros-controls/ros2_controllers/issues/585>`_)
* Contributors: Noel Jiménez García

3.6.0 (2023-04-29)
------------------
* Renovate load controller tests (`#569 <https://github.com/ros-controls/ros2_controllers/issues/569>`_)
* adjusted open_loop param description in diff_drive_controller_parameter.yaml (`#570 <https://github.com/ros-controls/ros2_controllers/issues/570>`_)
* Contributors: Bence Magyar, muritane

3.5.0 (2023-04-14)
------------------

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ class DiffDriveController : public controller_interface::ControllerInterface
// publish rate limiter
double publish_rate_ = 50.0;
rclcpp::Duration publish_period_ = rclcpp::Duration::from_nanoseconds(0);
rclcpp::Time previous_publish_timestamp_{0};
rclcpp::Time previous_publish_timestamp_{0, 0, RCL_CLOCK_UNINITIALIZED};

bool is_halted = false;
bool use_stamped_vel_ = true;
Expand Down
2 changes: 1 addition & 1 deletion diff_drive_controller/package.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<package format="3">
<name>diff_drive_controller</name>
<version>3.5.0</version>
<version>3.7.0</version>
<description>Controller for a differential drive mobile base.</description>
<maintainer email="[email protected]">Bence Magyar</maintainer>
<maintainer email="[email protected]">Jordan Palacios</maintainer>
Expand Down
19 changes: 17 additions & 2 deletions diff_drive_controller/src/diff_drive_controller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,23 @@ controller_interface::return_type DiffDriveController::update(
tf2::Quaternion orientation;
orientation.setRPY(0.0, 0.0, odometry_.getHeading());

if (previous_publish_timestamp_ + publish_period_ < time)
bool should_publish = false;
try
{
if (previous_publish_timestamp_ + publish_period_ < time)
{
previous_publish_timestamp_ += publish_period_;
should_publish = true;
}
}
catch (const std::runtime_error)
{
// Handle exceptions when the time source changes and initialize publish timestamp
previous_publish_timestamp_ = time;
should_publish = true;
}

if (should_publish)
{
previous_publish_timestamp_ += publish_period_;

Expand Down Expand Up @@ -400,7 +416,6 @@ controller_interface::CallbackReturn DiffDriveController::on_configure(
// limit the publication on the topics /odom and /tf
publish_rate_ = get_node()->get_parameter("publish_rate").as_double();
publish_period_ = rclcpp::Duration::from_seconds(1.0 / publish_rate_);
previous_publish_timestamp_ = get_node()->get_clock()->now();

// initialize odom values zeros
odometry_message.twist =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,9 @@ TEST(TestLoadDiffDriveController, load_controller)
std::make_unique<hardware_interface::ResourceManager>(ros2_control_test_assets::diffbot_urdf),
executor, "test_controller_manager");

ASSERT_NO_THROW(
cm.load_controller("test_diff_drive_controller", "diff_drive_controller/DiffDriveController"));
ASSERT_NE(
cm.load_controller("test_diff_drive_controller", "diff_drive_controller/DiffDriveController"),
nullptr);

rclcpp::shutdown();
}
4 changes: 2 additions & 2 deletions doc/controllers_index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,14 @@ Available Controllers
:titlesonly:

Admittance Controller <../admittance_controller/doc/userdoc.rst>
Tricycle Controller <../tricycle_controller/doc/userdoc.rst>
Differential Drive Controller <../diff_drive_controller/doc/userdoc.rst>
Effort Controllers <../effort_controllers/doc/userdoc.rst>
Forward Command Controller <../forward_command_controller/doc/userdoc.rst>
Joint Trajectory Controller <../joint_trajectory_controller/doc/userdoc.rst>
PID Controller <../pid_controller/doc/userdoc.rst>
Position Controllers <../position_controllers/doc/userdoc.rst>
Tricycle Controller <../tricycle_controller/doc/userdoc.rst>
Velocity Controllers <../velocity_controllers/doc/userdoc.rst>
Effort Controllers <../effort_controllers/doc/userdoc.rst>


Available Broadcasters
Expand Down
8 changes: 8 additions & 0 deletions effort_controllers/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
Changelog for package effort_controllers
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

3.7.0 (2023-05-02)
------------------

3.6.0 (2023-04-29)
------------------
* Renovate load controller tests (`#569 <https://github.com/ros-controls/ros2_controllers/issues/569>`_)
* Contributors: Bence Magyar

3.5.0 (2023-04-14)
------------------

Expand Down
2 changes: 1 addition & 1 deletion effort_controllers/package.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<package format="3">
<name>effort_controllers</name>
<version>3.5.0</version>
<version>3.7.0</version>
<description>Generic controller for forwarding commands.</description>
<maintainer email="[email protected]">Bence Magyar</maintainer>
<maintainer email="[email protected]">Jordan Palacios</maintainer>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,10 @@ TEST(TestLoadJointGroupVelocityController, load_controller)
ros2_control_test_assets::minimal_robot_urdf),
executor, "test_controller_manager");

ASSERT_NO_THROW(cm.load_controller(
"test_joint_group_effort_controller", "effort_controllers/JointGroupEffortController"));
ASSERT_NE(
cm.load_controller(
"test_joint_group_effort_controller", "effort_controllers/JointGroupEffortController"),
nullptr);

rclcpp::shutdown();
}
8 changes: 8 additions & 0 deletions force_torque_sensor_broadcaster/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
Changelog for package force_torque_sensor_broadcaster
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

3.7.0 (2023-05-02)
------------------

3.6.0 (2023-04-29)
------------------
* Renovate load controller tests (`#569 <https://github.com/ros-controls/ros2_controllers/issues/569>`_)
* Contributors: Bence Magyar

3.5.0 (2023-04-14)
------------------

Expand Down
2 changes: 1 addition & 1 deletion force_torque_sensor_broadcaster/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>force_torque_sensor_broadcaster</name>
<version>3.5.0</version>
<version>3.7.0</version>
<description>Controller to publish state of force-torque sensors.</description>
<maintainer email="[email protected]">Bence Magyar</maintainer>
<maintainer email="[email protected]">Denis Štogl</maintainer>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,11 @@ TEST(TestLoadForceTorqueSensorBroadcaster, load_controller)
ros2_control_test_assets::minimal_robot_urdf),
executor, "test_controller_manager");

ASSERT_NO_THROW(cm.load_controller(
"test_force_torque_sensor_broadcaster",
"force_torque_sensor_broadcaster/ForceTorqueSensorBroadcaster"));
ASSERT_NE(
cm.load_controller(
"test_force_torque_sensor_broadcaster",
"force_torque_sensor_broadcaster/ForceTorqueSensorBroadcaster"),
nullptr);

rclcpp::shutdown();
}
9 changes: 9 additions & 0 deletions forward_command_controller/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@
Changelog for package forward_command_controller
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

3.7.0 (2023-05-02)
------------------

3.6.0 (2023-04-29)
------------------
* Renovate load controller tests (`#569 <https://github.com/ros-controls/ros2_controllers/issues/569>`_)
* Fix docs format (`#589 <https://github.com/ros-controls/ros2_controllers/issues/589>`_)
* Contributors: Bence Magyar, Christoph Fröhlich

3.5.0 (2023-04-14)
------------------

Expand Down
6 changes: 3 additions & 3 deletions forward_command_controller/doc/userdoc.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ forward_command_controller

This is a base class implementing a feedforward controller. Specific implementations can be found in:

- :ref:`position_controllers_userdoc`
- :ref:`velocity_controllers_userdoc`
- :ref:`effort_controllers_userdoc`
* :ref:`position_controllers_userdoc`
* :ref:`velocity_controllers_userdoc`
* :ref:`effort_controllers_userdoc`

Hardware interface type
-----------------------
Expand Down
2 changes: 1 addition & 1 deletion forward_command_controller/package.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<package format="3">
<name>forward_command_controller</name>
<version>3.5.0</version>
<version>3.7.0</version>
<description>Generic controller for forwarding commands.</description>
<maintainer email="[email protected]">Bence Magyar</maintainer>
<maintainer email="[email protected]">Jordan Palacios</maintainer>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,10 @@ TEST(TestLoadForwardCommandController, load_controller)
ros2_control_test_assets::minimal_robot_urdf),
executor, "test_controller_manager");

ASSERT_NO_THROW(cm.load_controller(
"test_forward_command_controller", "forward_command_controller/ForwardCommandController"));
ASSERT_NE(
cm.load_controller(
"test_forward_command_controller", "forward_command_controller/ForwardCommandController"),
nullptr);

rclcpp::shutdown();
}
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ TEST(TestLoadMultiInterfaceForwardController, load_controller)
ros2_control_test_assets::minimal_robot_urdf),
executor, "test_controller_manager");

ASSERT_NO_THROW(cm.load_controller(
"test_forward_command_controller",
"forward_command_controller/MultiInterfaceForwardCommandController"));
ASSERT_NE(
cm.load_controller(
"test_forward_command_controller",
"forward_command_controller/MultiInterfaceForwardCommandController"),
nullptr);
}
8 changes: 8 additions & 0 deletions gripper_controllers/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
Changelog for package gripper_controllers
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

3.7.0 (2023-05-02)
------------------

3.6.0 (2023-04-29)
------------------
* Renovate load controller tests (`#569 <https://github.com/ros-controls/ros2_controllers/issues/569>`_)
* Contributors: Bence Magyar

3.5.0 (2023-04-14)
------------------
* [Parameters] Use `gt_eq` instead of deprecated `lower_bounds` in validators (`#561 <https://github.com/ros-controls/ros2_controllers/issues/561>`_)
Expand Down
2 changes: 1 addition & 1 deletion gripper_controllers/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
schematypens="http://www.w3.org/2001/XMLSchema"?>
<package format="3">
<name>gripper_controllers</name>
<version>3.5.0</version>
<version>3.7.0</version>
<description>The gripper_controllers package</description>
<maintainer email="[email protected]">Bence Magyar</maintainer>

Expand Down
Loading

0 comments on commit 0850668

Please sign in to comment.