ros2_controllers
ros2_controllers copied to clipboard
[JTC] Cleanup API
The last bullet point and closes #944.
The methods
fill_partial_goal
sort_to_local_joint_order
validate_trajectory_msg
add_new_trajectory_msg
all used class variables, like dof_ and so on. I moved them to a separate file as proposed, and wrote additional unit tests. I used the JTC-GPL-parameter struct as function arguments, but this makes these methods not really standalone without JTC.
- Should I add all relevant fields directly and remove the struct as dependency?
- Passing the logger and time to the methods seems a bit verbose, any suggestions?
The logic is almost identical, except for sort_to_local_joint_order
where I also updated the joint_names field
// might not be used any more, but to get a genuine msg
trajectory_msg->joint_names = params.joints;