**3. Low-level intelligent nonlinear controller**

In this subsection, a position controller is developed based on the general model using the backstepping technique and new adaptation laws. The dynamics Eq. (1) can be splitted for low-level subsystems under the following state-space form:

$$\begin{cases}
\dot{\varkappa}\_1 = \varkappa\_2 + v\\\dot{\varkappa}\_2 = -a\_1\varkappa\_2 + a\_2u + d
\end{cases} \tag{2}$$

where *<sup>x</sup>*<sup>1</sup> <sup>¼</sup> **<sup>q</sup>***<sup>i</sup>*∣*i*¼1*::<sup>n</sup>* presents a specific joint angle, *<sup>x</sup>*<sup>2</sup> is the measurement joint velocity, *u* ¼ **τ***<sup>i</sup>*∣*i*¼1*::<sup>n</sup>* is the control torque at the specific joint, *υ* is the measurement noise, *a1* is a positive constant presenting the nominal dynamics, *a2* is another positive constant standing for the inverse nominal mass at low-level dynamics, and *d* is the lumped disturbance denoting the deviation of internal dynamics. Note that, *x*<sup>1</sup> and *x*<sup>2</sup> hold for the following assumptions:

*Assumption 1*:

extended studies noted that the outstanding control performances are difficult to be preserved with hard control gains employed in diverse real-time operations [18, 19]. As a result, gain-learning SMC algorithms have been developed for robotic systems [18–21]. The control objective could be minimized by learning processes of robust gains, driving gains or massive gains [22, 23]. In fact, some control gains still need to manually tune for their possibly wide ranges due to nature of each control

Intelligent methods for automatically tuning all the control gains have been also proposed based on modified backtracking search algorithms (MBSA) combining with a Type-2 fuzzy-logic design [24] or model predictive approaches [25]. The desired gains could be estimated for the best performance by dealing with closedloop optimal constraints. Though promising control results were presented, smooth

Gain-learning control approaches under backstepping design provided another interesting direction as well. PID control with a gain-varying technique encoded by the backstepping scheme was formerly studied [26]. Success of the creative control method was confirmed by a thorough theoretical proof and experimental validation results. Since the learning process of all the control gain is generated only by one damping function, versatility of the control design may be limited for diverse working conditions. Improvement on the flexibility of gain selection is thus still an open issue. In this chapter, an extensive gain-adaptive nonlinear control approach is presented for high-performance motion control of a low-level servo system. The controller is comprised of an inner robust nonlinear loop and an outer gain-learning loop. The inner loop is developed based on a RISE-modified backstepping framework to ensure asymptotic tracking control in the existence of nonlinear uncertainties and disturbances. The second loop contains a new gain-adaptive engine to activate variation gains of the inner loop in real-time applications. Theoretical effectiveness of the proposed controller is concretely proven by Lyapunov-based analyses. Feasibility of the control approach was confirmed by intensive real-time experiments on a legged

General dynamics of a robotic system could be expressed in the following form:

where **q**, **q**\_ , **q**€ ∈ ℜ*<sup>n</sup>* are respectively the joint position, velocity and acceleration vectors, **M q**ð Þ<sup>∈</sup> <sup>ℜ</sup>*<sup>n</sup>*�*<sup>n</sup>*is the inertia matrix, **C q**ð Þ , **<sup>q</sup>**\_ <sup>∈</sup> <sup>ℜ</sup>*<sup>n</sup>*�*<sup>n</sup>*is the Centrifugal/Coriolis matrix, **g q**ð Þ<sup>∈</sup> <sup>ℜ</sup>*<sup>n</sup>*denotes the gravitational torque, **<sup>τ</sup>***fr*ð Þ **<sup>q</sup>**\_ <sup>∈</sup> <sup>ℜ</sup>*<sup>n</sup>* is the frictional

The main control objective here is to find out a proper control signal **τ** that ensures a control error between the system output and a desired profile stabilizing

as Proportional-Integral-Derivative (PID) and Sliding mode control (SMC) methods are priority selections in industry thanks to their simplicity and robustness. However, such the mission in humanoid robots is a different story in which

unpredictable disturbances [27, 28]. Obviously, the required controller is strong

the systems frequently operate in unknown environments with harshly

To realize the control objective, conventional linear or nonlinear controllers such

*<sup>T</sup>* is the respective Jacobian matrix, **f***ext* is the external disturbance, and **τ** is

*<sup>T</sup>***f***ext* <sup>¼</sup> **<sup>τ</sup>** (1)

**M q**ð Þ**q**€ þ **C q**ð Þ , **q**\_ **q**\_ þ **g q**ð Þþ **τ***fr*ð Þþ **q**\_ **J**

plant. Thus, it may lead to inconvenience during the operation.

*Collaborative and Humanoid Robots*

variation of the gain dynamics need to further consideration.

robot. Their features are presented in detail in the below sections.

**2. Problem statements**

control torque at robot joints.

at origin under various complicated environments.

robustness, fast adaptation, and easy implementation.

torque, **J**

**38**


#### **3.1 Robust backstepping control scheme**

Let formulate the main control error as:

$$
\varkappa\_1 = \varkappa\_1 - \varkappa\_{1d} \tag{3}
$$

where *x*1*<sup>d</sup>* is the desired trajectory of the controlled joint. Before designing the final control signal, additional assumptions are given. *Assumption 2*:


The time derivative of the control objective *e1* in considering the first equation of dynamics Eq. (2) is:

$$
\dot{\varkappa}\_1 = \varkappa\_2 + \nu - \dot{\varkappa}\_{1d} \tag{4}
$$

To control the error *e*<sup>1</sup> to zero or to be as small as possible, a virtual control signal is employed to remove the time derivative of the desired signal and to compensate for the disturbance *υ*:

$$
\propto\_{2d} = \dot{\mathfrak{x}}\_{1d} - k\_1 e\_1 \tag{5}
$$

where *k*<sup>1</sup> is a positive constant.

A new state control error is defined as:

$$\mathbf{e}\_2 = \mathbf{x}\_2 - \mathbf{x}\_{2d} \tag{6}$$

ensuring stability of the closed-loop system. The variation gains are self-adjusted to suppress unpredictable disturbances for the expected transient performance.

gain variation, which could activate a chattering problem [25], the following

*^ i* � � � *i*≜1*::*5

Under operation of the flexible gains, the nonlinear control signal Eq. (8) is

sat *k ^* 1 � �*e*<sup>1</sup>

*a*2

are the saturation functions limited by upper-bound values

*<sup>i</sup>*\_*low* ≤ 0 � �

*unew* ¼ *u* þ

*^ i*\_*lo* � � � *i*≜1*::*5 � �as follows:

*k ^*

8 >>>><

>>>>:

Δ \_ *k ^ i* < ∞

The learning rules for the variation gains are proposed as follows:

<sup>1</sup> ¼ �*σ*1*e*1*ε* � sat *k*

*<sup>ε</sup>*<sup>2</sup> � *<sup>η</sup>*2sat *<sup>k</sup>*

*e*1*ε* � *η*3sat *k*

*εφ* � *η*4sat *k*

8 < :

� � � � � � *k ^*

*k ^*

*<sup>i</sup>*\_*up* if *k ^ <sup>i</sup>* ≥ *k ^ <sup>i</sup>*\_*up* ≥0 � �

*<sup>i</sup>* if *k ^ <sup>i</sup>*\_*low* <*k ^ <sup>i</sup>* <*k ^ <sup>i</sup>*\_*up* � �

*<sup>i</sup>*\_*low* if *k ^ <sup>i</sup>* ≤*k ^*

If a closed-loop system satisfies *Lemma 1*, it is stable for the time-varying gains

To comply with *Assumption 3*, the learning laws for the dynamic gains is structured from activation functions of the state control errors and leakage functions,

> *^* 1 � �

*^* 2 � �

> *^* 3 � �

*^* 4 � �

> *^* 5 � �

sgn ð Þ *e*<sup>1</sup> *φ* � *η*5sat *k*

0<*ki* min ≤*ki* ≤*ki* max < ∞

constraints are noted.

*Self-Learning Low-Level Controllers*

*DOI: http://dx.doi.org/10.5772/intechopen.96732*

derivatives are bounded.

where sat *k*

**Lemma 2**:

*^ i* � �� � � *i*≜1*::*5

� �and lower-bound values *<sup>k</sup>*

complying with *Assumption 3*, and

sat *k ^ i* � �� � � *i*≜1*::*5 ¼

*i*¼1*::*5

8 >>>>>><

>>>>>>:

Proof of *Lemma 2* is given in *Appendix D*.

which make sure boundedness of the learning gains.

8

>>>>>>>>>>>>>>><

\_ *k ^*

\_ *k ^* <sup>2</sup> <sup>¼</sup> <sup>1</sup> *σ*2

\_ *k ^* <sup>3</sup> <sup>¼</sup> <sup>1</sup> *σ*3

\_ *k ^* <sup>4</sup> <sup>¼</sup> <sup>1</sup> *σ*4

\_ *k ^* <sup>5</sup> <sup>¼</sup> <sup>1</sup> *σ*5

>>>>>>>>>>>>>>>:

Δ*k ^* 1 þ Δ \_ *k ^* 1 � � <sup>&</sup>lt;*k*3 min *:*

modified:

*k ^ i*\_*up* � � � *i*≜1*::*5

**41**

*Assumption 3:* The variation terms *k*

Furthermore, to ensure high control quality by avoiding sudden change of the

� � and their first-order time

(11)

(12)

(13)

Differentiating the new error with respect to time and using the second equation of the dynamics Eq. (2) lead to

$$\dot{e}\_2 = -a\_1 \mathbf{x}\_2 + a\_2 \boldsymbol{\mu} + \boldsymbol{d} - \ddot{\mathbf{x}}\_{1d} + k\_1 (\mathbf{x}\_2 + \boldsymbol{\nu} - \dot{\mathbf{x}}\_{1d}) \tag{7}$$

To drive the new control error *e*<sup>2</sup> to an expected range, the final control signal is proposed as follows, including two sub-control terms (a model-based term and robust term):

$$u = -a\_2^{-1} \left( -a\_1 \mathbf{x}\_2 + k\_1 (\mathbf{x}\_2 - \dot{\mathbf{x}}\_{1d}) + (k\_2 - k\_1) e\_2 + (k\_3 + k\_4) e\_1 + \int\_0^t (k\_4 k\_1 e\_1 + k\_5 \text{sgn}(e\_1)) d\tau \right) \tag{8}$$

where *ki*∣*i*¼2,3,4,5 are positive control gains.

Stability of the closed-loop system under the controller Eq. (8) can be confirmed by the following statement.

#### **Lemma 1**:

Given a low-level system Eq. (2) under *Assumptions 1* and *2*, if employing the control rule Eqs. (3)–(8), stability of the closed-loop system is ensured for the positive bounded control gains *ki*∣*i*¼1*::*<sup>5</sup> satisfying:

$$k\_2 - k\_1 > 0\tag{9}$$

Proof of *Lemma 1* is given in *Appendix A*.

*Remark 1: Lemma 1* reveals that the closed-loop system is stabilized at a vicinity around zero under the constrain Eq. (9). Obviously, acceptable control performance could be resulted in with proper control gains selected.

Effectiveness of the nonlinear control structure is achieved by the following statement:

#### **Theorem 1**:

Given a closed loop system satisfying *Lemma 1*, it asymptotically converges if properly further choosing the control gains such that:

$$k\_{\mathcal{S}} \ge \Delta\_{\dot{h}} \tag{10}$$

Proof of *Theorem 1* is discussed in *Appendix B*.

*Remark 2:* In real-time situations [15, 29, 30], the position data *x1* are employed to approximate the velocity *x2* throughout a low-pass filter. Thus, the perturbance term (*υ*) obviously exists in the studied model Eq. (2) and its variation depends on the used filter.

*Remark 3:* With the robust backstepping control scheme designed, an excellent control performance can be resulted in by the proper control gains selected regardless of the presence of the disturbances. Perfectly selecting the gains for a good transient performance and maintaining high-precision control results for divergent working conditions in the real-time control is not a trivial work.

#### **3.2 Auto gain-tuning rules**

To effectively support gain selection for users, a simple strategy for gain tuning is employed: the control gains *ki*j *i*≜1*::*5 � � are separated into two terms: nominal elements

*ki* � � *i*≜1*::*5 � �and variation elements *<sup>k</sup> ^ i* � � � *i*≜1*::*5 � �. The nominal ones play a key role in *Self-Learning Low-Level Controllers DOI: http://dx.doi.org/10.5772/intechopen.96732*

ensuring stability of the closed-loop system. The variation gains are self-adjusted to suppress unpredictable disturbances for the expected transient performance.

Furthermore, to ensure high control quality by avoiding sudden change of the gain variation, which could activate a chattering problem [25], the following constraints are noted.

*Assumption 3:* The variation terms *k ^ i* � � � *i*≜1*::*5 � � and their first-order time

derivatives are bounded.

*e*<sup>2</sup> ¼ *x*<sup>2</sup> � *x*2*<sup>d</sup>* (6)

ð*t*

ð Þ *k*4*k*1*e*<sup>1</sup> þ *k*<sup>5</sup> sgn ð Þ *e*<sup>1</sup> *dτ*

1 A

(8)

0

*k*<sup>2</sup> � *k*<sup>1</sup> > 0 (9)

*<sup>h</sup>* (10)

Differentiating the new error with respect to time and using the second equation

To drive the new control error *e*<sup>2</sup> to an expected range, the final control signal is

Stability of the closed-loop system under the controller Eq. (8) can be confirmed

Given a low-level system Eq. (2) under *Assumptions 1* and *2*, if employing the control rule Eqs. (3)–(8), stability of the closed-loop system is ensured for the

*Remark 1: Lemma 1* reveals that the closed-loop system is stabilized at a vicinity around zero under the constrain Eq. (9). Obviously, acceptable control perfor-

Effectiveness of the nonlinear control structure is achieved by the following

Given a closed loop system satisfying *Lemma 1*, it asymptotically converges if

*k*<sup>5</sup> ≥ Δ\_

*Remark 2:* In real-time situations [15, 29, 30], the position data *x1* are employed to approximate the velocity *x2* throughout a low-pass filter. Thus, the perturbance term (*υ*) obviously exists in the studied model Eq. (2) and its variation depends on

*Remark 3:* With the robust backstepping control scheme designed, an excellent control performance can be resulted in by the proper control gains selected regardless of the presence of the disturbances. Perfectly selecting the gains for a good transient performance and maintaining high-precision control results for divergent

To effectively support gain selection for users, a simple strategy for gain tuning is

� � are separated into two terms: nominal elements

. The nominal ones play a key role in

proposed as follows, including two sub-control terms (a model-based term and

<sup>2</sup> �*a*1*x*<sup>2</sup> þ *k*<sup>1</sup> *x*<sup>2</sup> � *x*\_ ð Þþ <sup>1</sup>*<sup>d</sup>* ð Þ *k*<sup>2</sup> � *k*<sup>1</sup> *e*<sup>2</sup> þ ð Þ *k*<sup>3</sup> þ *k*<sup>4</sup> *e*<sup>1</sup> þ

where *ki*∣*i*¼2,3,4,5 are positive control gains.

positive bounded control gains *ki*∣*i*¼1*::*<sup>5</sup> satisfying:

Proof of *Lemma 1* is given in *Appendix A*.

mance could be resulted in with proper control gains selected.

properly further choosing the control gains such that:

Proof of *Theorem 1* is discussed in *Appendix B*.

working conditions in the real-time control is not a trivial work.

*i*≜1*::*5

*^ i* � � � *i*≜1*::*5 � �

*e*\_<sup>2</sup> ¼ �*a*1*x*<sup>2</sup> þ *a*2*u* þ *d* � *x*€1*<sup>d</sup>* þ *k*<sup>1</sup> *x*<sup>2</sup> þ *υ* � *x*\_ ð Þ <sup>1</sup>*<sup>d</sup>* (7)

of the dynamics Eq. (2) lead to

*Collaborative and Humanoid Robots*

robust term):

0 @

by the following statement.

**Lemma 1**:

statement:

**Theorem 1**:

the used filter.

*ki* � � *i*≜1*::*5 � �

**40**

**3.2 Auto gain-tuning rules**

employed: the control gains *ki*j

and variation elements *k*

*<sup>u</sup>* ¼ �*a*�<sup>1</sup>

Under operation of the flexible gains, the nonlinear control signal Eq. (8) is modified:

$$u\_{new} = u + \frac{\text{sat}\left(\bar{k}\_1\right)e\_1}{a\_2} \tag{11}$$

where sat *k ^ i* � �� � � *i*≜1*::*5 are the saturation functions limited by upper-bound values *k ^ i*\_*up* � � � *i*≜1*::*5 � �and lower-bound values *<sup>k</sup> ^ i*\_*lo* � � � *i*≜1*::*5 � �as follows:

$$\mathbf{sat}\left(\bar{k}\_{i}\right)\Big|\_{i\triangleq1\ldots5} = \begin{cases} \bar{k}\_{i\\_up} \text{ if } \left(\bar{k}\_{i} \ge \bar{k}\_{i\\_up} \ge 0\right) \\\ \bar{k}\_{i} \quad \text{if } \left(\bar{k}\_{i\\_low} < \bar{k}\_{i} < \bar{k}\_{i\\_up}\right) \\\ \bar{k}\_{i\\_low} \text{ if } \left(\bar{k}\_{i} \le \bar{k}\_{i\\_low} \le 0\right) \end{cases}$$

**Lemma 2**:

If a closed-loop system satisfies *Lemma 1*, it is stable for the time-varying gains complying with *Assumption 3*, and

$$\begin{cases} \displaystyle \begin{cases} \displaystyle \mathbf{0} < k\_{i\min} \le k\_i \le k\_{i\max} < \infty \\\\ \Delta\_{\frac{\cdot}{k\_i}} < \infty \\\\ \left(\Delta\_{\frac{\cdot}{k\_1}} + \Delta\_{\frac{\cdot}{k\_1}}\right) < k\_{\Im \min} . \end{cases} \end{cases} < \infty$$

Proof of *Lemma 2* is given in *Appendix D*.

To comply with *Assumption 3*, the learning laws for the dynamic gains is structured from activation functions of the state control errors and leakage functions, which make sure boundedness of the learning gains.

The learning rules for the variation gains are proposed as follows:

$$\begin{cases} \dot{\bar{k}}\_1 = -\sigma\_1 e\_1 \varepsilon - \text{sat}\left(\bar{k}\_1\right) \\ \dot{\bar{k}}\_2 = \frac{1}{\sigma\_2} \varepsilon^2 - \eta\_2 \text{sat}\left(\bar{k}\_2\right) \\ \dot{\bar{k}}\_3 = \frac{1}{\sigma\_3} e\_1 \varepsilon - \eta\_3 \text{sat}\left(\bar{k}\_3\right) \\ \dot{\bar{k}}\_4 = \frac{1}{\sigma\_4} \epsilon \rho - \eta\_4 \text{sat}\left(\bar{k}\_4\right) \\ \dot{\bar{k}}\_5 = \frac{1}{\sigma\_5} \text{sgn}\left(e\_1\right) \rho - \eta\_5 \text{sat}\left(\bar{k}\_5\right) \end{cases} \tag{13}$$

**4.2 Comparative control results**

*DOI: http://dx.doi.org/10.5772/intechopen.96732*

*Self-Learning Low-Level Controllers*

their control gains were chosen as

*e*<sup>1</sup> ¼ *x*<sup>1</sup> � *x*1*<sup>d</sup>*;*e*<sup>2</sup> ¼ *e*\_<sup>1</sup> þ *kRISE*1*e*<sup>1</sup>

Its control signal was:

*uRISE* ¼ �*a*�<sup>1</sup>

Eq. (D.1):

**Figure 2.**

**43**

*Design and setup of the experimental testing system.*

(

8 < :

*<sup>k</sup>*1*<sup>h</sup>* <sup>¼</sup> 100; *<sup>k</sup>*2*<sup>h</sup>* <sup>¼</sup> 100;*ω*0*<sup>h</sup>* <sup>¼</sup> 60; *<sup>θ</sup>* min *<sup>h</sup>* <sup>¼</sup> ½ � 6, 1 *<sup>T</sup>*

*<sup>k</sup>*1*<sup>k</sup>* <sup>¼</sup> 80; *<sup>k</sup>*2*<sup>k</sup>* <sup>¼</sup> 75;*ω*0*<sup>k</sup>* <sup>¼</sup> 40; *<sup>θ</sup>* min *<sup>k</sup>* <sup>¼</sup> ½ � 5, 0*:*<sup>2</sup> *<sup>T</sup>*

The RISE control gains were set to be:

Both the hip and knee joints were controlled at the same time using the same control algorithm proposed. The controller was also compared with an adaptive robust extended-state-observer-based (ARCESO) controller, a robust integral-signerror (RISE) controller, and another case of itself with fixed gains (nominal gains)

The ARCESO controller was designed based on a previous work [30] wherein

The RISE controller was implemented based on a robust integral theory [13] to control the studied system Eq. (2) without considering the measurement noise ð Þ*υ* .

> *kRISE*1*<sup>h</sup>* ¼ 53; *kRISE*2*<sup>h</sup>* ¼ 85*:*4; *kRISE*3*<sup>h</sup>* ¼ 20; *kRISE*4*<sup>h</sup>* ¼ 250; *kRISE*1*<sup>k</sup>* <sup>¼</sup> 45; *kRISE*2*<sup>k</sup>* <sup>¼</sup> 65; *kRISE*3*<sup>k</sup>* <sup>¼</sup> 17; *kRISE*4*<sup>k</sup>* <sup>¼</sup> 235; (

> *k*1*<sup>h</sup>* ¼ 1*:*5; *k*2*<sup>h</sup>* ¼ 72*:*5; *k*3*<sup>h</sup>* ¼ 2000; *k*4*<sup>h</sup>* ¼ 50; *k*5*<sup>h</sup>* ¼ 200; *<sup>k</sup>*1*<sup>k</sup>* <sup>¼</sup> 5; *<sup>k</sup>*2*<sup>k</sup>* <sup>¼</sup> <sup>72</sup>*:*5; *<sup>k</sup>*3*<sup>k</sup>* <sup>¼</sup> 2000; *<sup>k</sup>*4*<sup>k</sup>* <sup>¼</sup> 50; *<sup>k</sup>*5*<sup>k</sup>* <sup>¼</sup> 200; (

The excitation signals ð Þ *ε* and *φ* of the learning laws Eq. (13) were directly synthesized from the control error (*e*1) and its high-order time derivatives based on

; *<sup>θ</sup>* max *<sup>h</sup>* <sup>¼</sup> ½ � 25, 5 *<sup>T</sup>*

; *<sup>θ</sup>* max *<sup>k</sup>* <sup>¼</sup> ½ � 30, 1*:*<sup>5</sup> *<sup>T</sup>*

0

� � *:*

; ^*θh*ð Þ¼ <sup>0</sup> ½ � <sup>12</sup>*:*25, 2*:*<sup>5</sup> *<sup>T</sup>*

; ^*θk*ð Þ¼ <sup>0</sup> ½ � 15, 0*:*<sup>5</sup> *<sup>T</sup>*

ð Þ *kRISE*3*e*<sup>2</sup> þ *kRISE*<sup>4</sup> sgn ð Þ *e*<sup>2</sup> *dτ*

;

;

(14)

in Eq. (8), which is denoted as the robust backstepping (RB) controller.

<sup>2</sup> �*a*1*x*<sup>2</sup> � *<sup>x</sup>*€1*<sup>d</sup>* <sup>þ</sup> *kRISE*<sup>1</sup> *<sup>x</sup>*<sup>2</sup> � *<sup>x</sup>*\_ ð Þþ <sup>1</sup>*<sup>d</sup> kRISE*2*e*<sup>2</sup> <sup>þ</sup> <sup>Ð</sup>*<sup>t</sup>*

The nominal gains of the proposed controllers were chosen to be:

#### **Figure 1.**

*Overview of the gain-learning backstepping controller for low-level subsystems.*

where *ηi*∣*i*¼2*::*<sup>5</sup> and*σi*∣*i*¼1*::*<sup>5</sup> are positive learning rates.

To investigate the control performance of the learning control system, a new theorem is given.

#### **Theorem 2:**

If applying the control gains updated using Eq. (13) to a closed-loop system satisfying *Lemma 2*, asymptotic convergences of the state control error and variation gains are obtained.

Proof of *Theorem 2* could be referred in *Appendix E*.

*Remark 4:* Overview of the proposed controller is sketched in **Figure 1**. As stated in Theorem 1, the stability of the closed-loop system is ensured in a robust control framework, and as proven in Theorem 2, the adaptation of the control structure is highlighted by all the control gains learning for minimizing the tracking control error. The form of Eq. (E.4) reveals that the learning rates (*σ<sup>i</sup>*∣*i*¼1*::*<sup>5</sup> and *η<sup>i</sup>*∣*i*¼2*::*5) can be employed with predefined values for specific control hardware.

*Remark 5*: In real-time applications, the proposed algorithm will be deployed in a discrete-time environment, the control errors will converge to arbitrary vicinities around zero. The desired control range can be however minimized under the learning mechanism proposed.

#### **4. Real-time experiments**

#### **4.1 Setup**

In this section, control performance of the intelligent controller is discussed based on verification results carried out in a real-time legged 2DOF robot. The experimental leg included one hip joint and one knee joint which were actuated by two BLDC motors. The mechanical design and a photograph of the actual leg are presented in **Figure 2**.

Incremental encoders were used to measure the joint angles, while a force sensor was placed in the shank of the robot to evaluate the ground contact force. The velocity signal was calculated from filtered backward differentiation of the position data. The robot was setup to freely move in both *x* and *y* directions. Total weight of the robot was about 15.74 kg. The proposed control algorithm was deployed in a NI Electrical Controller throughout LABVIEW software with a sampling time of 2 ms. The time derivative and integral terms in real-time implementation were approximated by Euler backward methods.

Two systematic parameters *a*1*<sup>j</sup>*, *a*2*<sup>j</sup> <sup>j</sup>*¼*h*,*<sup>k</sup>* of the low-level systems could be estimated offline or online using a model-based identification method derived in previous works [27, 31, 32]. Nominal values of the parameters were approximately determined as *a*1*<sup>h</sup>* ¼ 2*:*5; *a*2*<sup>h</sup>* ¼ 12*:*25; *a*1*<sup>k</sup>* ¼ 0*:*5; *a*2*<sup>k</sup>* ¼ 15*:*
