ADVRHumanoids / XBotControl

XBotControl framework: XBotCore + OpenSoT + CartesI/O
33 stars 3 forks source link

Fix ModelInterface::getVelocityTwist RT break #25

Closed EdoardoRomiti closed 5 years ago

EdoardoRomiti commented 5 years ago

@EnricoMingo: Line 616 of ModelInterface.cpp woul trigger a warning of breaking real-time:

bool XBot::ModelInterface::getVelocityTwist( const std::string& source_frame,
                               const std::string& target_frame,
                               Eigen::Matrix<double,6,1>& velocity) const
{
    bool success = getRelativeJacobian(source_frame, target_frame, _tmp_jacobian_relative);
    getJointVelocity(_tmp_jstate);
--->  velocity.noalias() = _tmp_jacobian_relative*_tmp_jstate;
    return success;
}

The fix with .noalias() seems to have solved it

EnricoMingo commented 5 years ago

Solved in commit 71b86145627fb8b1c504ac6aefb42c554487a47f last devel.