Design and Control of Upper Limb Rehabilitation Training Robot Based on a Magnetorheological Joint Damper

In recent years, rehabilitation robots have been developed and used in rehabilitation training for patients with hemiplegia. In this paper, a rehabilitation training robot with variable damping is designed to train patients with hemiplegia to recover upper limb function. Firstly, a magnetorheological joint damper (MR joint damper) is designed for the rehabilitation training robot, and its structural design and dynamic model are tested theoretically and experimentally. Secondly, the rehabilitation robot is simplified into a spring-damping system, and the rehabilitation training controller for human movement is designed. The rehabilitation robot dynamically adjusts the excitation current according to the feedback speed and human–machine interaction torque, so that the rehabilitation robot always outputs a stable torque. The magnetorheological joint damper acts as a clutch to transmit torque safely and stably to the robot joint. Finally, the upper limb rehabilitation device is tested. The expected torque is set to 20 N, and the average value of the output expected torque during operation is 20.02 N, and the standard deviation is 0.635 N. The output torque has good stability. A fast (0.5 s) response can be achieved in response to a sudden motor speed change, and the average expected output torque is 20.38 N and the standard deviation is 0.645 N, which can still maintain the stability of the output torque.


Introduction
Various dysfunctions often occur after stroke, and hemiparesis is the most common type of motor dysfunction.Since the central nervous system of the upper limbs is closer to the brain and the movement of the upper limbs is more variable, most stroke patients are unable to control their limbs effectively, especially the upper limbs.Clinical practice has shown that the most effective way to treat hemiplegia is to stimulate the regeneration of the injured central nerves through repeated rehabilitation exercises [1,2].
The effectiveness of traditional rehabilitation therapy relies heavily on the expertise and knowledge of the rehabilitation practitioner [3].Therefore, the use of robotics in the field of rehabilitation should take advantage of its strengths in performing high-intensity repetitive movements to alleviate muscle atrophy and joint stiffness [4][5][6].The shortcomings of traditional rehabilitation training, such as a not obvious rehabilitation effect, high cost, and difficult operation, have been overcome by robot-assisted training [7].In general, assisted training robots can be divided into two types: exoskeleton and end traction [8].The representative upper limb rehabilitation robots CADEN-7 [9], EUROExos [10], and BONES [11,12] were mainly rope-driven or pneumatic muscle-driven exoskeleton-type robots, which can realize multi-joint rehabilitation training.Exoskeletal rehabilitation devices are complex and inconvenient to wear and are not suitable for small medical institutions such as clinics and homes.Zhang designed an end-guided upper limb rehabilitation robot, UECM [13], which can realize shoulder adduction/abduction and elbow flexion/extension movements in the horizontal plane.Yong had developed an end-guided upper limb rehabilitation robot that can simultaneously perform different modes of rehabilitation training for the right and left hands [14].The end-effector robot transmits force through the grip and the user only needs to hold the grip to feel the assist or resistance, making it easy to get on and off the robot and change patients.Therefore, in the current situation of high demand for rehabilitation and patients queuing for treatment, the end-traction robot is an internationally recognized efficient design.
Currently, electric motors are mainly used as a rigid power source in rehabilitation robots.Due to the sudden change in load, the electric motor may stall, and the current will increase rapidly.In addition, there is a braking delay in the electric motor, which is a potential safety threat prone to causing secondary injuries to the patient.The use of smart materials in the robot transmission structure [15,16] can achieve better control during use [17,18].Magnetorheological fluid (MRF) is a smart material consisting of soft magnetic material particles, carrier fluid, and surfactant, and its fluid properties can be changed reversibly according to the external magnetic field [19,20].MRFs have the advantages of adjustable damping, a wide dynamic range, and a fast response time [21,22].Because of their variable damping, ease of control, and low cost, magnetorheological devices are beginning to be used in rehabilitation equipment to provide flexible and reliable impedance to help patients recover [23][24][25].
Many scholars have researched and explored the use of MRF in the field of rehabilitation.Xu designed and studied a magnetorheological multimodal lower limb rehabilitation robot [26,27], which realized adaptive rehabilitation training based on human intention.In addition, magnetorheological devices were used in the lower limb ankle joints to assist the user in movements such as walking, jumping, and landing [28].The MR Brake for wrist rehabilitation device developed by M. Avraam et al. [29] can achieve pronation/pronation movement of the wrist according to the set mode.The magnetorheological device designed by Takehito Kikuchi [30] and Noritaka Sato [31] for upper limb rehabilitation enables exercise recovery of upper limb muscles.The existing magnetorheological rehabilitation equipment can only provide rehabilitation control with fixed excitation current, but the motion of the hand is not fixed and random, which will cause fluctuations in the output damping torque.The magnetorheological joint damper developed in this paper can dynamically adjust the excitation current and robot speed according to the external motion state and the change in the control target and obtain a stable robot joint output torque.
The main purpose of this paper is to propose a magnetorheological upper limb rehabilitation training system.The structure of the paper is as follows: In Section 2, the mechanical mechanism of the robot trajectory and the MR joint damper are proposed, and the feasibility of the MR joint damper is verified by magnetic field simulation.In Section 3, the dynamic equation of the designed magnetorheological damper is established, and the accuracy of the dynamic equation is verified by experiments.In Section 4, the rehabilitation control strategy of the robot is introduced, the proposed control method is experimentally verified, and the safety performance of the rehabilitation robot is tested.In Section 5, the results are analyzed and discussed.

Mechanical Structure
Circular movement of the upper limb in terminal traction is a multi-joint process that sequentially activates the muscles of the elbow and shoulder.In addition, 360 • movement training of the arm in a circular motion requires coordination between the shoulder and elbow joints, which has a positive impact on upper limb rehabilitation training [31][32][33].As shown in Figure 1, cyclic and repeated variable resistance exercises can positively improve upper limb mobility and help patients regain their athletic ability.
shown in Figure 1, cyclic and repeated variable resistance exercises can positively improve upper limb mobility and help patients regain their athletic ability.The mechanical structure of the upper limb rehabilitation device is shown in Figure 2. In the rehabilitation robot, it is powered by a decelerating motor and driven by an elastic coupling.The MR joint damper, as a power transmission mechanism, plays a role in adjusting the output interaction torque of rehabilitation robots in rehabilitation training.D-H parameter method is adopted to establish the horizontal coordinate system of the human upper limb with the shoulder joint as the origin, and the schematic diagram of the horizontal coordinate system of the upper limb is shown in Figure 3.The mechanical structure of the upper limb rehabilitation device is shown in Figure 2. In the rehabilitation robot, it is powered by a decelerating motor and driven by an elastic coupling.The MR joint damper, as a power transmission mechanism, plays a role in adjusting the output interaction torque of rehabilitation robots in rehabilitation training.D-H parameter method is adopted to establish the horizontal coordinate system of the human upper limb with the shoulder joint as the origin, and the schematic diagram of the horizontal coordinate system of the upper limb is shown in Figure 3. shown in Figure 1, cyclic and repeated variable resistance exercises can positively improve upper limb mobility and help patients regain their athletic ability.The mechanical structure of the upper limb rehabilitation device is shown in Figure 2. In the rehabilitation robot, it is powered by a decelerating motor and driven by an elastic coupling.The MR joint damper, as a power transmission mechanism, plays a role in adjusting the output interaction torque of rehabilitation robots in rehabilitation training.D-H parameter method is adopted to establish the horizontal coordinate system of the human upper limb with the shoulder joint as the origin, and the schematic diagram of the horizontal coordinate system of the upper limb is shown in Figure 3.A kinematics analysis is to study the relationship between the end pose and joint angle.According to the homogeneous coordinate transformation equation, the pose matrix 0 T 3 of the end relative to the origin can be obtained (cθ i = cosθ i , sθ i = sinθ i ): Upper limb kinematics analysis has the potential to be a useful tool in clinical decision-making.The upper limb offers many degrees of freedom, coordinated movement across multiple joints, and a wide range of motion at the joints.As shown in Table 1, the range of motion and human body size required for daily activities by healthy adults are quantified.Based on this standard, we designed the trajectory and range of motion of the rehabilitation robot.By comparing the motion range of the human upper limb with the motion trajectory of the rehabilitation robot in Figure 4, the planned rehabilitation motion trajectory (radius R = 200 mm) conforms to the motion range of the upper limb, which can ensure the safety and rationality of rehabilitation training.Based on the pose matrix, the equation for the coordinate position of the end in the plane is as follows: Upper limb spatial position: Upper limb kinematics analysis has the potential to be a useful tool in clinical decisionmaking.The upper limb offers many degrees of freedom, coordinated movement across multiple joints, and a wide range of motion at the joints.As shown in Table 1, the range of motion and human body size required for daily activities by healthy adults are quantified.Based on this standard, we designed the trajectory and range of motion of the rehabilitation robot.By comparing the motion range of the human upper limb with the motion trajectory of the rehabilitation robot in Figure 4, the planned rehabilitation motion trajectory (radius R = 200 mm) conforms to the motion range of the upper limb, which can ensure the safety and rationality of rehabilitation training.

Magnetorheological Joint Damper Design and Simulation
Muscle strength is the force produced by muscles when they contract and are excited and is necessary for the body to maintain posture, initiate, or control movement.Shor-term and long-term treatment plans are developed based on muscle strength assessment results.The Lovett muscle strength rating scale is used to evaluate the effectiveness of functional recovery after stroke.The muscle strength rating scale is shown in Table 2.The maximum gripping force that can be generated by the upper limb is 400 N for healthy adult males and 228 N for females [35].Considering that it is mainly intended for elderly patients, the rehabilitation device provides a maximum of 20 N of human-machine interaction force (about 10% of the force of a healthy handgrip).The end of the subject's upper limb was set to perform a circular motion with a radius of R = 200 mm together with the rehabilitation device.
Upper limb kinematics analysis has the potential to be a useful tool in clinical decision-making.The upper limb offers many degrees of freedom, coordinated movement across multiple joints, and a wide range of motion at the joints.As shown in Table 1, the range of motion and human body size required for daily activities by healthy adults are quantified.Based on this standard, we designed the trajectory and range of motion of the rehabilitation robot.By comparing the motion range of the human upper limb with the motion trajectory of the rehabilitation robot in Figure 4, the planned rehabilitation motion trajectory (radius R = 200 mm) conforms to the motion range of the upper limb, which can ensure the safety and rationality of rehabilitation training.In a rehabilitation robot system, MR joint dampers generate controlled torque for the robot joints by adjusting the input current.As shown in Figure 5, the MR joint damper is mainly composed of magnetorheological fluid, rotor, stator, excitation coil, and sealing device.The specific design parameters of MR joint dampers are shown in Table 3.The magnetorheological fluid is evenly distributed in the gap between the rotor and the stator, and a magnetic field is generated around the exciting coil when a current is passed into the coil.Magnetorheological fluid changes from fluid form to a solid-like form under the action of a magnetic field.The T-type rotor designed in this paper combines the two ends of the rotor and the cylinder of the rotor as the effective working area, which has the advantages of a small volume, compact structure, and large damping torque.
The electromagnetic simulation of MR joint dampers is carried out to verify the rationality of the structural design.Figure 6 shows the simulation of the magnetic field when the maximum excitation current (2 A) is applied.In the magnetic field cloud image, we can see that the magnetic field becomes stronger the closer you get to the coil.The magnetic field generated by the upper and lower coils is symmetrically distributed, and the two magnetic fields are superimposed on each other at the rotor to obtain a greater magnetic field effect.We can observe in more detail the magnetic field changes in the damped channels filled with magnetorheological fluids under different excitation currents (1 A, 2 A, 3 A, and 4 A).The gap width of the magnetorheological liquid filled in the shell is δ, R 1 and R 2 are the inner and outer diameters of the effective ring on the end face, H is the magnetic field intensity generated by the excitation coil, h is the height of the ring, τ m is the static yield stress, and η is the apparent viscosity of the magnetorheological liquid.
According to the Bingham model, the output torque of MR joint dampers can be calculated as follows:  The electromagnetic simulation of MR joint dampers is carried out to verify the rationality of the structural design.Figure 6 shows the simulation of the magnetic field when the maximum excitation current (2 A) is applied.In the magnetic field cloud image, we can see that the magnetic field becomes stronger the closer you get to the coil.The magnetic field generated by the upper and lower coils is symmetrically distributed, and the two magnetic fields are superimposed on each other at the rotor to obtain a greater magnetic field effect.We can observe in more detail the magnetic field changes in the damped channels filled with magnetorheological fluids under different excitation currents (1A, 2A, 3A, and 4A).The gap width of the magnetorheological liquid filled in the shell is ,  and  are the inner and outer diameters of the effective ring on the end face,  is the magnetic field intensity generated by the excitation coil, ℎ is the height of the ring,  is the static yield stress, and  is the apparent viscosity of the magnetorheological liquid.According to the Bingham model, the output torque of MR joint dampers can be calculated as follows: is the torque transmitted by the end face of the rotor, and  is the torque transmitted by the circumferential surface of the rotor:  M d is the torque transmitted by the end face of the rotor, and M z is the torque transmitted by the circumferential surface of the rotor: It can be seen from the magnetic field simulation results that the magnetic field distribution in the working area of the damper is reasonable, and the magnetorheological field in the damping channel can realize the role of transmitting damping torque.The relationship between the excitation current and magnetic induction intensity can be obtained using a simulation.Under normal circumstances, when the working current of the MR joint damper is 0-2 A, the output torque is 0-5 NM, so we can provide 0-25 N pressure for the rehabilitation training of the limbs.It can be seen from the magnetic field simulation results that the magnetic field distribution in the working area of the damper is reasonable, and the magnetorheological field in the damping channel can realize the role of transmitting damping torque.The relationship between the excitation current and magnetic induction intensity can be obtained using a simulation.Under normal circumstances, when the working current of the MR joint damper is 0-2 A, the output torque is 0-5 NM, so we can provide 0-25 N pressure for the rehabilitation training of the limbs.

