Skip to content

Add filtering capability to ft_broadcaster (backport #1814) - #1927

Merged
christophfroehlich merged 3 commits into
jazzyfrom
mergify/bp/jazzy/pr-1814
Sep 23, 2025
Merged

Add filtering capability to ft_broadcaster (backport #1814)#1927
christophfroehlich merged 3 commits into
jazzyfrom
mergify/bp/jazzy/pr-1814

Conversation

@mergify

@mergify mergify Bot commented Sep 23, 2025

Copy link
Copy Markdown
Contributor

Good morning!

This is a continuation of #559 as it was inactive.

The changes are minimal:

  1. Applied @saikishor suggestions
  • Added sensor_filter_chain to the parameters, which serves as documentation.
  • I removed all the logic about the additional frames. I agree with @saikishor that transforming to different frames should be handled by the user in their application. With this, no tf calls inside the RT are needed.
  • No more publishing NaN if the update of the filter failed.
  1. Added some relevant tests
    IMHO, the previous tests were testing the business logic of the filters themselves, that is, checking that the actual computations were correct, rather than the actual new logic for adding filters. I added three tests for configuring, activating/deactivating, and updating with a configured filter chain. Just one consideration: I changed a little bit the logic of SetUpFTSBroadcaster a little bit to accept a node name. This is because I added some parameters in the YAML that are needed for the broadcaster with filters. I cannot do set_parameter because the filter chain expects the parameters to be overrides.

Thanks a lot for your time!

Óscar


This is an automatic backport of pull request #1814 done by Mergify.

Co-authored-by: Denis Štogl <denis@stogl.de>
Co-authored-by: Guillaume Walck <guihome@wanadoo.fr>
Co-authored-by: Christoph Froehlich <christoph.froehlich@ait.ac.at>
Co-authored-by: Bence Magyar <bence.magyar.robotics@gmail.com>
Co-authored-by: Christoph Fröhlich <christophfroehlich@users.noreply.github.com>
Co-authored-by: Xavier Guay <xavguay@gmail.com>
Co-authored-by: Aarav Gupta <amronos275@gmail.com>
Co-authored-by: Oscar Lima <olima_84@yahoo.com>
Co-authored-by: Hilary Luo <103377417+hilary-luo@users.noreply.github.com>
Co-authored-by: Sai Kishor Kothakota <saisastra3@gmail.com>
Co-authored-by: Sai Kishor Kothakota <sai.kishor@pal-robotics.com>
(cherry picked from commit 4f9c462)

# Conflicts:
#	doc/release_notes.rst
#	force_torque_sensor_broadcaster/src/force_torque_sensor_broadcaster.cpp
@mergify mergify Bot added the conflicts label Sep 23, 2025
@mergify

mergify Bot commented Sep 23, 2025

Copy link
Copy Markdown
Contributor Author

Cherry-pick of 4f9c462 has failed:

On branch mergify/bp/jazzy/pr-1814
Your branch is up to date with 'origin/jazzy'.

You are currently cherry-picking commit 4f9c462.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   force_torque_sensor_broadcaster/CMakeLists.txt
	modified:   force_torque_sensor_broadcaster/doc/userdoc.rst
	modified:   force_torque_sensor_broadcaster/include/force_torque_sensor_broadcaster/force_torque_sensor_broadcaster.hpp
	modified:   force_torque_sensor_broadcaster/package.xml
	modified:   force_torque_sensor_broadcaster/src/force_torque_sensor_broadcaster_parameters.yaml
	new file:   force_torque_sensor_broadcaster/test/dummy_filter.cpp
	new file:   force_torque_sensor_broadcaster/test/dummy_filter_plugin.xml
	modified:   force_torque_sensor_broadcaster/test/force_torque_sensor_broadcaster_params.yaml
	modified:   force_torque_sensor_broadcaster/test/test_force_torque_sensor_broadcaster.cpp
	modified:   force_torque_sensor_broadcaster/test/test_force_torque_sensor_broadcaster.hpp

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   doc/release_notes.rst
	both modified:   force_torque_sensor_broadcaster/src/force_torque_sensor_broadcaster.cpp

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@codecov

codecov Bot commented Sep 23, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 95.23810% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.57%. Comparing base (b9f3358) to head (9f829c0).
⚠️ Report is 1 commits behind head on jazzy.

Files with missing lines Patch % Lines
...roadcaster/src/force_torque_sensor_broadcaster.cpp 92.50% 3 Missing ⚠️
...ce_torque_sensor_broadcaster/test/dummy_filter.cpp 80.00% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##            jazzy    #1927      +/-   ##
==========================================
+ Coverage   85.52%   85.57%   +0.04%     
==========================================
  Files         137      138       +1     
  Lines       13171    13231      +60     
  Branches     1143     1146       +3     
==========================================
+ Hits        11265    11322      +57     
- Misses       1544     1547       +3     
  Partials      362      362              
Flag Coverage Δ
unittests 85.57% <95.23%> (+0.04%) ⬆️

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 98.46% <100.00%> (+0.30%) ⬆️
...ce_torque_sensor_broadcaster/test/dummy_filter.cpp 80.00% <80.00%> (ø)
...roadcaster/src/force_torque_sensor_broadcaster.cpp 91.17% <92.50%> (+0.49%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@christophfroehlich
christophfroehlich merged commit b5dcb11 into jazzy Sep 23, 2025
13 of 14 checks passed
@christophfroehlich
christophfroehlich deleted the mergify/bp/jazzy/pr-1814 branch September 23, 2025 20:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Backporting filtering for ft sensor broadcaster to jazzy branch

2 participants