1 Introduction

The first modern walking robot was developed over 40 years ago (Takanishi et al. 1985) and today most powered humanoids still follow the same design philosophy of using rigid actuated joints, coupled to controllers that regulate the zero moment point (ZMP) (Vukobratović et al. 2004). This design and control paradigm has formed the basis for the development of a variety of highly successful humanoids powered by electric motors, including the WL-10RD robot (Takanishi et al. 1985) which was an early example of a successful dynamic walker and later designs such as the series of Honda robots P2 (Hirai et al. 1998) and Asimo (Hirose et al. 2001), HRP2 to HRP4 (Kajita et al. 2010) developed by AIST, and the Wabian (Ogura et al. 2006) humanoid from Waseda University.

The ZMP based gait generation techniques developed in the past are mostly dedicated to bipeds with stiff joints. The ZMP concept can be used in different ways to generate dynamically stable gaits. Here we classify the utilization of ZMP criterion into two categories. In the first approach, which is particularly suited to use with traditional non-compliant robots, the ZMP is considered as a target reference. Starting from these target references, different numerical methods can be used to solve the ZMP equations to obtain the center of mass (COM) trajectory which satisfies the pre-set ZMP trajectory (Kagami et al. 2002). Alternatively, the ‘Preview Control’, which is a Linear Quadratic Integral (LQI) controller, can be used to solve the bipedal walking as a ZMP tracking problem (Kajita et al. 2003). Each of these walking pattern generators relies on ZMP trajectory planning, which can be created either off-line or on-line, together with a real-time stabilizer to counteract external disturbances (Kajita et al. 2010). However, when the disturbances are large, a high level controller is required to re-plan both the footholds and the ZMP trajectory (Morisawa et al. 2007). In the first approach mentioned above, the ZMP trajectory is typically designed to move from one foot center to another, thus the ZMP trajectory is predefined. The second approach considers the ZMP as an actuation signal. Using this principle, Sugihara (2009) and Mitobe et al. (2000) manipulated the ZMP to control the reaction force acting on the COM for generating the bipedal gaits. In this method, the ZMP trajectory has a wide variety and doesn’t necessarily stay in the foot center. Our method developed in this paper builds on the latter concept in which the ZMP is regarded as the control effort rather than a target reference, and combines with the extension of capture point which will be mentioned later.

ZMP tracking schemes require precise joint position tracking which is guaranteed in robots with stiff actuation and rigid links. However, the stiff actuation does make the system more susceptible to physical damage arising from the high impact forces generated during the ground contact. For some existing non-compliant humanoids, these high impact forces are reduced by introducing foot compliance. The Honda robots have rubber bushes/soles on feet as the passive compliance (Hirai et al. 1998; Takenaka et al. 2009). The WL-12 biped is equipped with a special foot mechanism for shock absorption (Yamaguchi et al. 1995). The new Petman robot has prosthetic feet made of carbon fibers. This work solves this issue at the actuation level by using the compliant actuators developed in Tsagarakis et al. (2009), Jafari et al. (2010), and Laffranchi et al. (2010).

Moreover, recent studies indicate the necessity to intrinsically include compliance in the robot system. The energy storage and reuse from the elastic element in Chobino1D robot improved the performance of hopping height, and moreover its stiffness profile resembled the leg stiffness similar to that found in human running and hopping (Vanderborght et al. 2009). The compliant legs can also demonstrate dynamic characteristics similar to those observed in human gait (Geyer et al. 2006). The work on passive dynamic walkers demonstrated that the exploitation of passivity and compliance of tendons can adapt to environmental discrepancies (Vaughan et al. 2004). The Pneumat-BS robot powered by pneumatic muscles showed that a compliant humanoid could perform successful dynamic walking (Narioka et al. 2009). In this paper, we emphasize the significance of the physical compliance in dynamic walking because the compliant components inherently provide protection against impacts or accidental collisions. Hence, intrinsically compliant legs are proposed for improving the performance in terms of impact absorption compared to the stiff leg systems developed in the past (Tsagarakis et al. 2007). For this purpose, the COmpliant huMANoid COMAN was developed in IIT (Tsagarakis et al. 2011) as an experimental platform. The compliant actuators at the knee and ankle sagittal joints of COMAN have a measured torsional stiffness of \(120\) Nm/rad. However, although intrinsic elasticity can bring benefits to the robot performance, it introduces oscillations and vibration modes that limit the control bandwidth and reduce the joint tracking precision.

Our previous work on generating a variety of gaits using ZMP tracking schemes (similar to those developed for stiff humanoids) had demonstrated the difficulty of applying the same ZMP tracking principle for the case of an intrinsically compliant humanoid (Li et al. 2010). This motivated our work on the development of new trajectory generation strategies. Inspired by the work in (Pratt and Tedrake 2006) which revealed that the COM position and velocity are suitable state variables, and the work in (Mitobe et al. 2000; Sugihara 2009) where the ZMP is the actuation signal, we extend the concept of capture point (Pratt et al. 2006) to formulate a new gait generation approach in which the horizontal components of the GRF are used to control the desired COM states. The deterioration of the COM motion caused by imprecise joint tracking is regarded as the disturbance to the COM states, which can be corrected by using the COM state feedback. Hence, the proposed method can generate effective walking while retaining the feature of impact reduction arising from the intrinsic compliance in the joints.

This paper is organized as follows. Section 2 presents the modeling and the methodology that consider the bipedal walking as the COM state tracking problem. Section 3 presents the principle of the lateral gait control. Section 4 describes the synchronization control used for generating the sagittal gait. In Sect. 5, the experimental results of different walking experiments from the real robot are analyzed. The discussion and conclusion are finally presented in Sect. 6.

2 Methodology of gait control based on com states tracking

The lower body of the COMAN robot has series elastic actuators in the knee and ankle flexion joints in each leg, as shown in Fig. 1. The details of the mechanical design and specifications of the robot can be found in Tsagarakis et al. (2011). This configuration of the compliant joints mainly introduces oscillation in the sagittal plane and with a smaller influence in the lateral plane through a coupling effect when the knees are bent (because compliance in two knees could create a differential leg force that results in a torque in the lateral plane). Based on the theory of small vibrations, we found that in the sagittal plane the lowest resonance frequency is \(1.18\) Hz in the single support phase and \(1.57\) Hz in the double support phase.