MR Joint Damper Dynamic Model
To obtain a good control effect, the establishment of an accurate dynamic model is a prerequisite for achieving good results.MR joint dampers have strong nonlinear and hysteretic properties, which make their accurate modeling complicated.The hyperbolic tangent model [37] can describe the hysteretic characteristics of MRF, which can be expressed as follows: where c is the damping coefficient, k is the stiffness coefficient, α denotes the proportionality coefficient related to the hysteresis characteristic, β denotes the proportionality coefficient related to the slope of the hysteresis curve, δ denotes the half-width of the hysteresis curve, and  is the bias force.
The calibration test platform of the MR joint damper is shown in Figure 7.The servo motor (Yaskawa Motor SGM7G20AFC61) generates the driving force, and the dynamic torque sensor (Zhongwan Jinno JN-DN5) is installed on the output shaft of the MR joint damper.The adjustable current input to the coil is provided by a DC power supply.The end payload is regulated by the magnetic powder brake (Jiangsu Haowen PB-12).During the test, the current (0-4 A) and the motor (amplitude ±10° frequency 1 Hz) are adjusted to achieve different output torques of the MR joint dampers.

MR Joint Damper Dynamic Model
To obtain a good control effect, the establishment of an accurate dynamic model is a prerequisite for achieving good results.MR joint dampers have strong nonlinear and hysteretic properties, which make their accurate modeling complicated.The hyperbolic tangent model [37] can describe the hysteretic characteristics of MRF, which can be expressed as follows: where c is the damping coefficient, k is the stiffness coefficient, α denotes the proportionality coefficient related to the hysteresis characteristic, β denotes the proportionality coefficient related to the slope of the hysteresis curve, δ denotes the half-width of the hysteresis curve, and f 0 is the bias force.
The calibration test platform of the MR joint damper is shown in Figure 7.The servo motor (Yaskawa Motor SGM7G20AFC61) generates the driving force, and the dynamic torque sensor (Zhongwan Jinno JN-DN5) is installed on the output shaft of the MR joint damper.The adjustable current input to the coil is provided by a DC power supply.The end payload is regulated by the magnetic powder brake (Jiangsu Haowen PB-12).During the test, the current (0-4 A) and the motor (amplitude ±10 • frequency 1 Hz) are adjusted to achieve different output torques of the MR joint dampers.
The experimental data on the relationship between the damping torque of different currents and displacement and velocity are used as the model training data.The parameters of the hyperbolic tangent model are identified by genetic algorithm and least square method [38].The set parameters c, k, α, β, and δ are current-dependent parameters, and a polynomial in the current is fitted to the parameters at different currents as follows:  (8) The results of parameter identification are obtained as shown in Table 4. Comparing the established hyperbolic tangent model with the experimental data when the excitation signal has an amplitude of ±10 • at a frequency of 1 Hz, and a comparison of the model fit is shown in Figure 8.It can be found that the established hyperbolic tangent model fits the experimental results well.This reflects the velocity characteristics and hysteresis characteristics of the damping torque of the MR joint damper.At the same time, the validity of the model is verified.The damping force increases with the increase in current.To obtain a better control effect, we mainly chose a 0-2 A excitation current for the experiment.The results of parameter identification are obtained as shown in Table 4. Comparing the established hyperbolic tangent model with the experimental data when the excitation signal has an amplitude of ±10° at a frequency of 1 Hz, and a comparison of the model fit is shown in Figure 8.It can be found that the established hyperbolic tangent model fits the experimental results well.This reflects the velocity characteristics and hysteresis characteristics of the damping torque of the MR joint damper.At the same time, the validity of the model is verified.The damping force increases with the increase in current.To obtain a better control effect, we mainly chose a 0-2 A excitation current for  The damping torque output of the MR joint damper is related to the rotation angle and angular velocity of the damper connecting rod and the input control current.In the actual engineering process, it is often necessary to deduce the corresponding control current according to the expected damping torque and the current motion state.Due to the nonlinear characteristics of the MR devices, the inverse mechanical model of the MR joint damper can be trained by a BP neural network through the obtained hyperbolic tangent model.The input layer and output layer of the BP neural network are set as follows: The damping torque output of the MR joint damper is related to the rotation angle and angular velocity of the damper connecting rod and the input control current.In the actual engineering process, it is often necessary to deduce the corresponding control current according to the expected damping torque and the current motion state.Due to the nonlinear characteristics of the MR devices, the inverse mechanical model of the MR joint damper can be trained by a BP neural network through the obtained hyperbolic tangent model.The input layer and output layer of the BP neural network are set as follows: =  =   (10)

Robot System Implementation
Figure 9 shows the hardware composition of the rehabilitation robot control system.The DSP28335 chip is the host computer's main control chip to undertake the main data processing and program control functions.The encoder is selected as an extended-range encoder with a resolution of 1024 pulse signals per revolution.The torque sensor is located below the handle and is used to monitor the interaction torque between the feedback patient and the rehabilitation robot.The motion data acquisition system is responsible for collecting the motion speed of human upper limbs, motor speed, and human-computer interaction torque and transmitting them to the main control chip.The motor and current driver execute the program command to dynamically adjust the motor speed with the current of the MR joint damper through the PWM signal.

Robot System Implementation
Figure 9 shows the hardware composition of the rehabilitation robot control system.The DSP28335 chip is the host computer's main control chip to undertake the main data processing and program control functions.The encoder is selected as an extended-range encoder with a resolution of 1024 pulse signals per revolution.The torque sensor is located below the handle and is used to monitor the interaction torque between the feedback patient and the rehabilitation robot.The motion data acquisition system is responsible for collecting the motion speed of human upper limbs, motor speed, and human-computer interaction torque and transmitting them to the main control chip.The motor and current driver execute the program command to dynamically adjust the motor speed with the current of the MR joint damper through the PWM signal.The damping torque output of the MR joint damper is related to the rotation angle and angular velocity of the damper connecting rod and the input control current.In the actual engineering process, it is often necessary to deduce the corresponding control current according to the expected damping torque and the current motion state.Due to the nonlinear characteristics of the MR devices, the inverse mechanical model of the MR joint damper can be trained by a BP neural network through the obtained hyperbolic tangent model.The input layer and output layer of the BP neural network are set as follows: =  =   (10)

Robot System Implementation
Figure 9 shows the hardware composition of the rehabilitation robot control system.The DSP28335 chip is the host computer's main control chip to undertake the main data processing and program control functions.The encoder is selected as an extended-range encoder with a resolution of 1024 pulse signals per revolution.The torque sensor is located below the handle and is used to monitor the interaction torque between the feedback patient and the rehabilitation robot.The motion data acquisition system is responsible for collecting the motion speed of human upper limbs, motor speed, and human-computer interaction torque and transmitting them to the main control chip.The motor and current driver execute the program command to dynamically adjust the motor speed with the current of the MR joint damper through the PWM signal.As shown in Figure 10, the robotic arm transmits the torque of the MR joint damper to the affected limb through the handle.The three-dimensional force sensor (HEX80RE3200N) will be responsible for real-time monitoring of the human-computer interaction torque.As shown in Figure 10, the robotic arm transmits the torque of the MR joint damper to the affected limb through the handle.The three-dimensional force sensor (HEX80RE3200N) will be responsible for real-time monitoring of the human-computer interaction torque.

Training Controller
In the treatment and rehabilitation of traditional hemiplegia patients, exercise training of the affected limb plays an important role.Rehabilitation training requires many

