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

[ForceTorqueSensorBroadcaster] added force and torque offsets to the parameters + export state interfaces #1215

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

saikishor
Copy link
Member

@saikishor saikishor commented Jul 17, 2024

This PR allows to define of the offsets of the force and torque through the parameter server. It would also be interesting to make it a chainable controller and expose the interfaces to the other controllers.

Now the offsets are removed and published and the same interfaces are exposed as state interfaces to be able to chain by other controllers

Copy link

codecov bot commented Jul 17, 2024

Codecov Report

Attention: Patch coverage is 94.66667% with 4 lines in your changes missing coverage. Please review.

Project coverage is 80.68%. Comparing base (7c89c17) to head (1f175ec).

Files with missing lines Patch % Lines
...roadcaster/src/force_torque_sensor_broadcaster.cpp 91.30% 1 Missing and 3 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1215      +/-   ##
==========================================
+ Coverage   80.57%   80.68%   +0.11%     
==========================================
  Files         109      109              
  Lines        9553     9625      +72     
  Branches      832      841       +9     
==========================================
+ Hits         7697     7766      +69     
- Misses       1578     1579       +1     
- Partials      278      280       +2     
Flag Coverage Δ
unittests 80.68% <94.66%> (+0.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...ster/test/test_force_torque_sensor_broadcaster.cpp 97.82% <100.00%> (+0.57%) ⬆️
...roadcaster/src/force_torque_sensor_broadcaster.cpp 89.21% <91.30%> (+2.77%) ⬆️

... and 2 files with indirect coverage changes

@saikishor saikishor changed the title [force_torque_sensor_broadcaster] added force and torque offsets to the parameters [ForceTorqueSensorBroadcaster] added force and torque offsets to the parameters Jul 18, 2024
@saikishor saikishor changed the title [ForceTorqueSensorBroadcaster] added force and torque offsets to the parameters [ForceTorqueSensorBroadcaster] added force and torque offsets to the parameters + export state interfaces Jul 18, 2024
Comment on lines 224 to 229
msg.wrench.force.x -= params.offset.force.x;
msg.wrench.force.y -= params.offset.force.y;
msg.wrench.force.z -= params.offset.force.z;
msg.wrench.torque.x -= params.offset.torque.x;
msg.wrench.torque.y -= params.offset.torque.y;
msg.wrench.torque.z -= params.offset.torque.z;
Copy link
Member

Choose a reason for hiding this comment

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

I don't want to be a nag but I'd reeeeeeeally expect offsets to be added using a +

Copy link
Member Author

Choose a reason for hiding this comment

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

A very very fair point!
I'll try to change it ASAP

Copy link
Member Author

Choose a reason for hiding this comment

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

Done. I've made the changes. Thanks for the feedback

@saikishor
Copy link
Member Author

Rebased the PR! :)

@saikishor saikishor force-pushed the add/offsets/force_torque_sensor_broadcaster branch from 4bab5f6 to f7643ba Compare October 7, 2024 16:49
Copy link
Contributor

@christophfroehlich christophfroehlich left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants