# Design of Hybrid Phase Sliding Mode Control Scheme for Lower Extremity Exoskeleton
## 2 Methods
### Design of SMC Based on ESO
#### 2.2.2 Design of Sliding Mode Controller  
This work considers the nonlinear and strong coupling characteristics of the exoskeleton and designs the robust sliding mode controller combining with the system (2). The proof step of the controller does not directly use the upper limit of the disturbance but relies on the upper limit of the observer's observation error. As long as the observer has good observation ability (observation error converges) and ensures that the observation has an upper bound, then the proof of the controller is valid. Considering the stability of the system under the extended state observer (4), the controller can be proposed. The following lemma and proposition should be pointed out in advance:  
**Lemma 2**. : _For the candidate Lyapunov function \(V:[0,\infty)\in R\), the solution of the inequality equation \(V\leq-\alpha V+f,\forall t\geq t_{0}\geq 0\) is_  
\[V\left(t\right)\leq e^{-\alpha\left(t-t_{0}\right)}V\left(t_{0}\right)+\int_{t _{0}}^{t}e^{-\alpha\left(t-\tau\right)}f\left(\tau\right)\mathrm{d}\tau \tag{13}\]  
**Proposition 2**. : _The observation error under (4) is limited, that is \(\left\|\bar{v}+\bar{f}+k_{g}\bar{s}\right\|\leq\Delta_{\max}\), \(\Delta_{\max}>0\)._  
The reference position is indicated by \(x_{1d}=[q_{1d},q_{2d}]^{\mathrm{T}}\), define the tracking error as  
\[e=x_{1}-x_{1d}=[e_{1},e_{2}]^{\mathrm{T}} \tag{14}\]  
The sliding mode surface is defined as  
\[s=ce+\dot{e},c=diag(c_{1},c_{2}) \tag{15}\]  
According to Equation (15) and system (2), the general sliding mode controller has the following form:  
\[u=F\left(-ce+\ddot{\theta}_{d}-\eta\mathrm{sgn}s\right)-D\mathrm{sgn}s+\left( Cx_{2}+G\right) \tag{16}\]  
where \(\eta>0\) denotes the switching gain, \(D\) is considered to be the upper bound of disturbances, that is \(\left|d\right|\leq D\), the conventional sliding mode control often requires large switching gains to eliminate extern disturbances and uncertainties. However, the large switching gains will cause chattering. Through the designed extended state observer, the disturbances estimation are used as the feed-forward input of the controller, which greatly reduces the gain of the switching term in the sliding mode controller and effectively eliminates chattering. The sliding mode controller is designed as follows:  
\[u=F\left(-k_{g}\hat{s}-\hat{v}-\hat{f}-\eta\mathrm{sgn}s\right)+\left(Cx_{2}+G\right) \tag{17}\]  
where  
\[ \begin{array}{l}k_{g}=diag(k_{1},k_{2}),\;\;k_{1},k_{2}>0,\\ \hat{v}=\hat{c}e-\bar{x}_{1d},\;\hat{s}=c\bar{e}+\dot{e},\;\;\hat{e}=\hat{x}_{ 1}-x_{1d},\\ \dddot{e}=\hat{x}_{2}-x_{2d},\\ \hat{v}=v-\hat{v},\hat{f}=f-\hat{f},\hat{s}=s-\hat{s}.\end{array}  \tag{18}\]  
**Theorem 2**. : _Consider the exoskeleton system (2) and the extended state observer(4), the system globally stable under the controller(17) if the proposition 1-2 are satisfied and Lemma 1-2 are applied. The tracking error has an upper bound of convergence, and the convergence speed depends on positive constant parameter \(\varepsilon\) and control gain \(k_{g}\)._  
swing phase and a stance phase. The single-leg gait is divided into several specific stages, as shown in Figure 3. The stance stage includes four states, and the swing stage includes three states which can be collectively referred to as the swing phase. The design of the plantar pressure measurement system is an important part of the hybrid phase control mechanism [28]. In this article, the plantar pressure is collecting by High Dynamic Force Sensing Resistor-Insole, which is pasted on the sandal. It has eight HD-FSR cells and can measure 7 channels punctual plantar pressure, including foot's heel, midfoot, metatarsal heads, and the toes. The AD module of the STM32F407 collects the plantar pressure data at a rate of 200 Hz and transmits the data to the host computer to display and store in real time via Bluetooth. In this experiment, 200 gaits cycles from 5 healthy subjects have been obtained. During data collection, it was found that the data of the TOES cell were not regular, and it was given up.