Mathematical and Computational Topics in Design StudiesView this Special Issue
Research Article | Open Access
The Design of EMG Measurement System for Arm Strength Training Machine
The setup of interactive communication between arm strength training machine and the people will make exercise and rehabilitation therapy become more friendly. The employment of electromyographic not only can help physical therapy but also can achieve more effective rehabilitation. Both of the system hardware and software of the arm strength training machine with EMG system are well designed and described. The fundamental design of electromyographic measurement system based on a microcontroller is analyzed and discussed. The software programming is developed in MPLAB integrated development environment from the Microchip Technology Inc. and the friendly user interface is created as well. Finally, an arm strength training machine with electromyographic control system is realized and demonstrated. The experimental results show the feasibility and fidelity of the complete designed system.
An arm strength training machine (ASTM) based on an embedded microcontroller system that utilizes a PMSM motor drive to simulate the stack of iron weights has better performance than that of the conventional exercise apparatus presented in . Several studies indicate that chronic stroke patients who gained maximal functional benefits from the biofeedback intervention initially had greater active range of motion at all major upper extremity joints [2–4]. Another study to investigate neuromuscular electrical stimulation initiated by a surface electromyographic biofeedback threshold on knee extension active range of motion (AROM), function, and torque in patients with postoperative arthroscopic knee surgery has been addressed in . It concludes that the usage of surface EMG-triggered neuromuscular electrical stimulation can improve the extension AROM. Consequently, the proper utilization of electromyographic biofeedback can lead to substantial improvements among selected chronic stroke patients and can be of considerable functional benefits to others [6, 7]. Therefore, the usage of EMG not only can help the physical therapy but also can achieve more effective rehabilitation [8, 9]. Conventional exercise apparatus typically couple a stack of iron weights through a series of pulleys and levels to hand grips . The stack of iron weights are usually mounted on guide rods for vertical reciprocal movement from a rest position upwardly against gravity force to an upper position. Lifting weights is accomplished by the user who actuates a bar or another device operably connected to the weights. To vary the force opposing the user, the user is required to change the position of mechanical locking pin and physically add or remove weights from the stack. This results in time consumption and inconvenience when user changes the exercise force level between lifts. These are drawbacks for such an exercise apparatus [11, 12]. To solve this problem, a closed-loop motor control system that can generate a user opposition force and more particularly simulate a weight stack is presented in . Therefore, in order to obtain more effective rehabilitation when manipulating the arm strength training machine (ASTM), an EMG system incorporated with the original functions is designed and implemented in this paper.
The EMG measurement mechanism consists of the EMG electrodes: the EMG amplification circuits and the band-pass filter [14, 15]. In order to obtain a “clean” signal that is without DC offset and high frequency noise, the output signal from the instrumentation amplifier is filtered by a band-pass filter which is formed by a high-pass filter cascaded with a low-pass filter. The clean signal is then rectified to DC value by using the rectifier circuit. The rectified signal is fed into the microcontroller. Accordingly, the signal can be used to display the contraction of muscle group when the user manipulates the ASTM . A PMSM (Permanent Magnet Synchronous Motor) drive controlling system based on the microcontroller is also developed in this paper to generate a torque to oppose the user force [17, 18]. The hardware circuits of the PMSM drive, such as AC/DC rectifier, DC link, DC/AC inverter, EMG sensors, physiological amplifier, high-pass filter, low-pass filter, Hall-effect position sensors, and speed encoder, are well designed, simulated, and implemented. The software programs are written in C language and programmed based on the MPLAB integrated development environment (IDE) tool by Microchip technology Inc. The PMSM motor drive is used to simulate the weight stack that is usually employed to the conventional exercise machines. Thus, the principle of EMG measurement system is firstly derived and described in Section 2. Later, the system hardware and software are designed and realized in subsequent Section 3. Section 4 will present the experimental results of ASTM and EMG measurement system for system verification. Finally, an arm strength training machine with electromyographic EMG measurement system is realized and demonstrated in the Conclusions. The Experimental Results show the feasibility and fidelity of the complete designed system.
2. The EMG Measurement System of ASTM
The system hardware of an arm strength machine with EMG measurement system based on PMSM motor drive is shown in Figure 1. It consists of a dsPIC30F4011 microcontroller, EMG measurement system, protection circuit, optical coupling isolation, inverter, current sensor, encoder, and communication interface. The PMSM motor drive is used to simulate the weight stack that is usually employed to the conventional exercise machines. The microcontroller dsPIC30F4011 manufactured by Microchip technology Inc. is the core controller of the ASTM. It is a 16-bit CPU with the capability of digital signal processing. Moreover, it supports many powerful modules such as built-in PWM module, addressable encoder interface module, and input capture module. This makes the design easily complete and thus it shortens the development schedule. The independent power source is employed to supply the gate of MOSFETs. The photocoupler TLP250 is used for electrical isolation between the microcontroller system and the high DC voltage bus voltage as well as the independent power source [19, 20].
The motor currents are sensed through the current detection circuit. The magnet pole and rotor position are detected by the Hall-effect sensor and the encoder. In such a way, the speed and rotor position can be calculated and precisely controlled, subsequently. The ACS 712-20 current sensor IC which has the resolution of 100 mV per ampere is adopted for stator phase current detection. Since the microcontroller supports a 10-bit analog and digital converter (ADC), the full scale of 5 V is corresponding to the 1024 bits. In other words, one bit of the ADC represents the 48.83 mA.
The biosignal amplification system shown in Figure 2 is used to amplify the electrophysiological signal which is generated from the physiological response inside the body, usually in microvolts level. These signals after amplification are processed for image processing and medical diagnosis. The EMG electrophysiological measurement is one of most popular applications of the biosignal amplification. The electrophysiological signals of muscle contraction and relaxation sensed by EMG sensors are then amplified by the physiological amplifier. From the acquisition of these after processing EMG signals, it can predict the strength of the muscle contraction and the situation of muscle motor so as to facilitate the rehabilitation or the exercise of patients. The EMG measurement mechanism consists of the EMG electrodes, the EMG physiological amplifier, high-pass filter, low-pass filter, and a full-wave rectifier, as shown in Figure 2. Two electrodes of EMG sensor are attached to the surface skin of an arm. A third electrode is attached to the common point for voltage reference. The potential difference is generated when the muscle group contracts and then fed into the instrumentation amplifier for amplification . Since the input resistance of an instrumentation amplifier is very high, it is suitable to pick up the EMG signal with high input resistance. In order to obtain a “clean” signal that is not DC offset and high frequency noise, the output signal from the instrumentation amplifier is filtered by a band-pass filter which is formed by a high-pass filter cascaded with a low-pass filter with the lower 3 dB frequency about 100 Hz and upper 3 dB frequency about 500 Hz. The clean signal is then rectified to DC value by using the rectifier circuit. The rectified signal is fed into the microcontroller. After proper processing, it is transmitted to the human interface via communication interface to display the contraction of muscle group when the user manipulates the ASTM.
The input physiological signal to the EMG sensor is usually in microvolt. In order to pick up this minute signal, an instrumentation amplifier with high input resistance of INA 2126 that is manufactured by Burr-Brown Corporation is used in this paper. Figure 3 shows the inside of INA 2126 instrumentation amplifier. It is a precision instrumentation amplifier for accurate, low noise differential signal acquisition. The transfer function between output and difference input can be expressed bywhere kΩ and kΩ. The resistor is the most properly selected to adjust the voltage gain since the other components need more than two resistances for voltage gain adjustment. is equal to 842 Ω for the voltage gain of 100 in this design.
Since the spectrum of EMG biosignal is usually between 50 Hz and 500 Hz. The cutoff frequency is designed to be 100 Hz in this paper. The second order high-pass filter designed in this paper is shown in Figure 4. The transfer function of high-pass filter can be expressed bywhere , , and . The lower cutoff frequency is The midband voltage gain is Regarding the high-pass filter design, also , , μF, kΩ, kΩ, and kΩ; the voltage gain is about 10 and the cutoff frequency is around 100 Hz.
The output signal from the high-pass filter is then fed to the second order low-pass filter as shown in Figure 5. The transfer function of the second order low-pass filter can be expressed as where , , and . The upper 3 dB frequency is and the midband voltage gain is Considering the low-pass filter design, also , , μF, kΩ, kΩ, and kΩ; the voltage gain is of 1.5 and the cutoff frequency is around 500 Hz. The voltage gain between the analog output signal of EMG measurement system, , and the differential input signal of EMG sensor, , can be expressed as where is the overall voltage gain of the instrumentation amplifier, high-pass filter, and the low-pass filter. In this case, is equal to 15000.
The equivalent circuit of a PMSM motor is shown in Figure 6. The stator phase voltage equations (, , ) related to the stator phase currents (, , ) and back electromotive force (, , ) for a PMSM motor can be expressed by the following:where , , and , represent the phase resistance for each phase, , , and represent the self-inductance for each phase, , , and represent the mutual inductance between either of the two phases, and , , and represent the back EMF for each phase.
If a three-phase balanced system is considered, the stator voltage in the following equation can be rearranged to
In steady state, the air gap power is expressed in terms of the electromagnetic torque and speed as
Hence the electromagnetic torque can be represented as
Rearrange (12), the electromagnetic torque can be expressed by
The load model can be expressed in terms of the motor speed, , a moment of inertia, , in kg-m2/sec2 with a viscous friction , in N-m/rad/sec. The electromagnetic torque, , in N-m then drives the load torque, , in N-m as represented in (13) .
The actual force displayed in the human interface panel is obtained from the motor torque. The relationship between developed torque and the total current is in (12). Since the current is captured by current sensors and converted to 10-bit digital signals, the ACS 712-20 current sensor which generates 100 mv for 1 A current flowing is used in this system. If 5 volts’ reference voltage is employed for ADC converter, the actual force can be expressed by where is the digital value of actual force displayed in the human interface panel, is the total motor current, is the torque constant of the PMSM motor and equal to 10.724 kgf-cm, and is the conversion factor, with 48.83 mA per bit in this case and subject to change if different current sensor is used.
3. The System Software Development
The system software program is developed under MPLAB IDE software platform and written in C language. Most of the functions of electric bicycle are programmed in the microcontroller firmware which includes the circuit protection mechanism, the ADC converter for EMG system, PWM generation, motor currents calculation, rotor position and speed calculation, and rotor pole position. The system software structure for microcontroller firmware is shown in Figure 7. The initializations for I/O configuration, Timer 1, Timer 2, ADC, and PWM settings are firstly processed in the main program.
Most of the ASTM functions are programmed in the microcontroller firmware which includes the circuit protection mechanism, the analog to digital converter for EMG system, PWM generation, motor currents calculation, rotor position and speed calculation, rotor pole position and the transmission and receiving of communication interface as shown in Figure 7. The flowchart of the main program for microcontroller firmware is shown in Figure 8. Since the resolution of encoder is 2500 pulses per revolution. The value of the counter in the microcontroller will be 5000 counts. The motor speed is obtained from the difference between current counter value and the last counter value in which both are acquired from the Timer 2 in capture interrupt service routine as shown in Figure 9. The EMG analog signal input to the microcontroller is first converted to the digital signal via the ADC module embedded in the microcontroller. Accordingly, the human interface can display the same converted EMG signal as well. The human interface design related to the peripheral device can be found in the paper . The Capture Counter in Figure 9 represents the distance when motor runs. Consequently, the displacement of a user performing the arm exercise can be obtained. The relationship between the actual speed shown in the human interface display and the motor speed can be expressed aswhere is the speed displayed in human interface with the unit of cm/sec and is the radius of motor shaft with the unit of cm.
The communication between the ASTM and human interface is established by UART interface which is fulfilled with the RS232 serial communication standard. The EIA-232 drives/receives of MAX 232 which includes a capacitive voltage generator provides EIA-232 voltages from a 5 V supply. Hence, it can be used for proper voltage levels conversion so that the communication of microcontroller can meet the RS232 standard. The system software for human interface including serial communication program is developed on PC and written in C language. The firmware of ASTM is programming basically on the MPLAB development tool by Microchip technology Inc. as shown in Figure 7. The desired force command and desired speed command are transmitted to the ASTM via the UART communication interface. The programming flowchart is shown in Figure 10. Both the actual force and the actual speed, as well as the EMG signal, are received by the UART controller through the UART communication interface. The data of actual force, actual speed, and the EMG signal are scaled to the corresponding coordinate and saved in EXCEL data format.
The EMG signal is sampled every 1 ms. As discussed in Section 2, the signals from EMG sensors firstly go through the EMG amplification system and then feed to the microcontroller via the ADC converter. The real time EMG signals are then converted to the digital values and stored in the ADC buffer. In order to distinguish the real electric signal of the muscle activity from other noise interferences, a threshold voltage about 1 volt is adopted in EMG measurement system. In other words, the digital value is zero if the analog output EMG measurement system is less than 1 volt. This means that the sampled EMG muscle signal is less than 1 volt and is considered as the noise interference. In order to clearly observe the phenomenon of muscle activity while the user manipulates the ASTM, the 100 sampled EMG signals are averaged and denoted as . The together with real time current, speed are sent to PC human interface for panel display via the RS-233 communication interface. The detailed flowchart for the EMG process is shown in Figure 11. In this paper, the main aim of using the EMG sensors in the ASTM is to observe the muscle activity through the waveform of human interface display panel while user exercises the ASTM. Consequently, the user can increase more interest to do the exercise and more motivation for rehabilitation if physical therapy is required. Furthermore, the physician and physical therapist can understand the therapy progress as well as the practical conditioning of the patient’s rehabilitation by observing the phenomenon of muscle activity from the human interface display.
Therefore the envelope of the EMG waveform in the human interface display can represent the strength of muscle activity. The larger the envelope (amplitude) of the waveform is, the more strength the user exerts. The relationship between the analog output of EMG measurement system and the amplitude of the envelope for the EMG signal can be expressed by where is the digital output of EMG signal shown in human interface display, is the analog output of EMG measurement system, is the threshold voltage, is the digital output bias, and is the conversion ratio between the digital output of EMG signal and the analog output signal of EMG measurement system. The conversion ratio can be adjusted according to the user’s needs. The amplitude of EMG digital output increases as the becomes larger and decreases vice versa. Since a 10-bit analog to digital converter is employed in the system, both and have 10-bit data length. The digital output is adjusted due to the offset of EMG measurement system.
4. The Experimental Results
The prototype of arm strength training machine with EMG measurement system is tested under different load conditions in which they are fulfilled with the dynamometer. The manipulation of ASTM with EMG measurement system is operated via the designed human interface, as shown in Figure 12. Both of the desired force command of 5 kg-cm and desired speed of 10 cm/sec are displayed in the upper window of Figure 12. In order to simulate the practical situation of lifting weights, the actual torque of motor and actual speed when the user exercises are measured and displayed in real time as shown in the middle window of Figure 12 as well. The experiment is cyclically completed by pulling the handle bar of ASTM for 10 seconds and then releasing for next 5 seconds. The experiment is repeated by the same cycle. Observing the waveform of Figure 13, it can be seen that the motor develops about 5 kg-cm of torque to counter the force exerted by user. This verifies the system design feasibility. The data displayed in Figures 12 and 13 are firstly saved in the memory and then sketched by using the Microsoft EXCEL software.
The EMG measurement system is basically composed of high-pass filter and low-pass filter. Two different frequencies of input signal are applied to high-pass filter for frequency response testing, one is 50 Hz in which it is in stop band and the other is 100 Hz in pass band. The high-pass filter has a voltage gain of 20 dB. The upper and lower traces of Figure 14 represent the waveforms of input and output signals, respectively. It can be seen that the output signal is attenuated to 6.6 dB at 50 Hz. The input signal of frequency at 100 Hz is applied to the high-pass filter as shown in Figure 15. Observing Figure 15, the amplitude of output signal is equal to 0.707 of that of the input signal. In other words, there is a 3 dB difference between the amplitude of input and output signals. The Bode plot of magnitude response for the high-pass filter is shown in Figure 16. The same testing method for high-pass filter can be applied to low-pass filter. The designed low-pass filter has voltage gain of 1.5. Figure 17 shows the waveforms of output and input signals at the frequency of 500 Hz. The different frequency of 1 kHz for input signals is also tested. The results are shown in Figure 18. The Bode plot of magnitude response of low-pass filter is shown in Figure 19. From the observation of Bode plot in Figure 19, it can be seen that the magnitude of the output signal for the frequencies above the 500 Hz is reduced; on the contrary, below the 500 Hz it stays flat. The cutoff frequency of 500 Hz is the same as that designed in this paper.
In this preliminary test, the experimental results amplitude of EMG envelope which is obtained from the in (16) are depicted in the bottom graph of Figure 12 for , , and V. The experimental test for this waveform is processing when the user manipulates the ASTM with EMG electrodes attached in the bicep brachii under the conditions of desired force = 5 kg and desired speed = 10 cm/sec. The user cyclically pulls and releases the handle bar of the ASTM. The motion of bicep muscle is then captured by EMG sensors and displayed in the human interface display. The corresponding real time EMG waveform of oscilloscope for is shown in Figure 20. Due to the difficulty of synchronization between human interface and the oscilloscope, the four envelopes of EMG signal in oscilloscope are corresponding to the last four envelopes of waveform in the graph of human interface display. The zoom in EMG waveform within 100 ms is shown in Figure 21. The peak amplitude of EMG signal is about 4 volts as seen from Figure 20. It is about 580 for corresponding digital output according to (16). The experimental results demonstrate and verify the feasibility and integrity for both EMG measurement system and human interface display. Since EMG signal represents the biophysical information of the muscle activity. The average voltage of EMG sensor can be considered as the contraction of the muscle group of bicep. The peak amplitude of EMG signal is then the phenomenon of severe motion of muscle activity. Consequently, all phenomena of motion for muscle activity can be demonstrated in the human interface display designed in this paper. Therefore, the physician and physical therapist can understand the therapy progress as well as the practical conditioning of the patient’s rehabilitation by observing the phenomenon of muscle activity from the human interface display. The practical system configuration of designed ASTM with EMG sensor is shown in Figure 22.
The establishment of EMG measurement system in ASTM can make the exercise and rehabilitation therapy become more friendly and effective. This paper designs an EMG physiological amplifier system to monitor the muscle activity of the user when manipulating the ASTM. From the experimental results, the system hardware including the microcontroller, protection circuit, optical coupling isolation, three-phase inverter, current sensor, EMG sensors, encoder, and communication interface is well designed. Though only the desired force of 5 kg and desired speed of 10 cm/sec is tested in the experiment, the force up to 15 kg and down to the 0.5 kg have been well-tested in practice for verification of system integrity. The voltage gain of the instrumentation amplifier is designed to be 100. Because the extremely small signal is not easy to generate in the lab, the designed instrumentation amplifier is tested by using circuit simulation. However, the EMG physiological signal of biceps brachii inputted to the instrumentation amplifier is amplified to appropriate voltage level as the experimental result presented. The relationship between the analog output of EMG measurement system and the amplitude of the envelope for the EMG signal displayed in human interface can be expressed by (16). However, these parameters in (16) are achieved from the preliminary tests of the experimental prototype system under the completion of few lab members. In order to obtain more exact and precise parameters, statistical method will be considered and employed to experimental tests, such as the placement of EMG electrodes and different sex and ages of testing samples, in future work. For testing of high-pass filter and low-pass filter, though only two different frequencies are applied to each filter in the experimental results, several frequencies located in stop band and pass band are also tested to complete the Bode plot. Further, the fundamentals of EMG measurement system have been derived, designed, and described in detail. The experimental results have verified the feasibility of each design procedure. Moreover, both of the microcontroller firmware and the user interface are programed and described in detail. Finally, an arm strength training machine with electromyographic sensors for biofeedback is realized and demonstrated in this paper. The experimental results show the feasibility and fidelity of the complete designed system.
Conflict of Interests
The authors declare that there is no conflict of interests regarding the publication of this paper.
The author thanks the Ministry of Science and Technology at Taiwan for the fund support under Project NSC 102-2221-E-035-047 for its help in the completion of this work.
- T.-Y. Ho, Y.-J. Chen, M.-S. Chen, P.-H. Chen, and H.-Y. Chen, “The design and implementation of arm strength training machine,” in Proceedings of the IEEE EuroCon, pp. 1911–1914, Zagreb, Croatia, July 2013.
- S. L. Wolf, “Electromyographic biofeedback applications to stroke patients. A critical review,” Physical Therapy, vol. 63, no. 9, pp. 1448–1459, 1983.
- G. Francisco, J. Chae, H. Chawla et al., “Electromyogram-triggered neuromuscular stimulation for improving the arm function of acute stroke survivors: a randomized pilot study,” Archives of Physical Medicine and Rehabilitation, vol. 79, no. 5, pp. 570–575, 1998.
- J. Luczak, A. Bosak, and B. L. Riemann, “Shoulder muscle activation of novice and resistance trained women during variations of dumbbell press exercises,” Journal of Sports Medicine, vol. 2013, Article ID 612650, 6 pages, 2013.
- T. Boucher, S. Wang, E. Trudelle-Jackson, and S. Olson, “Effectiveness of surface electromyographic biofeedback-triggered neuromuscular electrical stimulation on knee rehabilitation,” North American Journal of Sports Physical Therapy, vol. 4, no. 3, pp. 100–109, 2009.
- S. L. Wolf and S. A. Binder-Macleod, “Electromyographic biofeedback applications to the hemiplegic patient,” Physical Therapy, vol. 63, no. 9, pp. 1393–1403, 1983.
- J. L. Kelly, M. P. Baker, and S. L. Wolf, “Procedures for EMG biofeedback training in involved upper extremities of hemiplegic patients,” Physical Therapy, vol. 59, no. 12, pp. 1500–1507, 1979.
- N. Mroczek, D. Halpern, and R. McHugh, “Electromyographic feedback and physical therapy for neuromuscular retraining in hemiplegia,” Archives of Physical Medicine and Rehabilitation, vol. 59, no. 6, pp. 258–267, 1978.
- O. Armagan, F. Tascioglu, and C. Oner, “Electromyographic biofeedback in the treatment of the hemiplegic hand: a Placebo-Controlled Study,” The American Journal of Physical Medicine and Rehabilitation, vol. 82, no. 11, pp. 856–861, 2003.
- F. Bugallo, “Weight lifting apparatus having increased force on return stroke,” U.S . Patent No. 4563003, 1983.
- P. Hon, “Apparatus for training, investigation and re-education in particular for the neuro-muscular function,” U.S. Patent No. 4979733, 1990.
- W. H. Englehardt, “Motor control for simulating weight stack-life fitness,” U.S . Patent No. 5020794, 1991.
- T.-Y. Ho, Y.-J. Chen, P.-H. Chen, and C.-H. Chiang, “The design and implementation of windowing interface arm strength training machine,” in Proceedings of the 1st IEEE Global Conference on Consumer Electronics (GCCE 12), pp. 201–202, Makuhari Messe, Tokyo, Japan, October 2012.
- C. Choi, S. Kwon, W. Park, H.-D. Lee, and J. Kim, “Real-time pinch force estimation by surface electromyography using an artificial neural network,” Medical Engineering and Physics, vol. 32, no. 5, pp. 429–436, 2010.
- F. Mobasser, J. M. Eklund, and K. Hashtrudi-Zaad, “Estimation of elbow-induced wrist force with EMG signals using fast orthogonal search,” IEEE Transactions on Biomedical Engineering, vol. 54, no. 4, pp. 683–693, 2007.
- E. E. Cavallaro, J. Rosen, J. C. Perry, and S. Burns, “Real-time myoprocessors for a neural controlled powered exoskeleton arm,” IEEE Transactions on Biomedical Engineering, vol. 53, no. 11, pp. 2387–2396, 2006.
- T.-Y. Ho, Y.-J. Chen, C.-T. Chung, and M.-H. Hsiao, “The design and implementation of a windowing interface pinch force measurement system,” in Advanced Biomedical and Clinical Diagnostic Systems VIII, Proceedings of SPIE, January 2010.
- H.-X. Wu, S.-K. Cheng, and S.-M. Cui, “A controller of brushless DC motor for electric vehicle,” IEEE Transactions on Magnetics, vol. 41, no. 1, pp. 509–513, 2005.
- J. Holtz and N. Oikonomou, “Estimation of the fundamental current in low-switching-frequency high dynamic medium-voltage drives,” IEEE Transactions on Industry Applications, vol. 44, no. 5, pp. 1597–1605, 2008.
- P. Pillay and R. Krishnan, “Modeling, simulation, and analysis of permanent-magnet motor drives. I. The permanent-magnet synchronous motor drive,” IEEE Transactions on Industry Applications, vol. 25, pp. 265–273, 1989.
Copyright © 2015 Tze-Yee Ho et al. This is an open access article distributed under the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.