robotology-legacy / mex-wholebodymodel

Matlab MEX interface to the iWholeBodyModel interface.
11 stars 9 forks source link

[Interface] Remove wbm_setWorldLink ? #43

Closed traversaro closed 8 years ago

traversaro commented 8 years ago

A lot of users have been confused by the semantics of the setWorldLink function https://github.com/robotology/mex-wholebodymodel/issues/26 and now it is possible to use all the functions by directly passing the complete state https://github.com/robotology/mex-wholebodymodel/issues/27 .

If no code it is supposed to use this function, perhaps it is a better idea to just remove it from the interface, to avoid confusion/misuse by the users?

After that, for symmetry with all existing calls, it could make sense to have an updateState in which you pass all the state, with also the base position (basically a combination of setWorldFrame + updateState ).

In this way we would be more consistent with all the existing interfaces.

traversaro commented 8 years ago

cc @naveenoid @gabrielenava opinions?

traversaro commented 8 years ago

This would also have the side benefits of removing the hardcoded "l_sole" in the code ( https://github.com/robotology/mex-wholebodymodel/blob/6603ab444e828f05bcb71c0317e4421e97736ac8/src/modelstate.cpp#L41 ).

traversaro commented 8 years ago

Another example of confusion regarding wbm_setWorldLink semantics : https://github.com/robotology/mex-wholebodymodel/issues/47#issuecomment-150511583 .

DanielePucci commented 8 years ago

I completely agree with you: passing the whole state is the right way to go. How do we pass this state for SE(3)? Do we pass quaternions or what? @naveenoid opinions?

traversaro commented 8 years ago

We are currently passing rotation matrices.

DanielePucci commented 8 years ago

Now we are talking [1]

[1] http://www.youtube.com/watch?v=k17KH6F63aE&t=1m24s

naveenoid commented 8 years ago

I will most likely remove this once PR https://github.com/robotology/mex-wholebodymodel/pull/49 is merged

naveenoid commented 8 years ago

Tackled in https://github.com/robotology/mex-wholebodymodel/pull/52