Training Controller
In the treatment and rehabilitation of traditional hemiplegia patients, exercise training of the affected limb plays an important role.Rehabilitation training requires many repetitive movements to rebuild the motor nerves while ensuring that the auxiliary force provided remains stable.The training controller of the rehabilitation robot is designed for this goal.MR joint dampers accurately provide auxiliary force to the patient when the strength is insufficient, ensuring the completion of the training goal, and are suitable for establishing the motor coordination ability of the affected limb.
Establish a mechanical model of human-computer interaction: .
x,x represent the acceleration, velocity, and displacement of the human-robot interaction end; M, B, and K denote the inertia, damping, and stiffness of the system, respectively; τ rob denotes the human-robot interaction torque of the robotic system; and τ MR denotes the torque supplied by the MR joint damper.
As shown in Figure 11, the interaction between the robot and the environment in the supple state can be viewed as a mass block-spring-damping second-order system.The robot joint torque is adjusted according to the deviation of the actual position from the set position to achieve tracking control of torque and velocity.

Training Controller
In the treatment and rehabilitation of traditional hemiplegia patients, exercise training of the affected limb plays an important role.Rehabilitation training requires many repetitive movements to rebuild the motor nerves while ensuring that the auxiliary force provided remains stable.The training controller of the rehabilitation robot is designed for this goal.MR joint dampers accurately provide auxiliary force to the patient when the strength is insufficient, ensuring the completion of the training goal, and are suitable for establishing the motor coordination ability of the affected limb.
Establish a mechanical model of human-computer interaction: where , ,  represent the acceleration, velocity, and displacement of the human-robot interaction end; M, B, and K denote the inertia, damping, and stiffness of the system, respectively;  denotes the human-robot interaction torque of the robotic system; and  denotes the torque supplied by the MR joint damper.As shown in Figure 11, the interaction between the robot and the environment in the supple state can be viewed as a mass block-spring-damping second-order system.The robot joint torque is adjusted according to the deviation of the actual position from the set position to achieve tracking control of torque and velocity.As shown in Figure 12, a block diagram of the training control strategy is presented.In the process of training control, the upper limb has a poor movement ability to drive the rehabilitation robot.When the sensor detects slight movement, the motor drives the MR joint damper at a faster speed to provide positive rehabilitation force in the same direction.Currently, the stable output of the end interaction force of the rehabilitation robot is realized by dynamically adjusting the current of the MR joint damper.As shown in Figure 12, a block diagram of the training control strategy is presented.In the process of training control, the upper limb has a poor movement ability to drive the rehabilitation robot.When the sensor detects slight movement, the motor drives the MR joint damper at a faster speed to provide positive rehabilitation force in the same direction.Currently, the stable output of the end interaction force of the rehabilitation robot is realized by dynamically adjusting the current of the MR joint damper.

Training Performance Testing
The main purpose of the upper limb rehabilitation equipment controller is to realize the variable damping rehabilitation training device by adjusting the excitation current of the MR joint damper.The dynamic model of the MR joint damper is established by experiments, and the reverse dynamic model of the MR joint damper is obtained using the BP neural network calculation method and the forward dynamic model.The end of the subject's upper limb is set to perform a circular motion with a radius of R = 200 mm together with the rehabilitation equipment, and the subject's upper limb mass is about 5 kg.
In the experiment, the affected limb of the tester was relaxed on the handle.When the robot detected a slight movement speed of the hand, the handle of the rehabilitation

Training Performance Testing
The main purpose of the upper limb rehabilitation equipment controller is to realize the variable damping rehabilitation training device by adjusting the excitation current of the MR joint damper.The dynamic model of the MR joint damper is established by experiments, and the reverse dynamic model of the MR joint damper is obtained using the BP neural network calculation method and the forward dynamic model.The end of the subject's upper limb is set to perform a circular motion with a radius of R = 200 mm together with the rehabilitation equipment, and the subject's upper limb mass is about 5 kg.
In the experiment, the affected limb of the tester was relaxed on the handle.When the robot detected a slight movement speed of the hand, the handle of the rehabilitation device began to drive the affected limb to move, as shown in Figure 13.

