Tuning `input_filter_bandwidth` for `INPUT_MODE_POS_FILTER`

I’m having a hard time choosing a value for input_filter_bandwidth that produces smooth motion while resulting in the frequency of a sign wave drastically changing the amplitude. I’m planning on using the Step/Dir interface, but for testing I am just sending a series of position only commands over the ASCII serial protocol with INPUT_MODE_POS_FILTER. What is a reasonable procedure for choosing the value for the bandwidth for the filter in INPUT_MODE_POS_FILTER? And a follow up concern, does the input filter affect the main position/velocity/torque controller such that I would have to tune them both at the same time?

Yes and no. It doesn’t affect the controller directly, but it’s feeding forward the torque and velocity curves, so you may want to re-tune in the POS_FILTER mode.

It should ideally be set to the same bandwidth as the system. So you’d get everything set up, send a step torque command to the motor, and measure the system response. Then pick a bandwidth that results in the same curves. When you do that, you get position commands that are “achievable”, regardless of how they’re sent. This is something that’s way easier to do graphically, so I’d set up the GUI.