ros_control
ros_control copied to clipboard
Joint limits debug helper functionality
Currently there is no easy way to tell when the joint_limits_interface is limiting joints, but it can be very helpful in debugging why your trajectory isn't moving the way it should to get feedback during testing. This well documented debug code is disabled by default (not even compiled) but allows one to see information about joint limits and usage of them.
If other maintainers like this addition, we can add the debug to all types of joint_limits_interfaces, not just the position joint limit.
This sounds useful but do you think you could change the implementation slightly so that it is more of a runtime feature? I haven't thought of realtime implications, but having to recompile & change the macro is only a small step up from writing the prints by hand.
It could be published on the diagnostics perhaps?
I can just remove all the changes in joint_limits_interface.h
, but what do you say to the print()
function - IMHO all classes should usually have those
:+1: for the print method, it is good to have inspection tools
@bmagyar Unfortunately, diagnostic publishers aren't RT-safe.
However, I'm of the opinion we should add diagnostics anyway, with a flag to enable them (disabled by default). After all, sometimes is legal to break RT for debugging purposes, or even some people don't even have RT constraints and can benefit from diagnostics.
Either way, IMHO this is probably very low level for a diagnostic message. I don't know, it'd depend on the frequency it gets published, and the level of detail (in terms of the information provided).
👍 for making it optional, I'd help a lot when in trouble