Fig. 1
figure 1

Kinematic and actuator configuration of COMAN

The capture point technique answers the question of where the robot should place its next foothold to completely come to a stop (Pratt et al. 2006). In other words, zero velocity above the new foothold. This approach is typically used for push recovery or restoring balance. However, we have discovered that this concept can be further extended by using a more general formula based on the linear inverted pendulum model (LIPM) to determine what the current velocity the robot should have if it needs to come to a stop at a target position other than the foothold center. In this case, the general formula could enable a gait transition for walking.

Denote by \(\lambda _{x},\, \lambda _{y} \, \lambda _{z}\), and \(\lambda _{s}\) the step length, step width, step height, and the amplitude of lateral sway, respectively. The LIPM (Kajita et al. 2001) is chosen for its analytical ability to predict a desired COM state in order to achieve a bounded cyclic motion in the lateral plane. Figure 2 illustrates our concept for obtaining lateral gait control. The support leg is assumed to switch instantaneously when the COM crosses the zero position in the \(y\) direction. Given the nominal foot support point \(\lambda _{y}\) and the magnitude of the sway motion \(\lambda _{s}\) where the COM has zero velocity, the LIPM provides an analytical solution to the desired COM velocity at the current position. Therefore, the GRF within the current support polygon can be used as the control effort to drive the COM velocity to the desired velocity reference so that the COM comes to a rest exactly at \(\lambda _{s}\). For bipedal walking, the change of the support leg forms two discrete potential apexes (Pratt and Drakunov 2007) as shown by the bottom graphs in Fig. 2. Consequently, the ZMP is the point where the resultant GRF intersects the polygon during the control process, and does not need to be tracked as a predefined reference.

Fig. 2
figure 2

LIPM predicts the desired velocity of a bounded cyclic motion given \(\lambda _{s}<\lambda _{y}\)

The above concept is a general methodology for a bounded cyclic motion control. By setting \(\lambda _{s}=\lambda _{y}\), the period of the cyclic motion becomes infinite thus it evolves to the capture point used for push recovery (Pratt et al. 2006), in which the COM stops exactly above the support point (the apex of potential energy). In Fig. 3, the red lines are the boundary states of the COM state, position and velocity, given the nominal support point \(\lambda _{y}\) as the capture point. So the state on the red line will eventually stops at the capture point \(\lambda _{y}\). The set of the COM states within these red lines in Fig. 3 are the bounded states which are controllable because the horizontal components of the GRF can be used to prevent the COM states from diverging. The distance between the COM state (\(y\),\(\dot{y}\)) and the red boundary indicates the stability margin similar to the concept proposed in Pratt and Tedrake (2006).

Fig. 3
figure 3

The COM states \((y,\dot{y})\) with respect to the red boundary indicates the stability margin

To effectively execute walking on a compliant humanoid, a trajectory generation control scheme must counteract the reduction in the joint tracking accuracy that is caused by the compliance in the joints. As the proposed method uses closed loop control of the COM states, any COM state error caused by the deterioration in the joint tracking can be minimized by the feedback controller. When the real COM state is disturbed from the desired one, the controller generates an on-line control output, which is the desired horizontal ground reaction force to drive the COM state back to the reference. Meanwhile, this reduced tracking performance has an advantage because it makes the robot more tolerant to external disturbances such as the terrain irregularity. To our understanding, to use the COM state of the robot for controlling balancing and walking is one of the correct approaches that combines the tolerance of the passive compliance together with a higher level control of the COM state.

ZMP is the point where the resultant GRF acts on the robot feet (Popovic 2005). It is strongly related to the foot-ground contact and the COM acceleration. Therefore, the feedback signal of the ZMP is usually noisy and has the characteristics of high frequency. Hence, the ZMP tracking scheme requires a high control bandwidth from the position controllers. In contrast, the COM velocity and position are the resultant state variables of applied forces thus they are the low frequency signals. Since most humanoid robots use position control of their actuators, the control bandwidth is typically limited, especially for compliant actuators since the elastic elements act as mechanical low-pass filters which further reduce the control bandwidth. Hence, the use of ZMP tracking is challenging for most position controlled robots especially for compliant robots. On the other hand, the bandwidth of the position controllers better matches the frequency characteristics of the COM states. Based on this knowledge, the proposed work might provide an insight into the control of bipedal gaits using the low-bandwidth compliant actuators.

3 Control of lateral motion

The robot is represented by a concentrated mass model. The LIPM is used for formulating the control references given the nominal center of pressure (COP) which is a constant point, while the real instantaneous COP varies within the support foot for applying the control effort. The vertical position of the COM is constant. The horizontal motion of the COM is subject to the resultant force and computed by numerical integration. As the translational dynamics of the COM are more dominant in normal walking gaits (Popovic 2005), this single mass model is considered as a reasonable approximation for a moderate walking speed in our generated gaits. We also assume that the GRF instantaneously shifts to the new support foot when the COM passes the zero position in the lateral plane. Denote by \(Q_{0}\) and \(Q_{f}\) the transition phases of start and stop. To formulate the control, the cyclic phase portrait of the lateral motion (\(y,\,\dot{y}\)) is divided into four phases, as shown in Fig.3, and defined as follows:

  1. 1.

    The 1st quadrant (\(Q_{1}\)): COM is on the left of the lateral plane and approaching the left foothold (\(y^{+}\), \(\dot{y}^{+}\));

  2. 2.

    The 4th quadrant (\(Q_{4}\)): COM is on the left of the lateral plane and leaving the left foothold (\(y^{+}\), \(\dot{y}^{-}\));

  3. 3.

    The 3rd quadrant (\(Q_{3}\)): COM is on the right of the lateral plane and approaching the right foothold (\(y^{-}\), \(\dot{y}^{-}\));

  4. 4.

    The 2nd quadrant (\(Q_{2}\)): COM is on the right of the lateral plane and departing the right foothold (\(y^{-}\), \(\dot{y}^{+}\)).

3.1 Formulation of velocity references

