Using an intelligent control scheme in the open-source design on non-invasive rehabilitation platform of physical therapy for patient

In the context of global pandemic, hospital or healthcare center is very sensitive for patients. However, the injuried patients must maintain their medical orders to rehabililate as soon as possible, otherwise, the clinical treatment could be interruptted. To overcome these troubles, an open-source design of mechanical machine for non-invasive method (NIPPT) is firstly introduced. The advantages of our approach are low-cost, available in the market and satisfy the medical requirements. The structure and motion of wrist are initially analyzed to obtain the dimensional sizes of mechanical details. Owing to computational mechanics, the architecture of hardware components is determined and manufactured. Later, sensing modules such as torque sensor, positioning sensor and limit sensor are integrated while powerful microprocessor provides the abilities of rapid calculation, small sampling time and stable operation. Then, the model-free control scheme such as fuzzy PID (F-PID) is embeded into hardware in order to drive the mechanism appropriately. Due to the simple implementation and servo lag phenomenon, this controller is expected to adapt with the uncertainties and unknown environment. Based on this design, several medical exercises are validated in the experimental tests. It is obviously seen that the proposed approach is feasible, proper and possible for clinical applications.


Specifications table Subject Area
Engineering More specific subject area

Bio-engineering, Mechatronics design, Motion control Method name
The modified fuzzy control integrating PID scheme with real-time performance in medical application Name and reference of original method Method 1: Using the recursive least square algorithm to determine the impedance parameters of human arm, the reference trajectory [1] can be generated in the case of healthy human. Then, the fuzzy logic strategy manipulate to track the desired path. Method 2: Proposing an effective solution to take care of patients from far, a wrist rehabilitation system ensuring the two wrist movements, was investigated [ 2 ]. The fuzzy controller was employed to control the robot action according to the pain felt by the patient. From

Mechanical analysis of proposed platform
Deriving from DOFs of hand wrist, this actuator needs to have two rotational movement to match with: one DOF for X axial rotation and the other for Z axis. After surveying the medium size of human, the dimensions of each component are proper and comfortable for each patient. During the computational process, it is acknowledged that there is essential to adjust the distance from palm to wrist. Hence, a passive DOF is attached to allow this adjustment. The novel concept of mechanical design for proposed instrument is demonstrated as Fig. 1 .
The number of DOFs W in this mechanism is identified as below where, R : the number of constraints for dynamic joints in mechanism W 0 : the total DOFs for dynamic joints if it is separated We have, From the proposed design, mechanical model of this instrument in 3D is established as Fig. 2 . Each part must obey the conditional constraints so that the total tolerances in manufacturing or assembly could be not violated.

Computational kinetic and dynamic of proposed platform
From the theoretical design, the coordinates as Fig. 3 are attached to each joint in order to compute both kinetic and dynamic for proposed instrument. Using the theory of Denavit-Hartenberg matrix, each joint has its own parameters to depict the motion as where, i +1 i T : transformation matrix from link i to link i + 1 .   The transformation matrices from link 1 to link 6 are Therefore, the total transformation matrix from link 1 to link 6 To simplify the dynamic computation, a theoretical diagram of proposed instrument in Fig. 4 is modified as below The kinetic energy for rotary angle θ 1 , θ 2 is determined as Similarly, the potential energy is  Using the Lagrange approach, we estimate Then, the applied torques F 1 , F 2 to drive two axes are By adopting above computation, the test validation of mechanical parts by SolidWorks software is deployed to confirm the design. The input parameters consist of materials, physical dimensions   and the estimated moment at each joint. These results are shown as Fig. 5 in order to identify the maximum stress and transposition which must be smaller than thresholds ( Fig. 6 ).

Implementation of control scheme
Generally, the medical machine for physical therapy should have two driving motors at least. For a specific exercise, the actuator needs the sensing data, for instance torque, angular rotation and velocity, and time period. In the field of clinical knowledge, nurse or technician must determine how long the exercise is. Depending on the feedback signals from patient, sensing module could     measure exactly and immediately. Nevertheless, these parameters still have the upper thresholds and lower thresholds according to each exercise, level of injury and load. As a result, the control scheme must adapt with various conditions. The fuzzy PID is initally proposed to implement in this hardware platform so that the response of driving actuator is smooth and stable. The overall scheme of proposed controller is illustrated as Fig. 7 . Since this algorithm does not need the precise information of model, the signal of control output is modified frequently in respect to the current status of environment. With the F-PID control, the reasoning mechanism of control rules allows to launch the proper signals. Besides, the conventional PID control is not usually well-adapted for nonlinear model with unknown parameter variations.
The main control scheme is organized as cascade diagram such the fuzzy logic scheme is first, and PID scheme is second. The inputs of fuzzy controller contains two physical variables, error of position and derivative of error. In this case, the control requirements are very sensitive so that each adjustment could not suddenly occur.
Firstly, the design process of fuzzy inference is to create the linguistic fuzzy variables as Fig. 8 . The inputs of fuzzy system are error e and deviation of error ∂e ∂t while the outputs are fed to regulate the PID controller. The shapes of membership functions in input variables are triangle and trapezoidal because of simple and effective performance. In this design, the linguistic input variables  Table 1 Fuzzy rule-based system for evaluation.
1 ≤ a, b, c ≤ 5 In Table 1 , the fuzzy rules are recognized so that the driving command does not fluctuate unexpectedly but still adapt rapidly. For these reasons, there are totally 9 fuzzy rules to indicate each potential combination of the two fuzzy inputs to perform an output for each rule. The fuzzy inference mechanism employed the appropriate expert-knowledge to produce the crisp output Crisp

Method validation
In order to estimate the system performance of proposed instrument, several experiments have been conducted on real hardware as Fig. 9 . One young volunteer has tried to employ this platform due to the user guideline. After the power is on, the host computer begins to communicate with main board of machine. Normally, the feedback signals including the sensing data and system state, are transmitted in one sampling period. If an operator or technician decides to switch the operating mode, then a command is passed to proposed instrument. In most cases, the security verification bit is firstly checked in the communication frame because the safety in execution is prior.
For the treatment of injuried patient, nurse or technical operator must set the working mode in the first stage. Later, user must follow the physical exercises that are pre-determined. Whenever the movement of hand is activated, the motion parameters could be collected. Since the machine has two DOFs, hence, the status of two joints are monitored. The data of the first joint is captured from Figs. 10 to 12 whilst the others are shown from Figs. 13 to 15 .
To imitate the medical therapy, the position and speed are primarily identified as the desired performance. Thereafter, the driving commands from proposed controller are fed to actuator. Thanks to F-PID scheme, the position performance in Figs. 10 and 13 for the first joint and second joint respectively, is well-received. The tracking results in Figs. 11 and 14 are also as good as the expected values. It is clearly seen that the tuning mechanism of proposed control scheme work well although the machine is under the impact of uncertainties. The torque performance of each joint is monitored in order to maintain in the range of the reasonable thresholds. From these results, the proposed design is effective, feasible and appropriate in the field of medical applications.