BipedalLocomotion::Contacts::ContactDetector class

Base classes

template<class Output>
class BipedalLocomotion::System::Source<EstimatedContactList>
Source is a template specialization of Advanceable and represents a block that does not contains input.

Derived classes

class FixedFootDetector
The FixedFootDetector is a class that can be used to find the fixed foot given a sequence of contacts.
class SchmittTriggerDetector
Schmitt Trigger thresholding based contact detector that maintains and updates the contact states for a prescribed set of contacts.

Constructors, destructors, conversion operators

~ContactDetector() defaulted virtual

Public functions

auto isOutputValid() const -> bool final
Determines the validity of the object retrieved with get()
auto getOutput() const -> const EstimatedContactList& final
Get contact states.
auto resetContacts() -> bool
Reset the internal contact states of the detector to false.
auto get(const std::string& contactName, Contacts::EstimatedContact& contact) const -> bool
Get state of specific contact.
auto get(const std::string& contactName) const -> Contacts::EstimatedContact
Get state of specific contact.

Protected types

enum class State { NotInitialized, Initialized, Running }
Enumerator used to determine the running state of the estimator.

Protected variables

State m_detectorState
State of the estimator.
EstimatedContactList m_contactStates

Enum documentation

enum class BipedalLocomotion::Contacts::ContactDetector::State protected

Enumerator used to determine the running state of the estimator.

Enumerators
NotInitialized

The estimator is not initialized yet call ContactDetector::initialze method to initialize it.

Initialized

The estimator is initialized and ready to be used.

Running

The estimator is running.

Function documentation

bool BipedalLocomotion::Contacts::ContactDetector::isOutputValid() const final

Determines the validity of the object retrieved with get()

Returns True in case of success, false otherwise.

const EstimatedContactList& BipedalLocomotion::Contacts::ContactDetector::getOutput() const final

Get contact states.

Returns container of contacts

bool BipedalLocomotion::Contacts::ContactDetector::resetContacts()

Reset the internal contact states of the detector to false.

Returns True in case of success, false otherwise.

bool BipedalLocomotion::Contacts::ContactDetector::get(const std::string& contactName, Contacts::EstimatedContact& contact) const

Get state of specific contact.

Parameters
contactName in name of contact
contact out estimated contact
Returns true if contact exists, false otherwise

Contacts::EstimatedContact BipedalLocomotion::Contacts::ContactDetector::get(const std::string& contactName) const

Get state of specific contact.

Parameters
contactName in name of contact
Returns contact state if contact exists, a dummy contact otherwise