Lateral gait control aims to regulates the kinetic energy of the COM by controlling the COM velocity, so the robot could perform a cyclic motion between two footholds without falling. In Fig. 3, the blue line shows a desired stable COM state trajectory. The step width \(\lambda _{y}\) is the lateral distance of the foothold center, which is also the nominal COP of the current foothold. The nominal COM height is set as constant \(z_{c}\). The desired maximum sway distance \(\lambda _{s}\) is the position where the COM comes to a stop which indicates the stability level with respect to \(\lambda _{y}\). We set \(\lambda _{s}<\lambda _{y}\) to guarantee a stability margin such that the COM wouldn’t pass over the foothold and further diverge. LIPM is exploited to obtain an analytical solution for the on-line generation of the COM velocity reference. In the following cases, we consider only four different scenarios in the \(Q_{1}\) and \(Q_{4}\) phases, and the similar formulation can be derived for the \(Q_{2}\) and \(Q_{3}\) phases.

In the \(Q_{1}\) phase, when \(y<\lambda _{s}\), the GRF does the negative mechanical work and decelerates the COM, thus the kinetic energy is converted to the mechanical work. Therefore, given \(\lambda _{y}\) and \(z_{c}\), there exists a desired velocity \(V_{y}^{ref}\) with which the COM would stop exactly at \(\lambda _{s}\). The desired kinetic energy \(E_{k}^{d}\) determined by \(V_{y}^{ref}\) is totally converted to the mechanical work at \(\lambda _{s}\) during this deceleration period.

$$\begin{aligned}&E_{k}^{d}+W=0,\end{aligned}$$
(1)
$$\begin{aligned}&W=\frac{g}{2z_{c}}(\lambda _{s}^{2}-y^{2})- \frac{g}{z_{c}}\lambda _{y}(\lambda _{s}-y),\end{aligned}$$
(2)
$$\begin{aligned}&\frac{1}{2}(V_{y}^{ref})^{2} +\frac{g}{2z_{c}}(\lambda _{s}^{2}-y^{2}) -\frac{\lambda _{y}g}{z_{c}}(\lambda _{s}-y)=0,\end{aligned}$$
(3)
$$\begin{aligned}&V_{y}^{ref}=\sqrt{ 2\frac{g}{z_{c}}\lambda _{y}(\lambda _{s}-y)+\frac{g}{z_{c}}(y^{2} -\lambda _{s}^{2}) },y\le \lambda _{s}. \end{aligned}$$
(4)

Note that all the mechanical work and energy terms are normalized by the mass of the robot. In \(Q_{4}\) phase, when \(y<\lambda _{s}\) and \(\dot{y}<0\), the desired motion is a reversed trajectory compared to that in \(Q_{1}\), and a symmetrical negative velocity reference can thus be obtained.

$$\begin{aligned} V_{y}^{ref}=-\sqrt{ 2\frac{g}{z_{c}}\lambda _{y}(\lambda _{s}-y) +\frac{g}{z_{c}}(y^{2}-\lambda _{s}^{2})}. \end{aligned}$$
(5)

Substitute \(y=0\) into (4) and (5), the desired velocities \(\sqrt{\frac{g}{z_{c}}(2\lambda _{y}\lambda _{s}-\lambda _{s}^{2})}\) and \(-\sqrt{\frac{g}{z_{c}}(2\lambda _{y}\lambda _{s}-\lambda _{s}^{2})}\) are obtained for the COM to stop exactly at \(\lambda _{s}\) and \(-\lambda _{s}\) respectively while swicthing to the \(Q_{1}\) and \(Q_{3}\) phases.

Note that the real kinetic energy \(E_{k}\) may be larger or smaller than the ideal \(E_{k}^{d}\). In \(Q_{1}\), if \(E_{k}>E_{k}^{d}\), the case where \(\lambda _{s}<y<\lambda _{y}\) is possible. In this case, the velocity needs to be reduced to prevent the COM from overshooting the support foot and diverging from the foothold as this can eventually cause the robot to topple. To address this issue, a negative desired velocity \(V_{y}^{ref}\) is computed to force the COM to return to the desired sway point \(\lambda _{s}\).

$$\begin{aligned} E^{*}&= \frac{g}{z_{c}}\lambda _{y}(y-\lambda _{s})+\frac{g}{2z_{c}}(\lambda _{s}^{2} - y^{2}),y>\lambda _{s},\end{aligned}$$
(6)
$$\begin{aligned} V_{y}^{ref}&= -\sqrt{2E^{*}}. \end{aligned}$$
(7)

Similarly in the \(Q_{4}\) phase, when \(\lambda _{s}<y<\lambda _{y}\) and \(\dot{y}<0\), a positive reference velocity is formed to reduce the magnitude of the velocity in order to dissipate the excessive kinetic energy so as to avoid overshooting the desired velocity \(-\sqrt{\frac{g}{z_{c}}(2\lambda _{y}\lambda _{s}-\lambda _{s}^{2})}\),

$$\begin{aligned} V_{y}^{ref} = \sqrt{2E^{*}}. \end{aligned}$$
(8)

The formulation of the velocity control can now be defined for all phases. In the \(Q_{1}\) and \(Q_{4}\) phases,

