[KDL] Trajectory Generator - Path_RoundedComposite
| Submitted by Enea Scioni on Mon, 2012-06-11 15:47 |
Dear All,
I am trying to create a simple component for trajectory generator purpose, using Path_RoundedComposite. I am following the example trajectory_example.cpp for that, but I keep catching the following exception:
3.562 [ ERROR ][Logger] Circle : Plane for motion is not properly defined
What is the exact meaning of this? And why is not properly defined? ( = what am I doing wrong?) (To be sure, I used the same values/viaponts used in the example, same velocity profile parameterization and so on....)
I report below part of the code interested...
_path.reset(new KDL::Path_RoundedComposite(0.2,0.01,new KDL::RotationalInterpolation_SingleAxis()));
_path->Add(KDL::Frame(KDL::Rotation::RPY(M_PI,0,0), KDL::Vector(-1,0,0)));
_path->Add(KDL::Frame(KDL::Rotation::RPY(M_PI/2,0,0), KDL::Vector(-0.5,0,0)));
_path->Add(KDL::Frame(KDL::Rotation::RPY(0,0,0), KDL::Vector(0,0,0)));
_path->Add(KDL::Frame(KDL::Rotation::RPY(0.7,0.7,0.7), KDL::Vector(1,1,1)));
_path->Add(KDL::Frame(KDL::Rotation::RPY(0,0.7,0), KDL::Vector(1.5,0.3,0)));
_path->Add(KDL::Frame(KDL::Rotation::RPY(0.7,0.7,0), KDL::Vector(1,1,0)));
_path->Finish();
_vel_profile.reset(new KDL::VelocityProfile_Trap(0.5,0.1));
_vel_profile->SetProfile(0,_path->PathLength());
_traj.reset(new KDL::Trajectory_Segment(_path.get(),_vel_profile.get()));
_max_duration = KDL::max(10, _traj->Duration());
_time_passed = 0;
_time_begin = os::TimeService::Instance()->getTicks();
}
catch(KDL::Error& e)
{
log(Error) << e.Description() << endlog();
return false;
}
Thank You in advance! - Enea Scioni
