lipm_walking::states::Standing Struct Reference

Enable stabilizer and keep CoM at a reference position. More...

#include <states/Standing.h>

Inheritance diagram for lipm_walking::states::Standing:
lipm_walking::State

Public Member Functions

void start () override
 Start state. More...
 
void teardown () override
 Teardown state. More...
 
void checkPlanUpdates ()
 Check for footstep plan updates. More...
 
bool checkTransitions () override
 Check transitions at beginning of control cycle. More...
 
void runState () override
 Main state function, called if no transition at this cycle. More...
 
void distributeFootCoPs ()
 Distribute spatial ZMP into foot CoPs in double support. More...
 
void updateTarget (double leftFootRatio)
 Update target CoM and CoP. More...
 
void makeFootContact (std::shared_ptr< mc_tasks::force::CoPTask > footTask, const Contact &contact)
 Make foot contact. More...
 
void makeLeftFootContact ()
 Make left foot contact. More...
 
void makeRightFootContact ()
 Make right foot contact. More...
 
bool releaseFootContact (std::shared_ptr< mc_tasks::force::CoPTask > footTask)
 Release foot contact. More...
 
void releaseLeftFootContact ()
 Release left foot contact. More...
 
void releaseRightFootContact ()
 Release right foot contact. More...
 
void startWalking ()
 Enable startWalking_ boolean and update GUI. More...
 
- Public Member Functions inherited from lipm_walking::State
EIGEN_MAKE_ALIGNED_OPERATOR_NEW void configure (const mc_rtc::Configuration &) override
 No configuration by default. More...
 
Controllercontroller ()
 Get controller. More...
 
std::shared_ptr< mc_rtc::gui::StateBuilder > gui ()
 Get GUI handle. More...
 
mc_rtc::Logger & logger ()
 Get logger. More...
 
Pendulumpendulum ()
 Get pendulum reference. More...
 
FootstepPlanplan ()
 Get footstep plan. More...
 
bool run (mc_control::fsm::Controller &) override
 Main function. More...
 
Stabilizerstabilizer ()
 Get stabilizer. More...
 
void start (mc_control::fsm::Controller &controller) override
 Start function. More...
 
void teardown (mc_control::fsm::Controller &) override
 Teardown function. More...
 

Protected Member Functions

void updatePlan (const std::string &name)
 Change footstep plan. More...
 

Additional Inherited Members

- Protected Attributes inherited from lipm_walking::State
Controllercontroller_ = nullptr
 

Detailed Description

Enable stabilizer and keep CoM at a reference position.

Applies a simple CoM set-point task:

\[ \ddot{c} = K (c^d - c) - B \dot{c} \]

with critical damping \(B = 2 \sqrt{K}\).

Definition at line 53 of file Standing.h.

Member Function Documentation

void lipm_walking::states::Standing::checkPlanUpdates ( )

Check for footstep plan updates.

Definition at line 205 of file Standing.cpp.

bool lipm_walking::states::Standing::checkTransitions ( )
overridevirtual

Check transitions at beginning of control cycle.

Implements lipm_walking::State.

Definition at line 304 of file Standing.cpp.

void lipm_walking::states::Standing::distributeFootCoPs ( )

Distribute spatial ZMP into foot CoPs in double support.

void lipm_walking::states::Standing::makeFootContact ( std::shared_ptr< mc_tasks::force::CoPTask >  footTask,
const Contact contact 
)

Make foot contact.

Parameters
footTaskStabilizer task corresponding to the foot to release.
contactContact target.

Definition at line 241 of file Standing.cpp.

void lipm_walking::states::Standing::makeLeftFootContact ( )

Make left foot contact.

Definition at line 256 of file Standing.cpp.

void lipm_walking::states::Standing::makeRightFootContact ( )

Make right foot contact.

Definition at line 261 of file Standing.cpp.

bool lipm_walking::states::Standing::releaseFootContact ( std::shared_ptr< mc_tasks::force::CoPTask >  footTask)

Release foot contact.

Parameters
footTaskStabilizer task corresponding to the foot to release.
Returns
True if the contact was released, false if not.

Definition at line 266 of file Standing.cpp.

void lipm_walking::states::Standing::releaseLeftFootContact ( )

Release left foot contact.

Definition at line 288 of file Standing.cpp.

void lipm_walking::states::Standing::releaseRightFootContact ( )

Release right foot contact.

Definition at line 296 of file Standing.cpp.

void lipm_walking::states::Standing::runState ( )
overridevirtual

Main state function, called if no transition at this cycle.

Implements lipm_walking::State.

Definition at line 156 of file Standing.cpp.

void lipm_walking::states::Standing::start ( )
overridevirtual

Start state.

Implements lipm_walking::State.

Definition at line 41 of file Standing.cpp.

void lipm_walking::states::Standing::startWalking ( )

Enable startWalking_ boolean and update GUI.

Definition at line 329 of file Standing.cpp.

void lipm_walking::states::Standing::teardown ( )
overridevirtual

Teardown state.

Implements lipm_walking::State.

Definition at line 131 of file Standing.cpp.

void lipm_walking::states::Standing::updatePlan ( const std::string &  name)
protected

Change footstep plan.

Parameters
nameNew plan name.

Definition at line 342 of file Standing.cpp.

void lipm_walking::states::Standing::updateTarget ( double  leftFootRatio)

Update target CoM and CoP.

Parameters
leftFootRatioLeft foot weight index between 0 and 1.

Definition at line 226 of file Standing.cpp.