$$\begin{aligned} V_{y}^{ref}\!=\! \left\{ \begin{array}{ll} sign(\dot{y})\sqrt{|2\frac{g}{z_{c}}\lambda _{y}(\lambda _{s}\!-\!y) \!+\!\frac{g}{z_{c}}(y^{2}\!-\!\lambda _{s}^{2})|}, \\ {y \le \lambda _{s}} ;\\ -sign(\dot{y})\sqrt{|2\frac{g}{z_{c}}\lambda _{y}(\lambda _{s}\!-\!y) \!+\!\frac{g}{z_{c}}(y^{2}\!-\!\lambda _{s}^{2})|}, \\ {y>\lambda _{s}}; \end{array} \right. \end{aligned}$$
(9)

and in the \(Q_{3}\) and \(Q_{2}\) phases.

$$\begin{aligned} V_{y}^{ref}\!=\! \left\{ \begin{array}{ll} sign(\dot{y})\sqrt{|\frac{g}{z_{c}}(\lambda _{s}^{2}\!-\!y^{2}) \!-\!2\frac{g}{z_{c}}\lambda _{y}(\lambda _{s}\!+\!y)|}, \\ {y \!\ge \! -\lambda _{s}}; \\ -sign(\dot{y})\sqrt{|\frac{g}{z_{c}}(\lambda _{s}^{2}\!-\!y^{2}) \!-\!2\frac{g}{z_{c}}\lambda _{y}(\lambda _{s}\!+\!y)|}, \\ {y< -\lambda _{s}}. \end{array} \right. \end{aligned}$$
(10)

Based on this approach, the kinetic energy can be regulated by controlling the velocity to maintain the stability. As shown in Fig. 4, the four velocity references form a closed basin in the phase portrait, which is the desired cyclic state of the lateral COM motion. In the \(Q_1\) phase when \(y\le \lambda _{s}\), if the state \((y, \dot{y})\) is inside or outside of the desired phase trajectory (case I and II in Fig. 4), the control effort drives the state back to the desired one. When \(y> \lambda _{s}\), the negative reference velocity is used to generate a control force to pull the state to the next phase \(Q_4\) (case III in Fig. 4). In the \(Q_4\) phase, where the COM is leaving the supporting leg, the motion is still controlled rather than falling passively due to gravity. In the phase \(Q_4\) (case IV in Fig. 4), if \(y>\lambda _{s}\), the velocity should be reduced, otherwise the kinetic energy would be larger than the ideal value \(\frac{g}{2 z_{c}}|\lambda _{y}\lambda _{s}-\lambda _{s}^{2}|\) while entering the next phase which results in an overshoot in the \(Q_3\) phase and an asymmetric shape for the phase portrait. Therefore, the positive reference velocity represented by the blue line in Fig. 4 (case IV), generates a control effort to decrease the velocity \(\dot{y}\). Theses control actions continuously attract the state of the COM to the desired state trajectory.

Fig. 4
figure 4

Desired velocity reference of each phase for lateral gait control

3.2 Control of lateral COM states

The reference velocity \(V_{y}^{ref}\) is regenerated at every control loop based on the COM state feedback \((y,\dot{y})\) according to (9) and (10). The control effort \(u\) is defined as the horizontal acceleration produced by the GRF. The kinetic energy is controlled by regulating the velocity given an updated reference \(V_{y}^{ref}\). By defining the velocity error as \(e_{y}=V_{y}^{ref}-\dot{y}\), the control effort \(u\) is hereby computed by a velocity controller,

$$\begin{aligned} u_{y}=K_{p1}^{y}e_{y}+K_{d1}^{y}\dot{e}_{y}. \end{aligned}$$
(11)

In the stop phase \(Q_{f}\), instead a position control is applied

$$\begin{aligned} u_{y}=K_{p2}^{y}(y_{ref}-y)-K_{d2}^{y}\dot{y}, \end{aligned}$$
(12)

where \(K_{p1}^{y},\, K_{p2}^{y}\) are the proportional gains and \(K_{d1}^{y},\, K_{d2}^{y}\) are the derivative gains for the velocity and position controllers respectively. In this paper we set \(y_{ref}=0\) in the stop phase.

The possible range of accelerations is not arbitrary but limited by the GRF which is constrained by the current support polygon since the robot cannot obtain unlimited force from the ground due to the finite size of the feet. Considering these physical constraints such as the step width \(\lambda _{y}\), the COP variation limits \(\Delta _{y}^{-}<0\) and \(\Delta _{y}^{+}>0\), and the nominal COM height \(z_{c}\), the desired output \(u_{y}^{d}\) constrained by the upper and lower acceleration limits can be determined as shown in Fig. 5. The deviations \(\Delta _{y}^{-}\) and \(\Delta _{y}^{+}\) are within the support feet. Given the initial condition \((y(0),\dot{y}(0))\) and sampling time \(T\), the next state of the COM is computed by the numerical integration based on the acceleration term \(u_{y}^{d}\) in (13) and (14).

Fig. 5
figure 5

The acceleration limit constrained by the support foot

For the \(Q_{1}\) and \(Q_{4}\) phases, namely the left leg single support phase, the desired output is

$$\begin{aligned} u_{y}^{d} = \left\{ \begin{array}{ll} u_{y}^{min}=\frac{y-(\lambda _{y}+\Delta _{y}^{+})}{z_{c}}g, u_{y} < u_{y}^{min}, \\ u_{y}, \text{ otherwise } \\ u_{y}^{max}=\frac{y-(\lambda _{y}+\Delta _{y}^{-})}{z_{c}}g, u_{y} > u_{y}^{max} .\\ \end{array} \right. \end{aligned}$$
(13)

For the \(Q_{2}\) and \(Q_{3}\) phases, namely the right leg single support phase, the desired output is

$$\begin{aligned} u_{y}^{d} = \left\{ \begin{array}{ll} u_{y}^{min}=\frac{y-(-\lambda _{y}+\Delta _{y}^{+})}{z_{c}}g, u_{y} < u_{y}^{min}, \\ u_{y}, \text{ otherwise } \\ u_{y}^{max}=\frac{y-(-\lambda _{y}+\Delta _{y}^{-})}{z_{c}}g, u_{y} > u_{y}^{max}. \\ \end{array} \right. \end{aligned}$$
(14)

4 Control of sagittal motion

The synchronization of the sagittal and the lateral motion is not an issue for the conventional ZMP tracking method, because \(x_{zmp}\) and \(y_{zmp}\) are predefined according to the same time-line, sharing the same transition instant. Since the velocity reference in our method is generated on-line using the COM state feedback, and the lateral COM position is modulated by the controllers, the timing of different walking phases is not predefined thus the gait cycle is not strictly a constant. Therefore, the sagittal walking needs to be specially controlled and synchronized with the lateral motion.

4.1 Formulation of sagittal walking parameters

Given the step length \(\lambda _{x}\) for the sagittal walking, the desired walking velocity can be calculated accordingly. Firstly the gait cycle is calculated from the lateral motion. Set \(\tau \) as the transition time from the middle position \((0,\dot{y}_{0})\) to the maximum sway position \((\lambda _{s},0)\) in the lateral plane. The LIPM model provides an analytical solution to calculate the time interval between these two transition states (Kajita et al. 2005). By substituting the lateral middle position \(y=0\) into (4), the initial velocity \(\dot{y}_{0}\) can be derived. Thus, the elapsed time from state \((0,\dot{y}_{0})\) to \((\lambda _{s},0)\) can be calculated.

$$\begin{aligned} \dot{y}_{0}&= \sqrt{2\frac{g}{z_{c}}\lambda _{y}\lambda _{s} - \frac{g}{z_{c}} \lambda _{s}^2},\end{aligned}$$
(15)
$$\begin{aligned} \tau&= T_{c}ln\frac{y_{0}+T_{c}\dot{y}_{0}}{y_{1}+T_{c}\dot{y}_{1}}, \end{aligned}$$
(16)

where \(T_{c}=\sqrt{z_{c}/g}\).

$$\begin{aligned} T_{cycle}&= 4\tau ,\end{aligned}$$
(17)
$$\begin{aligned} V_{x}^{ref}&= \frac{2\lambda _{x}}{T_{cycle}} . \end{aligned}$$
(18)

The detailed derivation of (16) can be found in Kajita et al. (2005). Note that \(\tau \) is one quarter of one complete gait, so the gait cycle \(T_{cycle}\) is calculated as \(4\tau \). The average walking velocity can be computed according to (18).

4.2 Control of sagittal COM states

Figure 6 illustrates the concept of the synchronization control of the lateral and the sagittal motion. The real COM position (black) is placed far from the desired trajectory to present a clearer visualization. The control law of the sagittal motion is explicitly described in (19). For the synchronization control, the lateral COM position \(y\) is firstly normalized by the desired sway \(\lambda _{s}\) then scaled by the step length \(\lambda _{x}\), and finally projected into the sagittal plane. This provides a phase mapping between the sagittal and the lateral COM position (red), as shown in Fig. 6. This mapping corresponds to the position control term in (19), where the desired position reference is a triangular trajectory. A low gain position control is used to prevents drifting of the sagittal motion. To track the desired velocity, a velocity controller is used. In (19), \(x\) is the COM position and \(x_{f}\) is the current support foot center. To initiate the entry into the first \(Q_{1}\) phase, a horizontal acceleration of approximately \(V_{x}^{ref}/\tau \) is produced by the horizontal component of the GRF to move the COM forward.

$$\begin{aligned} u_{x}= \left\{ \begin{array}{ll} \underbrace{K_{p1}^{x}[(\frac{|y|}{\lambda _{s}} \frac{\lambda _{x}}{2}-\frac{\lambda _{x}}{2}+x_{f})-x]}_ {\text{ position } \text{ control }}\\ +\underbrace{K_{v1}^{x}(V_{x}^{ref}-\dot{x})}_ {\text{ velocity } \text{ control }} ,\text{ when } \, {x \le x_{f};} \\ \underbrace{K_{p1}^{x}[(\frac{\lambda _{x}}{2}- \frac{|y|}{\lambda _{s}}\frac{\lambda _{x}}{2}+x_{f})-x]}_ {\text{ position } \text{ control }}\\ +\underbrace{K_{v1}^{x}(V_{x}^{ref}-\dot{x})}_ {\text{ velocity } \text{ control }},\text{ when } \, {x>x_{f}}, \end{array} \right. \end{aligned}$$
(19)

where \(K_{p1}^{x}\) and \(K_{v1}^{x}\) are the proportional gains for the position and velocity control.

Fig. 6
figure 6

Sagittal gait control

In the stop phase \(Q_{f}\), a position controller is used,

$$\begin{aligned} u_{x}=K_{p2}^{x} (x_{ref}-x)+K_{v2}^{x} \dot{x}, \end{aligned}$$
(20)

where \(K_{p2}^{x}\) and \(K_{v2}^{x}\) are the proportional and derivative gains, and \(x_{ref}\) is the mid point between two support feet. As with the lateral acceleration limit shown in Fig. 5, given the nominal COP \(x_{f}\) in the \(x\) coordinate, which is the current foothold center, and the boundary limits \(\Delta _{x}^{+}>0\) and \(\Delta _{x}^{-}<0\), the desired output \(u_{x}^{d}\) can be determined,

$$\begin{aligned} u_{x}^{d} = \left\{ \begin{array}{ll} u_{x}^{min}=\frac{x-(x_{f}+\Delta _{x}^{+})}{z_{c}}g, u_{x} < u_{x}^{min}, \\ u_{x}, \text{ otherwise } \\ u_{x}^{max}=\frac{x-(x_{f}+\Delta _{x}^{-})}{z_{c}}g, u_{x} > u_{x}^{max}. \\ \end{array} \right. \end{aligned}$$
(21)

4.3 Foot trajectory planning

The foot position of the stance leg \((x_{f}(i),y_{f}(i),z_{f}(i))\) at the time \(i T\) remain the same as \((x_{f}(i-1),y_{f}(i-1),z_{f}(i-1))\). The \(5\)th order polynomial function is used to generate smooth foot trajectories with continuous boundary conditions for the acceleration, velocity, and position. Let \(F :N^{9}\rightarrow R^{1}\) be the polynomial function with nine inputs and one output. For the swing foot,

$$\begin{aligned} x_{f}=F (X^{8},i T); \, y_{f}=\lambda _{y} \, \text{ or }-\lambda _{y}; \, z_{f}=F (Z^{8},i T), \end{aligned}$$
(22)

where \(X^{8}\) and \(Z^{8}\) contains \(8\) variables for the position, velocity, acceleration and time at the beginning and the end of the interpolation.

$$\begin{aligned}&X^{8}=\left\{ \begin{array}{llll} \ddot{x}_{0}=0, \dot{x}_{0}=0, x_{0}=x_{j-1}^{s},t_{0}=t_{j-1}^{s},\\ \ddot{x}_{f}=0, \dot{x}_{f}=0, x_{f}=x_{j-1}^{s}+2\lambda _{x},\\ t_{f}=t_{0}+\frac{T_{cycle}}{2},\text{ for } \, Q_{1}, Q_{3};\\ \ddot{x}_{0}=\ddot{x}_{j}^{s}, \dot{x}_{0}=\dot{x}_{j}^{s}, x_{0}=x_{j}^{s}, t_{0}=t_{j}^{s},\\ \ddot{x}_{f}=0, \dot{x}_{f}=0, x_{f}=x_{j}^{s}+\lambda _{x},\\ t_{f}=t_{j}^{s}+(t_{j}^{s}-t_{j-1}^{s}), \text{ for } \, Q_{2}, Q_{4}. \end{array}\right. \end{aligned}$$
(23)
$$\begin{aligned}&Z^{8}=\left\{ \begin{array}{llll} \ddot{z}_{0}=0, \dot{z}_{0}=0, z_{0}=z_{ankle},t_{0}=t_{j-1}^{s},\\ \ddot{z}_{f}=0, \dot{z}_{f}=0, z_{f}=z_{ankle}+\lambda _{z},\\ t_{f}=t_{0}+\frac{T_{cycle}}{2},\text{ for } \, Q_{1}, Q_{3};\\ \ddot{z}_{0}=\ddot{z}_{j}^{s}, \dot{z}_{0}=\dot{z}_{j}^{s}, z_{0}=z_{j}^{s}, t_{0}=t_{j}^{s},\\ \ddot{z}_{f}=0, \dot{z}_{f}=0, z_{f}=z_{ankle}\\ t_{f}=t_{j}^{s}+(t_{j}^{s}-t_{j-1}^{s}), \text{ for } \, Q_{2}, Q_{4}. \end{array} \right. \end{aligned}$$
(24)

\(\lambda _{z}\) is the maximum swing foot height of the ankle. For each leg, the controller stores the previous and the current foot position, \(x_{j-1}^{s}\) and \(x_{j}^{s}\) respectively when the phase \(Q\) switches at the time instants \(t_{j-1}^{s}\) and \(t_{j}^{s}\). In the \(Q_{1}\) and \(Q_{3}\) phases, the controller uses the half gait cycle \(T_{cycle}/2\) to estimate the first half of swing duration. In the \(Q_{2}\) and \(Q_{4}\) phases, the controller records the first half of the real swing duration \((t_{j}^{s}-t_{j-1}^{s})\) to estimate the second half.

Based on the position trajectories of the COM and feet, the orientation of the pelvis and feet was set to be parallel to the level ground. Conventional inverse kinematics based on the pelvis and feet positions and the forward kinematics are used iteratively as a numerical solution to obtain the COM based inverse kinematics (Li et al. 2012). The hip position is iteratively modified in proportion to the COM error calculated by the forward kinematics. The final updated joint angles are sent to the PID position controllers on the joints. Fig. 7 shows the overall control scheme. For the on-line trajectory generator, the estimate of COM position was computed by the forward kinematics with respect to the stance foot based on the absolute link position (after the compliant elements), assuming that the support foot conforms to the ground surface. The COM velocity was computed from the filtered COM position estimations.

Fig. 7
figure 7

Overall control scheme of trajectory generation

4.4 Finite state machine

Figure 8 shows the finite state machine used for monitoring the COM phases and coordinating the control actions. Its functionality is similar to that in Raibert and Hodgins (1991). Starting from the equilibrium, the control law is applied according to (9), (10), (11), and (19). During the \(Q_{0}\) phase, the gait is initiated and the COM starts to enter the desired cyclic gait. The controller switches to \(Q_{1}\) once the real COM velocity is equal or greater than the desired reference \(V_{y}^{ref}\). The switching between phases \(Q_{1-4}\) depends on the state \((y,\dot{y})\) as defined in Sect. 3. When the stop command is triggered, the state machine starts to check the upcoming state. Once \(y\approx 0\) is detected, the robot starts to slow down in two stages. Initially, the robot starts to slow down in one step by shortening the step length to a half of the previous value, thus the reference velocity is reduced to a half according to (18). Finally, it enters the double support phase and further decelerates until it stops completely using the position control (12) and (20).

Fig. 8
figure 8

Finite state machine

5 Experimental results

To validate the proposed walking pattern generator, the following experiments were carried out with sensory data acquisition for quantitative analysis using the COMAN robot as a testbed.

  1. 1.

    Walking with a constant gait frequency and step length to verify the feasibility of the trajectory generator.

  2. 2.

    Walking with a time-varying gait frequency and step length to examine the flexibility of the trajectory generator.

  3. 3.

    Walking in the presence of an unexpected load to evaluate the robustness.

To obtain a precise measurement of the walking motion, the ‘Vicon Nexus’ motion capture system was used to record the waist, hip and feet positions with respect to a fixed world coordinate. Figure 9 shows the setup where four markers located at the waist joint were used to compute the torso orientation, two markers located at left and right hip were used to calculate the global position of pelvis center. Markers on the left and right ankles tracked the feet trajectories during walking. The global position and orientation of the waist were combined with the absolute link position measurement to compute the global COM position of COMAN. Hence the performance of the COM state tracking can be evaluated.

Fig. 9
figure 9

Experimental setup of COMAN and the display of motion tracking markers

5.1 Walking experiments

In the first experiment, the gait frequency was \(0.79\) Hz (\(T_{cycle}=1.27\) s) and the robot performed 10 normal walking steps. Figure 10 shows the desired COM and foot trajectories from the trajectory generator, and Fig. 11 shows the real trajectories from the experimental data. In Fig. 11, it can be seen that the real trajectories of the sagittal COM \(x_{com}\) and hip \(x_{hip}\) had certain fluctuation during walking and especially during the stop phase. These passive oscillations were caused by the intrinsic physical compliance. The lateral (hip/ankle roll) joints have no springs and only the knee compliance has insignificant coupling on the lateral motion, so less oscillation is observed as in the stop phase since \(8s\) in Fig. 11. In Fig.  12, the step length exhibits variations due to the joint position errors caused by the physical elasticities. Thereby, the measured walking velocity has oscillations compared with the desired one.

Fig. 10
figure 10

Desired position trajectories

Fig. 11
figure 11

Measured position trajectories

Fig. 12
figure 12

Desired (red) and measured (blue) step length \(\lambda _{x}\) and the walking velocity \(\dot{x}_{com}\)

Figure 13 shows the GRF measured in the right foot during a number of walking cycles. The convention of local axes of the F/T sensor are parallel to the global coordinate. No impulsive collision forces were observed during foot-ground interaction. The vertical GRF measured in left foot is also included in order to show the transition of foot-ground contact. Figure 14 shows no impulsive torque measurement in each joint. It is believed that this is due to the inherent compliance in the robot.

Fig. 13
figure 13

The measured ground reaction force at the gait frequency \(0.79\) Hz

Fig. 14
figure 14

The joint torque measured from the right leg with the gait frequency \(0.79\) Hz

In the second experiment, both the gait frequency and the step length were modified on-line. Figure 15 shows the modification of the lateral sway amplitude \(\lambda _{s}\) and its corresponding gait frequency. A larger amplitude corresponds to a lower gait frequency. The sway distance \(\lambda _{s}\) increased from \(0.04\) to \(0.042\) m (frequency \(0.78\) Hz) during \(14\)\(17\) s, then decreased to \(0.03\) m (frequency \(1.06\) Hz) during \(71\)\(86\) s, and finally remained constant at \(0.039\) m. The gait frequency \(1.06\)  is the highest frequency that allows an arbitrary modification of both gait frequency and step length before reaching the resonance frequency. For a higher gait frequency, the stiffness of the elastic elements need to be increased in order to minimize the discrepancy between the real robot and the simplified model.

Fig. 15
figure 15

Variable sway amplitude \(\lambda _{s}\) and gait frequency

Figure 16 shows the desired and measured lateral COM position during the whole gait period and the enlarged time scale figures show details at different gait frequencies within \(5\)s time window. In Fig. 16, the top graphs show the COM position tracking at the low (top left) and the high (top right) gait frequency (refer to the corresponding frequencies in Fig. 15). It shows that the lateral COM position tracking at low frequencies is reasonable, and as the gait frequency increases the tracking performance decreases. The average position tracking errors were calculated with respect to time during the whole gait period. To have a better average precision, a walking experiment lasting \(110\) s was carried out.

Fig. 16
figure 16

Desired (red) and measured (blue) lateral COM position. Average position error \(-7.4\)to \(6.9\) mm

Figure 17 shows the desired and measured lateral COM velocity with respect to the data in Fig.16. The enlarged time scale graphs on the top show the COM velocity tracking performance at the low and the high gait frequency respectively. The velocity spikes around the peaks and valleys were caused by the ground impacts of the swing foot. When the robot was entering a double support phase, the landing foot collided with the ground and rapidly reduced the velocity. If the collision were inelastic, this would cause the loss of velocity thus the gait would be terminated. However, due to the elasticity in both legs, the collision caused an oscillatory motion and the weight transfer between two legs. The energy stored in the springs of the support leg was released in the post-collision phase, hence there was a fast boost-up after the velocity reduction in the top graphs in Fig.17. This feature is also observed in the GRF measurement which will be explained more explicitly in the following subsection.

Fig. 17
figure 17

Desired (red) and measured (blue) lateral COM velocity. Average velocity error \(-0.0577\) to \(0.0638\) m/s

Figure 18 shows both the desired and the measured step length and the walking velocity during the on-line modification of gait parameters. Despite the overall envelope of measured step length matches the desired one, it doesn’t coincide perfectly at each step. The observed variation is the direct consequence of the presence of compliance. The robot has certain oscillations during walking in the sagittal plane due to the compliant joints in ankles and knees, which decrease the precision of foothold placement. The oscillation is also observed from the fluctuation in the COM velocity \(\dot{x}_{com}\).

Fig. 18
figure 18

Desired (red) and measured (blue) step length and sagittal COM velocity \(\dot{x}_{com}\) with variable gait parameters

To sum up, given fixed control gains, the second experiment validates that the proposed pattern generator allows an arbitrary gait frequency within \([0.78,1.06]\) Hz and the step length within \([0,0.05]\) m to be modified on-line while still maintaining a stable walk. To increase the range of gait parameters, an on-line gain scheduling algorithm needs to be investigated in the future study. Further improvement in the performance will also require the real-time feedback of the COM state estimation based on the link position combined with the orientation measurement from an inertia measurement unit (IMU).

The third experiment examines the robustness of the trajectory generator in response to external disturbances. In order to quantify in a simpler manner, loading an extra weight during walking was chosen as the disturbance. The robot was able to continue walking in the presence of a maximum load of \(1.7\) kg, which corresponds to approximately \(9.4\) % of the robot weight (\(18.1\)) kg. Snapshots of the experiment are shown in Fig. 19, and the action of disturbance is highlighted by red circles. Fig. 20 shows the vertical GRF before and after loading the weight from a number of stable walking cycles, starting from the touch-down of the right foot.

Fig. 19
figure 19

Walking under load disturbance with gait frequency \(0.7\) Hz

Fig. 20
figure 20

Vertical GRF with and without loaded weight

Figure 21 shows the experiment of COMAN’s stepping on an obstacle with \(1\) cm thickness, placing under the front and rear foot of the robot respectively. The obstacle is highlighted by a red rectangle in order to be distinguished clearly. Fig. 21a, b show the snapshots of adapting to the obstacle, and Fig. 21c, d show the close view of the detailed motion. To a certain extent, the intrinsic compliance could contribute to the adaptation to the small irregularity of the ground. Undoubtedly, when the size of the obstacle increases more, additional controller needs to be used.

Fig. 21
figure 21

Stepping on an obstacle with \(1\) cm thickness

Figure 22 illustrates real applications of the proposed algorithm in controlling the walking of the full body COMAN robot in addition to the presented experiments. Figure 22a shows COMAN’s walking with a step length of \(12cm\) . The turning function can be realized by superimpose the yaw motion of the support foot during single support phase, as shown in Fig. 22b.

Fig. 22
figure 22

Implementation of the COM state based pattern generator on full body COMAN

5.2 Effect of compliance

The main resonance exists in the sagittal plane where the compliant joints are configured. The main resonance frequencies are \(1.18\) Hz in the single support phase and \(1.57\) Hz in the double support phase. It is found that when the walking frequency is close to the resonance, the oscillation in the sagittal plane augments and makes the gait unstable. Therefore, the highest walking frequency achieved with a stable gait is \(1.06\) Hz in this paper.

Apart from the resonance, the passive compliance in leg also introduces the foot clearance issue. By comparing the desired and the measured vertical feet trajectories in Fig. 10 and 11, it can be seen that the real height of the swing foot was lower than expected. This can also be detected from the contact force measurement from swing foot that a reduction of vertical GRF appeared during \(1.15\)\(1.41\) s in Fig. 20 and during \(1.05\)\(1.28\) s in Fig. 13, which indicates an early foot landing.

During the early landing collision, the weight of the robot was temporarily transferred to the new contact leg so the GRF of the old stance leg reduces, as seen from \(0.4\) to \(0.62\) s in Fig.  13 as well as from \(0.43\) to \(0.66\) s in Fig. 20. By comparing the vertical GRF from both feet from \(0.4\) to \(0.62\) s in Fig. 13, it can be understood that the compliance in both legs created an oscillatory behavior during the collision. The new landing leg firstly stored the elastic energy then released this back, and the weight of the robot was transferred back to the old stance leg.

This issue is caused by two reasons. One reason is that there is compliance at the COM level which results in a lower hip and COM height in single support phase, and the real height of the swing foot also becomes lower. The worsened foot clearance is shown from experimental data. Hence, the swing foot lifts not as high as it should be and touches the ground earlier, which consequently causes an earlier landing problem. This can be resolved by modeling the compliance at the COM level, the “Internal Model Control” reported in Colasanto et al. (2012) can be adopted for compensating the COM error for improving gait performance. Or alternatively, develop a low level joint controller that uses the link states to regulate the effect of intrinsic compliance.

The other reason is that a flat-footed swing trajectory is fundamentally sensitive to small discrepancies between the ideal planning and the real situation. In the proposed gait generator, the foot trajectory planning designs the orientation of the stance and swing feet to be parallel to the ground. As the displacement between the COM and ankle becomes larger, the torque exerted by the gravity increases. In our case, the compliance in ankle particularly leads the whole body to rotate around the stance foot during the post-swing phase when the step length increases. With soft springs, as shown in Fig. 23, the compliant ankle will ultimately cause the swing foot to land by its toe, which produces a large and undesired ground reaction force that makes the walking gait unstable. Even for a stiff humanoid, as reported in Buschmann (2010), a flat-footed trajectory has this unavoidable disadvantage of toe landing issue at the initial contact by the swing foot. This limitation coming from foot trajectory planning could occur in both stiff and compliant robots because the discrepancy can be either the joint tracking error or the unknown unevenness of the ground. Therefore, to achieve a larger step length using the proposed gait generator, new effort should be made in developing a robust foot trajectory planning as suggested in Buschmann (2010).

Fig. 23
figure 23

Foot clearance issue introduced by the compliance

Despite all that, the compliance does introduce important benefits to stability through the ability to reject unmodelled impacts and unexpected collisions. This is shown by the lack of large impacts forces during the collision between the landing foot and the ground, as shown in Fig. 13 and 20. The joint torque measurement starting from the touch-down of the right foot also shows no torque saturation nor large torque spikes, as depicted in Fig. 14.

5.3 Analysis of COM and ZMP Signals

The control bandwidth of the ankle flexion, knee and hip flexion joints are \(1.98,\, 1.89\) and \(1.53\) Hz respectively in the double support phase, and \(1.15,\, 0.95\) and \(1.58\) Hz respectively for the support leg in the single support phase. In order to verify our hypothesis regarding the different characteristics in the frequency domain, we conducted a frequency analysis of the ZMP and COM signal. The ZMP position was calculated from the measurements of the 6 DOF F/T sensor mounted underneath the ankle. Without losing the generality regarding other walking gaits performed by the proposed method, the data from the second experiment were analyzed as an example. Figure 24 plots the power spectrum normalized by the peak magnitude. The dominant power spectrum center of the COM is \(0.78\) Hz. In contrast, the dominant power spectrum center of the ZMP is \(2.4\) Hz, which is around \(3\) times higher than that in the COM spectrum.

Fig. 24
figure 24

Power spectrum of lateral ZMP and COM position signals

The analysis of the power spectrum suggests that the tracking control of the ZMP and the COM methods place different requirements on the control bandwidth. Since the intrinsic compliance in the joints of a robot such as those in COMAN limits the bandwidth of actuation, it is advisable to choose the COM tracking scheme as a more suitable approach for effectively performing bipedal walking for a humanoid equipped with compliant actuation.

6 Discussions and conclusions

We proposed a walking pattern generation method for the humanoid with intrinsic joint compliance. The purpose was to use the benefits of compliance in terms of impact reduction and to combine this with a suitable trajectory generation to permit effective walking.

The proposed pattern generator computes the desired references for the lateral gait and the synchronized sagittal gait based on COM states feedback. The performance of the trajectory generator was experimentally validated on the COMAN robot. It was demonstrated that the proposed method allows the intrinsically compliant humanoid to perform stable gaits with variable step length and gait frequency, and provides adequate tolerance to a load variation of \(9.4\) % of the total weight. The force data measured from feet exhibits no large force spikes confirming the achieved walking robustness. The examination of the frequency analysis of the ZMP and COM on the performed gaits suggests a better suitability of the COM based generator and the control methodology for the systems with low actuation bandwidth such as those created by using inherently elastic joints.

The benefits of compliance were shown by the experimental data. Figure 21 demonstrated an adaptation to an uneven terrain surface by stepping on a plate of \(1\) cm thickness. Figure 13 and 14 illustrated the gradual transitions of GRF and joint torque during walking. The trade-off is that the inclusion of the physical elasticity makes the modeling and control more complex. A negative effect is the low bandwidth and the reduced joint tracking performance at high frequencies. As a result, conventional gait generators developed for stiff humanoids with high precision tracking are not sufficient for this new generation of compliant humanoids.

The effect of compliance in walking is also analyzed in Sect. 5. Both the advantages and drawbacks are discussed. The essential aspect needs to be concerned is the resonance introduced by elastic elements, which strongly suggests a future study of a systematic selection of spring stiffness for different joints in order to identify the resonance frequencies of the robot, especially in different walking phases. Only in this way could the compliance be altered and better utilized according to the purpose of the task such as reducing impact and avoiding resonance at the same time. The theoretical and experimental investigation in this paper may shed some light on the future development of compliant humanoids.