Public Member Functions | Public Attributes | List of all members
foot_steps.FootSteps Class Reference
Inheritance diagram for foot_steps.FootSteps:
Inheritance graph
[legend]

Public Member Functions

def __init__ (self, right, left)
 
def add_phase (self, duration, foot, position=None)
 
def get_index_from_time (self, t)
 
def get_left_next_position (self, t)
 
def get_left_position (self, t)
 
def get_phase_duration (self, t)
 
def get_phase_remaining (self, t)
 
def get_phase_start (self, t)
 
def get_phase_type (self, t)
 
def get_right_next_position (self, t)
 
def get_right_position (self, t)
 
def is_double_from_left_to_right (self, t)
 

Public Attributes

 flying_foot
 
 left
 
 right
 
 time
 

Detailed Description

The class stores three functions of time: left, right and flying_foot.
Each function is piecewise constant. For each function, the user can ask
what is the value of this function at time t.

The storage is composed of three lists for left, right and flying_foot, and a list for time.
The list of times stores the time intervals, i.e. each element of the list is
the start of a time interval. The first element of the list is 0.
The value of the functions left, right, flying_foot one this time interval is stored at
the same position is their respective list (i.e. value of left on interval
[time[i], time[i+1]] is stored in left[i].

The 4 lists are set up using function add_phase().
The values of functions left, right, flying_foot can be accessed through the function
get_phase_type(t), get_left_position(t), get_right_position(t).
phase_type are 'left' (meaning left foot is flying, right foot is fixed), 'right' (ie the opposite)
or 'none' (meaning no foot is flying, both are fixed on the ground).

Additionnally, functions get_left_next_position(t),
get_right_next_position(t) can be used to get the next position of the
flying foot (in that case, additional work is needed to compute the
position of flying foot at time t by interpolating get_left_position(t)
and get_left_next_position(t).

Functions get_phase_start(t), get_phase_duration(t) and get_phase_remaining(t)
can be used to get the starting time, the duration and the remaining time of the
current phase at time t.

Definition at line 1 of file foot_steps.py.

Constructor & Destructor Documentation

def foot_steps.FootSteps.__init__ (   self,
  right,
  left 
)
The class is initiated from the initial positions of left and right feet.

Definition at line 31 of file foot_steps.py.

Member Function Documentation

def foot_steps.FootSteps.add_phase (   self,
  duration,
  foot,
  position = None 
)
Add a phase lasting <duration> where the flyhing foot <foot> (either 'left' or 'right')
moves to <position> (being a vector or a SE3 placement).
Alternatively, <foot> might be set to 'none' (i.e double support). In that case, <position>
is not specified (or is set to None, default).

Definition at line 40 of file foot_steps.py.

def foot_steps.FootSteps.get_index_from_time (   self,
  t 
)
Return the index i of the interval containing t, i.e. t in time[i], time[i+1] 

Definition at line 57 of file foot_steps.py.

def foot_steps.FootSteps.get_left_next_position (   self,
  t 
)

Definition at line 82 of file foot_steps.py.

def foot_steps.FootSteps.get_left_position (   self,
  t 
)

Definition at line 76 of file foot_steps.py.

def foot_steps.FootSteps.get_phase_duration (   self,
  t 
)

Definition at line 95 of file foot_steps.py.

def foot_steps.FootSteps.get_phase_remaining (   self,
  t 
)

Definition at line 99 of file foot_steps.py.

def foot_steps.FootSteps.get_phase_start (   self,
  t 
)

Definition at line 92 of file foot_steps.py.

def foot_steps.FootSteps.get_phase_type (   self,
  t 
)

Definition at line 63 of file foot_steps.py.

def foot_steps.FootSteps.get_right_next_position (   self,
  t 
)

Definition at line 87 of file foot_steps.py.

def foot_steps.FootSteps.get_right_position (   self,
  t 
)

Definition at line 79 of file foot_steps.py.

def foot_steps.FootSteps.is_double_from_left_to_right (   self,
  t 
)
Suppose that phase at time <t> is a double support phase.
Return True if the previous phase is left and/or the next phase is right.

Definition at line 67 of file foot_steps.py.

Member Data Documentation

foot_steps.FootSteps.flying_foot

Definition at line 38 of file foot_steps.py.

foot_steps.FootSteps.left

Definition at line 36 of file foot_steps.py.

foot_steps.FootSteps.right

Definition at line 35 of file foot_steps.py.

foot_steps.FootSteps.time

Definition at line 37 of file foot_steps.py.


The documentation for this class was generated from the following file:


pinocchio
Author(s):
autogenerated on Tue Jun 1 2021 02:45:05