Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom PID error rate #525

Merged
merged 2 commits into from
Mar 14, 2023
Merged

Custom PID error rate #525

merged 2 commits into from
Mar 14, 2023

Conversation

nkoenig
Copy link
Contributor

@nkoenig nkoenig commented Mar 13, 2023

🎉 New feature

Summary

Adds the ability to specify the error rate for PID::Update.

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by messages.

Signed-off-by: Nate Koenig <natekoenig@gmail.com>
@github-actions github-actions bot added 🏯 fortress Ignition Fortress 🏰 citadel Ignition Citadel labels Mar 13, 2023
@codecov
Copy link

codecov bot commented Mar 13, 2023

Codecov Report

Merging #525 (64183d6) into ign-math6 (3b9a192) will increase coverage by 0.00%.
The diff coverage is 100.00%.

❗ Current head 64183d6 differs from pull request most recent head c61837b. Consider uploading reports for the commit c61837b to get more accurate results

@@            Coverage Diff             @@
##           ign-math6     #525   +/-   ##
==========================================
  Coverage      99.68%   99.68%           
==========================================
  Files             73       73           
  Lines           6913     6918    +5     
==========================================
+ Hits            6891     6896    +5     
  Misses            22       22           
Impacted Files Coverage Δ
src/PID.cc 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Contributor

@adityapande-1995 adityapande-1995 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a way to add a test case for the dt == 0 or invalid error (infinite) case, to make the codecov bot happy ? Otherwise the macro/comment to skip that section for codecov.

Signed-off-by: Nate Koenig <natekoenig@gmail.com>
@nkoenig
Copy link
Contributor Author

nkoenig commented Mar 14, 2023

@adityapande-1995 , I added a test.

/// to the object being controlled.
/// \return the command value
public: double Update(const double _error,
double _errorRate,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: the mix of const double and double looks funny. Can we make them both one or the other?

@nkoenig nkoenig merged commit 27cdb93 into ign-math6 Mar 14, 2023
@nkoenig nkoenig deleted the nkoenig/pid_update_custom_error branch March 14, 2023 18:29
danilogsch pushed a commit to danilogsch/gz-math that referenced this pull request Jun 1, 2023
* Custom PID error rate

Signed-off-by: Nate Koenig <natekoenig@gmail.com>

* added test

Signed-off-by: Nate Koenig <natekoenig@gmail.com>

---------

Signed-off-by: Nate Koenig <natekoenig@gmail.com>
mjcarroll added a commit that referenced this pull request Aug 22, 2023
… models (#486)

* Class ignition::math::MecanumDriveOdometryPrivate to handle Mecanum wheels odometry

Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* Update include/ignition/math/MecanumDriveOdometry.hh

Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* Update include/ignition/math/MecanumDriveOdometry.hh

Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* Update include/ignition/math/MecanumDriveOdometry.hh

Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* Update src/MecanumDriveOdometry.cc

Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* MecanumDrive doc

Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* MecanumDrive doc

Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>

* Update MecanumDriveOdometry.cc

line length corrections

* Update include/ignition/math/MecanumDriveOdometry.hh

* CI workflow: use checkout v3 (#519)

Version v2 of the actions/checkout workflow is
deprecated, so switch to v3.

Part of gazebo-tooling/release-tools#862.

Signed-off-by: Steve Peters <scpeters@openrobotics.org>

* Rename COPYING to LICENSE (#521)

The LICENSE file contained a copy of the stanze
used at the top of source code files, while the
actual license was in the COPYING file. So remove
the stanza and put the actual Apache 2.0 license text
in LICENSE.

Signed-off-by: Steve Peters <scpeters@openrobotics.org>

* Custom PID error rate (#525)

* Custom PID error rate

Signed-off-by: Nate Koenig <natekoenig@gmail.com>

* added test

Signed-off-by: Nate Koenig <natekoenig@gmail.com>

---------

Signed-off-by: Nate Koenig <natekoenig@gmail.com>

* Add option to skip pybind11 and SWIG (#480)

Signed-off-by: Michael Carroll <michael@openrobotics.org>

* Disable pybind11 on windows by default (#529)

Signed-off-by: Addisu Z. Taddese <addisu@openrobotics.org>

* 🎈 6.14.0 (#531)

Signed-off-by: Addisu Z. Taddese <addisu@openrobotics.org>

* Lint

Signed-off-by: Michael Carroll <mjcarroll@intrinsic.ai>

* Port changes and tests from muttistefano

Co-authored-by: muttistefano <mutti.stefano.jp@gmail.com>
Signed-off-by: Michael Carroll <mjcarroll@intrinsic.ai>

* Add accessor and TODO note

Signed-off-by: Michael Carroll <mjcarroll@intrinsic.ai>

---------

Signed-off-by: danilo_gsch <danilo_gsch@hotmail.com>
Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Signed-off-by: Nate Koenig <natekoenig@gmail.com>
Signed-off-by: Michael Carroll <michael@openrobotics.org>
Signed-off-by: Addisu Z. Taddese <addisu@openrobotics.org>
Signed-off-by: Michael Carroll <mjcarroll@intrinsic.ai>
Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
Co-authored-by: Steve Peters <scpeters@openrobotics.org>
Co-authored-by: Nate Koenig <natekoenig@gmail.com>
Co-authored-by: Michael Carroll <michael@openrobotics.org>
Co-authored-by: Addisu Z. Taddese <addisu@openrobotics.org>
Co-authored-by: Michael Carroll <mjcarroll@intrinsic.ai>
Co-authored-by: muttistefano <mutti.stefano.jp@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏰 citadel Ignition Citadel 🏯 fortress Ignition Fortress
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants