-
Notifications
You must be signed in to change notification settings - Fork 70
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
[contact switching] Added setPrimaryFoot method and switch with contact makes #411
[contact switching] Added setPrimaryFoot method and switch with contact makes #411
Conversation
prashanthr05
commented
Jan 31, 2018
•
edited
Loading
edited
- Adding a useful setter method for contact switching
- Changed the switching logic to account for contact makes rather than contact breaks
* set primary foot | ||
* @param foot primary foot | ||
*/ | ||
void setPrimaryFoot(contactFoot foot) { m_primaryFoot = foot; } |
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.
What happens if I call setPrimaryFoot(UNKNOWN_FOOT)
?
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 method was mainly intended to be called by an external process to set the primary foot in the initial setting, before any contact is broken. In case it is set to UNKNOWN_FOOT, it waits for the foot normal force measurements (checks left first and then right), and activates corresponding foot, handled in the detectTransitions() method. In my opinion, this could be handled in a better way. But, I am not able to think how. Do you have any suggestions ?
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.
The current behavior is ok for me, can you just document it in a method? Just copy&paste the phrase you used in this comment is ok, thanks.
6f64e1e
to
d113240
Compare