Training Performance Testing
The main purpose of the upper limb rehabilitation equipment controller is to realize the variable damping rehabilitation training device by adjusting the excitation current of the MR joint damper.The dynamic model of the MR joint damper is established by experiments, and the reverse dynamic model of the MR joint damper is obtained using the BP neural network calculation method and the forward dynamic model.The end of the subject's upper limb is set to perform a circular motion with a radius of R = 200 mm together with the rehabilitation equipment, and the subject's upper limb mass is about 5 kg.
In the experiment, the affected limb of the tester was relaxed on the handle.When the robot detected a slight movement speed of the hand, the handle of the rehabilitation device began to drive the affected limb to move, as shown in Figure 13.Since the velocity of the rehabilitation motion of the hand is random and uncertain, the velocity difference between the input end and the output end of the MR joint damper changes in real time.By monitoring the change in velocity differential, the excitation current is adjusted in real time according to the reverse dynamic model of the MR joint damper and the human-computer interaction model, to realize stable tracking of the end force output.As shown in Figure 14a, the speed of the affected limb varies randomly during rehabilitation exercise, during which the excitation current varies in real time from a maximum of 1.91 A to a minimum of 1.10 A (in line with the given current range 0-2 A).As shown in Figure 14b, the end sensor monitors the change in the human-computer interaction force during the operation of the rehabilitation device.The expected torque is  Compared with common motor control, there are hidden safety problems caused by the stalling impact.The upper limb recovery device used for rehabilitation pays more attention to safety considerations.The safety test results of the upper limb rehabilitation robot in the event of a sudden motor stall (speed mutation increase) are shown in Figure 15.As shown in Figure 15a, the motor speed changes during normal operation, and the controller detects the change in speed within a short period of time (0.5 s) and adjusts the Compared with common motor control, there are hidden safety problems caused by the stalling impact.The upper limb recovery device used for rehabilitation pays more attention to safety considerations.The safety test results of the upper limb rehabilitation robot in the event of a sudden motor stall (speed mutation increase) are shown in Figure 15.As shown in Figure 15a, the motor speed changes during normal operation, and the controller detects the change in speed within a short period of time (0.5 s) and adjusts the excitation current (from 1.52 A to 1.34 A).When the motor speed changes abruptly, the end output torque increases by 12.5% and quickly recovers to the expected torque, as shown in Figure 15b.In the process of safety testing, the average value of the output expected torque is 20.38 N and the standard deviation is 0.645 N, which can maintain the stability of the output torque.Compared with common motor control, there are hidden safety problems caused by the stalling impact.The upper limb recovery device used for rehabilitation pays more attention to safety considerations.The safety test results of the upper limb rehabilitation robot in the event of a sudden motor stall (speed mutation increase) are shown in Figure 15.As shown in Figure 15a, the motor speed changes during normal operation, and the controller detects the change in speed within a short period of time (0.5 s) and adjusts the excitation current (from 1.52 A to 1.34 A).When the motor speed changes abruptly, the end output torque increases by 12.5% and quickly recovers to the expected torque, as shown in Figure 15b.In the process of safety testing, the average value of the output expected torque is 20.38 N and the standard deviation is 0.645 N, which can maintain the stability of the output torque.

Conclusions
To help stroke patients with upper limb movement disorders recover their movement ability, a rehabilitation training device and control method based on magnetorheological joint dampers are designed in this paper.To meet the control requirements, a dynamic model of the magnetorheological joint damper is established, and an experimental platform for the dynamic model is set up.The hyperbolic tangent model of the magnetorheological joint damper is obtained by a genetic algorithm and the least square method, and the inverse dynamic model is obtained by a BP neural network.The establishment of a dynamic model provides a basis for further research on the performance and control of rehabilitation devices.The joint damper based on MR fluid can realize the characteristics of adjustable and controllable damping torque and output damping torque 0-5.0 Nm under the condition of working current (0-2 A), which can meet the needs of dynamic adjustment of human-computer interaction force when recovering patients perform recovery exercise.In this paper, the control strategy of the rehabilitation robot is tested experimentally, and the specific results are as follows: (1) The rehabilitation-compliant joint based on MR fluid can dynamically adjust the excitation current according to the changes in the motion state of the human upper limb.The expected torque is set to 20 N, and the average value of the output expected torque is 20.02 N, and the standard deviation is 0.635 N during the random motion of the upper limb velocity.The output torque has good stability.(2) The application of MR devices in rehabilitation training improves flexibility and safety compared with traditional motor drives.It overcomes the shortcomings of the traditional rehabilitation device, which is easy to have impact and unstable human-computer interaction force causing secondary injury.The motor speed changes during normal operation, and the controller detects the change in speed for a short period of time (0.5 s) and adjusts the excitation current (from 1.52 A to 1.34 A).When the motor speed changes, the end output torque increases by 12.5% and quickly recovers to the desired torque.In the process of safety test, the average value of the output expected torque is 20.38 N and the standard deviation is 0.645 N, which can still maintain the stability of the output torque.
Because the speed of upper limb rehabilitation movement is a random speed and there is a delay problem in the control of MR devices, there is a problem of fluctuations in the end human-computer interaction torque.To achieve better control results, further research will be carried out, for example, by providing linear motors to help patients move smoothly.

Figure 1 .
Figure 1.The prototype of the robot.

