30 #include <mc_rbdyn/rpy_utils.h>
52 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
96 void configure(
const mc_rtc::Configuration & config);
120 void updateSupportPath(
const sva::PTransformd & X_0_lf,
const sva::PTransformd & X_0_rf);
129 return plans_.keys();
139 return customPlan_.
name;
147 std::string
gait() const noexcept
168 void gait(
const std::string & dir)
175 else if(dir ==
"Turn")
199 if(name.rfind(
"custom_", 0) == 0)
205 if(name == customPlan_.
name)
221 targetPose_ = lastBackwardTarget_;
231 targetPose_ = lastForwardTarget_;
241 targetPose_ = lastLateralTarget_;
274 return worldReference_;
324 void restoreDefaults();
331 void runShuffling_();
351 SE2d initPose_ = {0., 0., 0.};
352 SE2d lastBackwardTarget_ = {-0.5, 0., 0.};
353 SE2d lastForwardTarget_ = {0.5, 0., 0.};
354 SE2d lastLateralTarget_ = {0.0, 0.3, 0.};
355 SE2d targetPose_ = {0.5, 0., 0.};
356 bool startWithRightFootstep_ =
true;
357 double desiredStepAngle_ = 10. * M_PI / 180.;
358 double desiredStepLength_ = 0.2;
359 double extraStepWidth_ = 0.;
360 double outputVel_ = 0.25;
361 double stepAngle_ = 0.0;
362 double stepLength_ = 0.2;
363 double stepWidth_ = 0.18;
364 mc_rtc::Configuration plans_;
365 std::shared_ptr<mc_rtc::gui::StateBuilder> gui_;
366 std::vector<Eigen::Vector3d> supportPathDisplay_;
367 sva::PTransformd worldReference_;
368 unsigned nbFootsteps_ = 0;
369 bool hasRun_ =
false;
bool checkPlanUpdated()
Checks whether the plan has been recomputed (run() was called)
void configure(const mc_rtc::Configuration &config)
void stepWidth(double stepWidth)
static constexpr double DEFAULT_EXTRA_STEP_WIDTH
void updateLocalTarget_(const SE2d &target)
void restoreLateralTarget()
static constexpr double IN_PLACE_MAX_STEP_ANGLE
void gait(const std::string &dir)
static constexpr double MIN_STEP_LENGTH
std::string gait() const noexcept
const sva::PTransformd & worldReference() const
static constexpr double MAX_SAGITTAL_STEP_LENGTH
void restoreForwardTarget()
void restoreBackwardTarget()
FootstepPlan getPlan(std::string name)
std::vector< std::string > availablePlans() const
static constexpr double MAX_LATERAL_STEP_LENGTH
PlanInterpolator(std::shared_ptr< mc_rtc::gui::StateBuilder > gui)
static constexpr double MAX_EXTRA_STEP_WIDTH
static constexpr double IN_PLACE_EXTRA_STEP_WIDTH
void updateSupportPath(const sva::PTransformd &X_0_lf, const sva::PTransformd &X_0_rf)
const std::string & customPlanName() const
void worldReference(const sva::PTransformd &worldReference)
void updateWorldTarget_(const Eigen::Vector3d &desired)
lipm_walking::utils::SE2d SE2d