-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gazebo_yarp_controlboard: Add coupling icub_left_hand_mk4 to model iCub mk4 left hand #620
Conversation
@@ -326,7 +327,7 @@ bool GazeboYarpControlBoardDriver::gazebo_init() | |||
} | |||
else if (coupling_bottle->get(0).asString()=="icub_hand_mk3") | |||
{ | |||
BaseCouplingHandler* cpl = new HandMk3CouplingHandler(m_robot,coupled_joints, coupled_joint_names, coupled_joint_limits); | |||
BaseCouplingHandler* cpl = new HandMk4CouplingHandler(m_robot,coupled_joints, coupled_joint_names, coupled_joint_limits); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This piece of code uses the HandMk4CouplingHandler
class if the coupling name asked is icub_hand_mk3
, I am afraid this may be confusing, what do you think? See also the subsquent message yCInfo(GAZEBOCONTROLBOARD) << "using icub_hand_mk3";
. Perhaps we could have a specific coupling name for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I kept the naming icub_hand_mk3
to be back-compatible on the user-configuration level, but I agree, it might be better to give it a specific name and separate things and maybe keep both classes for the time being.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I think in any case you would not be able to be back-compatible as the number of joints is different, right?
Some comments on the top of the one that I did online. Do you have a reference for the coupling laws? For the mantainability it would be great if the coupling laws are documented (i.e. written down) somewhere, and then the gazebo plugins just implement the laws documented somewhere else. This is not a strict requirement if it takes too much time (in #469 we merged the mk3 coupling without any public reference) but it would be nice to have.
I am not sure we did any announcement on that coupling being obsolete in any changelog. Furthermore, that coupling is still used in the model |
By the way, I was wondering: the coupling is the same for the left and right hand, or is this a left-specific coupling? |
Hi @traversaro
This is a good point indeed, but I'd call for someone from the Team DEV (@Andrea-Mor, @andreaderito) to address it, as we're not the original developers. |
The only reference I have is the document posted in #469, I'll attach it in the PR post, at least until proper documentation on the subject is done, if it's ok.
My bad! Correcting the PR post now.
Agreed! I will add a commit to add a new HandMk4 class and keep HandMk3 for the time being. |
Sure, as mention this is just a nice to have, not something that is blocking the PR. |
@mfussi66 I updated the CHANGELOG and PR title, let me know if you think this is ok. The only remaining point is #620 (comment), do you have any idea on that? If the coupling is left-specific, probably it would be nice to already use a left-specific name for the coupling. |
@traversaro Honestly I did not think about that aspect, my bad. Of course the left and right hands will be mirrored, therefore some quantities' signs might change in the coupling laws. So I guess the class name should change too? |
Thanks, yes at least for the parameter name at this point I would then use a left-specific name, for all the rest of the names (for example the class) we can use the existing one as they can always be changed later. |
Ok for me! @mfussi66 it is ok for you if I merge with squash to get a clean history? |
@traversaro even better! |
This PR aims to
update the coupling rules of the mk3 hand with the new mk4 version given that the former is now obsoleteadd new coupling rules for the new iCub hand mk4, while keeping intact the mk3 version until declared obsolete.The hand mk4 has 5 fingers, causing an increase in the number of joints. In particular, the ring and pinkie fingers move together, since they are physically actuated by one tendon only.
The coupling laws that map the degrees of actuation into model joints are kept to the mk3 version, although they need updating since the geometric quantities have changed.
Reference documentation on the subject:
FingerkinV2.docx