Figure 2 .
Figure 2. The design scheme of the robot.

Figure 1 .
Figure 1.The prototype of the robot.

Figure 1 .
Figure 1.The prototype of the robot.

Figure 2 .
Figure 2. The design scheme of the robot.Figure 2. The design scheme of the robot.

Figure 2 .
Figure 2. The design scheme of the robot.Figure 2. The design scheme of the robot.

1 ) 15 Figure 3 . 3 T
Figure 3. Coordinate diagram of each joint of the upper limb.A kinematics analysis is to study the relationship between the end pose and joint angle.According to the homogeneous coordinate transformation equation, the pose matrix 0 3T of the end relative to the origin can be obtained (cθi = cosθi, sθi = sinθi):

Figure 4 .
Figure 4. Range of upper limb motion trajectories.

Figure 3 .
Figure 3. Coordinate diagram of each joint of the upper limb.

Figure 4 .
Figure 4. Range of upper limb motion trajectories.Figure 4. Range of upper limb motion trajectories.

Figure 4 .
Figure 4. Range of upper limb motion trajectories.Figure 4. Range of upper limb motion trajectories.

Figure 5 .
Figure 5. (a) Exploded view of MR joint damper; (b) MR joint damper model and real picture.

Figure 5 .
Figure 5. (a) Exploded view of MR joint damper; (b) MR joint damper model and real picture.

Figure 6 .
Figure 6.Electromagnetic simulation of MR joint damper.(a) Simulation setting.(b) Cloud image of magnetic field distribution.(c) The magnetic field strength of the damping channel.

Figure 6 .
Figure 6.Electromagnetic simulation of MR joint damper.(a) Simulation setting.(b) Cloud image of magnetic field distribution.(c) The magnetic field strength of the damping channel.

Micromachines 2024 , 15 Figure 7 .
Figure 7.The experimental device tests the relationship between the torque of MR joint damper and the current and speed.The experimental data on the relationship between the damping torque of different currents and displacement and velocity are used as the model training data.The parameters of the hyperbolic tangent model are identified by genetic algorithm and least square method[38].The set parameters c, k, α, β, and δ are current-dependent parameters, and a polynomial in the current is fitted to the parameters at different currents as follows:

Figure 7 .
Figure 7.The experimental device tests the relationship between the torque of MR joint damper and the current and speed.

Figure 8 .
Figure 8.Comparison between model and experiment (dashed line is experimental data; solid line is function fitting curve).

Figure 9 .
Figure 9. Hardware composition of the control system.

Figure 8 .
Figure 8.Comparison between model and experiment (dashed line is experimental data; solid line is function fitting curve).

Figure 8 .
Figure 8.Comparison between model and experiment (dashed line is experimental data; solid line is function fitting curve).

Figure 9 .
Figure 9. Hardware composition of the control system.

Figure 9 .
Figure 9. Hardware composition of the control system.

Figure 13 .
Figure 13.Motion diagram.Since the velocity of the rehabilitation motion of the hand is random and uncertain, the velocity difference between the input end and the output end of the MR joint damper changes in real time.By monitoring the change in velocity differential, the excitation current is adjusted in real time according to the reverse dynamic model of the MR joint damper and the human-computer interaction model, to realize stable tracking of the end force output.As shown in Figure14a, the speed of the affected limb varies randomly during rehabilitation exercise, during which the excitation current varies in real time from a maximum of 1.91 A to a minimum of 1.10 A (in line with the given current range 0-2 A).As shown in Figure14b, the end sensor monitors the change in the human-computer interaction force during the operation of the rehabilitation device.The expected torque is set to 20 N, the average output expected torque is 20.02 N, and the standard deviation is 0.635 N during operation.The output torque has good stability.Micromachines 2024, 15, x FOR PEER REVIEW 12 of 15

Figure 14 .
Figure 14.Upper limb rehabilitation exercise.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.

Figure 14 .
Figure 14.Upper limb rehabilitation exercise.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.

Figure 14 .
Figure 14.Upper limb rehabilitation exercise.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.

Figure 15 .
Figure 15.Safety testing.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.Figure 15.Safety testing.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.

Figure 15 .
Figure 15.Safety testing.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.Figure 15.Safety testing.(a) Velocity change and current change; (b) the end sensor monitors the change in the human-computer interaction force.

Table 4 .
MR joint damper hyperbolic tangent model parameter identification results.

Table 4 .
MR joint damper hyperbolic tangent model parameter identification results.