control_toolbox icon indicating copy to clipboard operation
control_toolbox copied to clipboard

LowPassFilter accepts parameters only from node

Open roncapat opened this issue 1 year ago • 2 comments

I wanted to use LowPassFilter, but it seems to me that there is no way to pass parameters via API (like PID constructor or setGains() call).

Wouldn't be better to make LowPassFilter support parameter passing via API and a corresponding LowPassFilterROS querying parameters from configuration instead? Or just modifying LowPassFilter to support both scenarios...

I would contribute a PR following your feedbacks of course.

roncapat avatar Oct 09 '23 14:10 roncapat

I think it is possible to change the parameters at runtime using this->set_parameter. Similar to https://github.com/ros-controls/control_toolbox/blob/759d95422893e03fdc88bfe0430370b13902b6f7/test/control_filters/test_low_pass_filter.cpp#L27

CalaW avatar Feb 25 '24 06:02 CalaW

I support the idea of a base implementation without ROS, and then being wrapped in the filters-class with the ROS node interfaces. @roncapat Even if your idea is a few months old, I'd welcome a PR.

christophfroehlich avatar Feb 25 '24 08:02 christophfroehlich