Go to the documentation of this file.
36 template<
typename Derived>
62 const Eigen::Matrix3d &
target,
63 const std::vector<std::pair<double, Eigen::Matrix3d>> & oriWp = {});
84 void oriWaypoints(
const std::vector<std::pair<double, Eigen::Matrix3d>> & oriWp);
114 void dimWeight(
const Eigen::VectorXd & dimW)
override;
120 Eigen::VectorXd
dimWeight()
const override;
243 void dampingInterpolation(
const std::vector<std::pair<double, Eigen::Vector6d>> & dampingGains);
262 Eigen::VectorXd
eval()
const override;
283 const sva::PTransformd
target()
const;
327 void refPose(
const sva::PTransformd & pose);
333 const sva::PTransformd &
refPose()
const;
375 #include <mc_tasks/SplineTrajectoryTask.hpp>
Simplify access to values hold within a JSON file.
Definition: Configuration.h:165
void update(mc_solver::QPSolver &) override
Update trajectory target.
double duration_
Definition: SplineTrajectoryTask.h:360
double damping() const
Get the current task damping.
Describes a trajectory with smoothly interpolate rotation between waypoints.
Definition: InterpolatedRotation.h:21
Eigen::VectorXd dimWeight() const override
Gets the dimensional weights (orientation/translation)
bool inSolver_
Definition: SplineTrajectoryTask.h:371
bool pause() const noexcept
Definition: SplineTrajectoryTask.h:313
const Eigen::VectorXd & refVel() const
Get the trajectory reference velocity.
SequenceInterpolator6d stiffnessInterpolator_
Definition: SplineTrajectoryTask.h:364
void addToLogger(mc_rtc::Logger &logger) override
Add information about the task to the logger.
mc_rbdyn::ConstRobotFramePtr frame_
Definition: SplineTrajectoryTask.h:359
Definition: QPSolver.h:85
void setGains(double stiffness, double damping)
Set both stiffness and damping.
unsigned samples_
Definition: SplineTrajectoryTask.h:370
bool paused_
Definition: SplineTrajectoryTask.h:367
unsigned displaySamples() const
Number of samples for displaying the spline.
double weight() const
Returns the task weight.
Generic CRTP implementation for a task tracking a curve in both position and orientation....
Definition: SplineTrajectoryTask.h:37
const sva::PTransformd & refPose() const
Returns the trajectory reference world pose.
void load(mc_solver::QPSolver &solver, const mc_rtc::Configuration &config) override
Load parameters from a Configuration object.
bool timeElapsed() const
Whether the trajectory has finished.
Logs controller data to disk.
Definition: Logger.h:29
double stiffness() const
Get the current task stiffness.
Definition: RobotFrame.h:21
double duration() const noexcept
Returns the trajectory's duration.
Definition: SplineTrajectoryTask.h:319
const std::vector< std::pair< double, Eigen::Vector6d > > & stiffnessInterpolation() const noexcept
Sets the dimensional weights (controls the importance of orientation/translation).
Definition: SplineTrajectoryTask.h:225
Eigen::VectorXd dimWeight() const override
Get the current task's dim weight vector.
const Eigen::VectorXd & refAccel() const
Get the trajectory reference acceleration.
void addToGUI(mc_rtc::gui::StateBuilder &gui) override
Add task controls to the GUI. Interactive controls for the trajectory waypoints and end-endpoints aut...
std::function< bool(const mc_tasks::MetaTask &, std::string &)> buildCompletionCriteria(double dt, const mc_rtc::Configuration &config) const override
void oriWaypoints(const std::vector< std::pair< double, Eigen::Matrix3d >> &oriWp)
Sets the orientation waypoints.
const std::vector< std::pair< double, Eigen::Vector6d > > & dimWeightInterpolation() const noexcept
Sets the dimensional weights (controls the importance of orientation/translation).
Definition: SplineTrajectoryTask.h:205
Definition: StateBuilder.h:27
TrajectoryTaskGeneric(const mc_rbdyn::Robots &robots, unsigned int robotIndex, double stiffness, double weight)
Constructor (auto damping)
std::shared_ptr< const RobotFrame > ConstRobotFramePtr
Definition: fwd.h:25
const sva::PTransformd target() const
Gets the target pose (position/orientation)
void values(const TimedValueVector &values)
Set interpolator values.
Definition: SequenceInterpolator.h:82
double currentTime() const noexcept
Definition: SplineTrajectoryTask.h:316
SequenceInterpolator6d dampingInterpolator_
Definition: SplineTrajectoryTask.h:365
double currTime_
Definition: SplineTrajectoryTask.h:369
SequenceInterpolator6d dimWeightInterpolator_
Definition: SplineTrajectoryTask.h:363
void pause(bool paused)
Allows to pause the task.
Definition: SplineTrajectoryTask.h:310
virtual Eigen::VectorXd evalTracking() const
Returns the trajectory tracking error: transformError between the current robot surface pose and its ...
mc_trajectory::InterpolatedRotation oriSpline_
Definition: SplineTrajectoryTask.h:361
SplineTrajectoryTask(const mc_rbdyn::RobotFrame &frame, double duration, double stiffness, double weight, const Eigen::Matrix3d &target, const std::vector< std::pair< double, Eigen::Matrix3d >> &oriWp={})
Constructor.
Definition: StabilizerStandingState.h:11
const std::vector< std::pair< double, Eigen::Vector6d > > & dampingInterpolation() const noexcept
Sets the dimensional weights (controls the importance of orientation/translation).
Definition: SplineTrajectoryTask.h:244
Generic wrapper for a trajectory dynamic over an error function.
Definition: TrajectoryTaskGeneric.h:26
Eigen::VectorXd eval() const override
Returns the transformError between current robot surface pose and its final target.