Medical Engineering & Physics 28 (2006) 177–186
Technical note
A system for the delivery of programmable, adaptive stimulation intensity envelopes for drop foot correction applications P.P. Breen, D.T. O’Keeffe, R. Conway, G.M. Lyons ∗ Biomedical Electronics Laboratory, Department of Electronic and Computer Engineering, University of Limerick, National Technological Park, Limerick, Ireland Received 11 December 2003; received in revised form 4 March 2005; accepted 8 April 2005
Abstract We describe the design of an intelligent drop foot stimulator unit for use in conjunction with a commercial neuromuscular electrical nerve stimulation (NMES) unit, the NT2000. The developed micro-controller unit interfaces to a personal computer (PC) and a graphical user interface (GUI) allows the clinician to graphically specify the shape of the stimulation intensity envelope required for a subject undergoing drop foot correction. The developed unit is based on the ADuC812S micro-controller evaluation board from Analog Devices and uses two force sensitive resistor (FSR) based foot-switches to control application of stimulus. The unit has the ability to display to the clinician how the stimulus intensity envelope is being delivered during walking using a data capture capability. The developed system has a built-in algorithm to dynamically adjust the delivery of stimulus to reflect changes both within the gait cycle and from cycle to cycle. Thus, adaptive control of stimulus intensity is achieved. © 2005 IPEM. Published by Elsevier Ltd. All rights reserved. Keywords: Functional electrical stimulation (FES); Drop foot stimulator; Stimulation intensity envelope
1. Introduction The use of FES for the correction of hemiplegic drop foot is well established. Liberson et al. [1] used a rectangular stimulation intensity envelope in an attempt to correct hemiplegic drop-foot. One of the features of drop foot correction using FES is that the user should be able to walk independently of FES, as stimulus is typically only delivered to the common peroneal nerve, to provide foot lift and some knee flexion. Thus, in order to apply FES for drop foot correction, all the other elements of locomotion must be sufficiently intact to facilitate independent walking, albeit impaired. The stimulation intensity envelope is the signal describing how stimulation intensity varies during the gait cycle. For Liberson, stimulation intensity underwent a step function switch-on at heel-off and a step-function switch-off at heel contact. Thus, the intensity envelope was rectangular in shape. ∗
Corresponding author. Tel.: +353 61 202621; fax: +353 61 338176. E-mail address:
[email protected] (G.M. Lyons).
Electronics technology has evolved a great deal since 1961, as have the methods used to combat drop-foot [2]. Vodovnik et al. [3] proposed adding adjustable ramp-up and ramp-down periods to the stimulation intensity envelope. The ramp-up period was used to avoid rapid contraction of the tibialis anterior, which could cause a spastic reaction of the calf muscle and a ramp-down period was used to avoid footflap due to rapid cessation of stimulus. Burridge et al. [4] described the use of a single-channel hard-wired stimulator, the ODFS, which had adjustable, delay times after heel-off and adjustable extension times after heel-strike. When these features are added the stimulation intensity envelope is trapezoidal in shape as shown in Fig. 1. While most commercial stimulators use the trapezoidal stimulation intensity envelope [4–6], there is no evidence that this intensity envelope is optimum for drop foot correction. An examination of the tibialis anterior muscle activation pattern and the trapezoidal stimulation intensity envelope with respect to the gait cycle (Fig. 1) suggests an apparent mismatch between what is biomechanically required of the tibialis anterior muscle and what is being
1350-4533/$ – see front matter © 2005 IPEM. Published by Elsevier Ltd. All rights reserved. doi:10.1016/j.medengphy.2005.04.008
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
178
Fig. 1. Trapezoidal stimulus intensity envelope (stimulus commences at the heel-off event, when it is ramped up to a maximum value, under the control of a ramp-up time, stimulus is then maintained constant until the heel-strike event when it is linearly ramped down to zero stimulus under the control of the ramp-down time) and tibialis anterior activation pattern vs. gait cycle.
elicited by FES using a trapezoidal stimulation intensity envelope. In fact, work by Stanic et al. [7] with a surface drop foot stimulator and by O’Halloran et al. [8] with an implanted drop foot stimulator suggests that significant improvement in orthotic performance can be achieved using more complex stimulus intensity shapes. Malezic et al. [9] designed a dual-channel stimulator with a separate programmer unit with independent settings of stimulation sequences for both channels during the stance and swing phases of gait. Malezic’s system allowed the clinician to specify when stimulus for a particular channel was ON and when it was OFF, with the gait cycle divided into 16 zones where this ON/OFF control could be applied. However, this system did not allow arbitrary shapes for the stimulation intensity envelope shape to be specified, which is a significant limitation in view of the findings of O’Halloran et al. [10] and Stanic et al. [7]. This paper describes the development of an intelligent drop foot stimulator with the ability to program a stimulation envelope of any shape and which adjusts in real-time the delivery of the stimulus to reflect acceleration and deceleration of the patient.
2. Method The developed system interfaced an existing, clinically approved and commercial muscle stimulator, the NT2000 from Neurotech,1 with an Analog Devices2 micro-controller evaluation board (ADuC812S) and provided PC-based software 1 2
BMR Ltd., Galway, Ireland. Analog Devices BV Ltd., Limerick, Ireland.
to enable graphical specification of the stimulus envelope and diagnostic feedback on the operation of the unit on a patient. The NT2000 includes a programming unit, which allows stimulus pulse-width, frequency, on/off time and ramp up/down time to be adjusted. The NT2000 uses an on-board digital-to-analogue converter (DAC) whose reference voltage determines the maximum stimulus amplitude and which is normally internally set at the maximum 5 V. If a modulating 0–5 V signal were applied to the voltage reference pin of the NT2000’s DAC, this would allow real-time dynamic adjustment of the stimulus envelope. In the developed system, the required modulating signal is provided by an analogue output on the micro-controller board (ADuC812S). This arrangement is shown in Fig. 2. The value of the modulating signal is determined using a 1D lookup table of 12-bit values stored in the board’s data RAM. The stored value used is based on the position of the user in the gait cycle and uses a system of estimation to deliver the stimulation envelope at the correct time. The heeloff, heel-strike, toe-off, toe-contact and stride times from the previous stride are recorded and used as an estimate of the event and stride times for the current cycle. Two force sensitive resistors (FSR), under the heel and toe of the subject allow the current gait position to be known at all times. The stimulation envelope is set graphically using the PC-resident GUI and this data can then take the form of a 1D lookup table, which is subsequently downloaded to the ADuC. Using the estimation of stride time, coupled with the known lookup table size a simple calculation will determine the output index value, as shown in Eq. (1). index =
current stride time × look-up table size expected stride time
(1)
The micro-controller uses information from the previous gait cycle to determine the delivery of stimulus in the current cycle, based on the algorithm described in Eq. (2): current gait cycle elapsed (%) =
current gait cycle time × 100 adjusted previous stride time
(2)
where adjusted previous stride time is the previous stride time with a correction factor for acceleration/deceleration due to change in walking speed or stride length. Fig. 3 shows a flowchart describing the detection of the gait events and subsequent adjustment based on whether the event occurred before, after or at the time expected. A Visual BASIC3 interface was written to enable the stimulator system to be configured graphically using a PC prior to fitting on the patient. The toe-off, toe-contact, heel-off and heel-strike events are detected using two FSR-based footswitches and stance and swing phase durations are then derived and recorded for each stride. The delivery of stimulus in a given stride is determined using the stride time from the 3
Microsoft Inc., Redmond Washington, USA.
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
179
Fig. 2. A block diagram of the developed system showing interaction of GUI, micro-controller (ADuc812S) and NT2000.
previous cycle. The graphical interface approach allows customized stimulation intensity profiles to be provided for each user. 2.1. Stimulus envelope adjustment with changes in stride time The trigger signal for the delivery of the stimulus envelope is the heel-off event. The times that toe-off, heel contact and toe contact are expected to occur are compared with the actual times and the stimulus envelope is appropriately adjusted in real-time. If an event occurs before the expected time, the stimulation envelope is shifted backwards in time and the envelope is scaled down in time to reflect this. This is necessary as the gait event in question occurred before the expected time and thus, the subsequent gait events and stride time will probably occur sooner than expected. Variance in walking speed and/or stride length will cause successive stride times to be shorter or longer. The algorithm incorporated here uses a multiplier mechanism to estimate stride time for the current stride. To explain the operation of this algorithm, a linear stimulation intensity envelope will be used in the analysis: 1. If the next gait event has not occurred by the expected time, the stimulation intensity level is maintained constant at the level it was at when this event should have occurred, until the anticipated event does occur. 2. The stimulation envelope is now shifted forward in time following this event and the envelope’s rate of change with time is reduced to reflect the longer than expected stride time. 3. In Fig. 4, a dotted line shows the stimulation pattern applied if the event occurs at the time expected.
4. The dashed line shows the stimulation pattern adjusted to reflect the actual event time, if the event occurred after the expected time. 5. The solid black line shows the actual stimulation intensity envelope applied. The device incorporated a time-out which, if exceeded resulted in a system reset. This time-out was set as a percentage of stride time. If the time-out were set at 120%, the system would reset if any gait event failed to occur by 120% of the expected time for that event. 1. If the gait event occurs before it is expected, the preset stimulation intensity corresponding to that event is immediately delivered. 2. The stimulation envelope is shifted backward in time and the envelope’s rate of change with time is increased to reflect the shorter than expected stride time. 3. In Fig. 5, a dotted line shows the stimulation pattern applied if the event occurred at the expected time. 4. The dashed line shows the stimulation pattern adjusted to reflect the actual event time, if the event occurred before the expected time. 5. The solid black line shows the actual stimulation intensity envelope applied. 2.2. Sensor arrangement Two FSR devices4 were each configured in a voltage divider arrangement and the voltage outputs from these two units were input to two of the analogue inputs of the ADuC812S. 4 Department of Medical Physics & Biomedical Engineering, Salisbury District Hospital, Salisbury, UK.
180
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
Fig. 3. A flowchart showing operation of the algorithm when: (a) heel-off, (b) toe-off, (c) heel-strike and (d) foot-flat is expected.
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
Fig. 3. (Continued ).
181
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
182
Fig. 4. Adjustment of linear stimulus envelope if actual event-time is later than expected. Stimulation intensity level is maintained until the expected event occurs. Stimulation envelope is now shifted forward in time following this event and the envelope’s rate of change with time is reduced to reflect the longer than expected stride time.
Fig. 5. Adjustment of linear stimulus envelope if actual event-time is earlier than expected. The preset stimulation intensity corresponding to that event is immediately delivered. The stimulation envelope is shifted backward in time and the envelope’s rate of change with time is increased to reflect the shorter than expected stride time.
2.3. PC-based GUI
facilitate this, a screen was provided to the user that allowed easy specification of the envelope shape. By selecting a point on the X-axis, its corresponding value on the Y-axis could be changed and this change was seen almost instantaneously.
A design objective of the developed system was the ability to specify any stimulation intensity envelope shape. To
Fig. 6. GUI showing stimulation envelope that was set (top) and that that was subsequently recorded (bottom).
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
The number of points that may be adjusted can be varied between 10 and 50 depending on how detailed the user wants to make the stimulation envelope. Two linked views of the stimulation envelope were provided, a gait cycle view with the beginning of the screen view corresponding to the heel-strike event, which is the event conventionally marking the beginning and end of the human gait cycle and a stimulation cycle view (Top, Fig. 6), where the beginning of the screen view is the heel-off event, which is typically used as a trigger event for the delivery of stimulus in drop foot correction. Markers are provided on each screen view corresponding to where each of the four gait events of interest occurs (Fig. 6), these provide assistance to the clinician in the specification of the stimulus envelope. A list table on the left of the GUI allows the user to set the number of points on the graph that may be altered. Hence, for creating the traditional trapezoidal envelope, 10 points may be used, whereas for the graph of Fig. 6 for instance, up to 25 points may be used.
183
The GUI also allows the user to set sensor thresholds and these thresholds are included in the 1D lookup table of values sent to the micro-controller. The lookup table, which is specified by the clinician graphically using a PC-resident GUI, is sent from the PC via a serial link to the micro-controller’s serial port. As the stimulus envelope resident in the micro-controller’s memory has a direct effect on how FES is delivered to a subject, special attention was paid to ensuring that the version of the stimulation envelope graphically displayed on PC and the version stored in the micro-controller’s memory were identical. The following approach was adopted: 1. The PC-based software transmitted the look-up table contents as 12-bit words, with 000 HEX representing 0% and FFF HEX representing 100%. 2. Two parameters were calculated by both the PC and microcontroller software, the check-length and the checksum.
Fig. 7. Output of device with linear stimulation envelope with constant stride time.
Fig. 8. Output of device with bi-phasic stimulation envelope with constant stride time.
184
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
3. The check-length is the number of 12-bit words transmitted from the PC to the micro-controller. It is first calculated at the PC end and stored in local memory and then calculated at the micro-controller end on the basis of 12-bit words received by the micro-controller. The check-
length computed by the micro-controller is transmitted back to the PC where it is checked for a match with the PC-calculated check-length. 4. To calculate the check-sum, an accumulated binary sum of the transmitted 12-bit words are computed, this sum is
Fig. 9. Actual vs. theoretical output with linear stimulation envelope during: (a) acceleration, (b) deceleration and (c) at constant speed, with natural changes in stride length.
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
divided by 16 and the quotient and reminder from this division are stored locally by the PC. At the micro-controller end, an accumulated binary sum, of the received 12-bit words, is computed, this sum is divided by 16 and the quotient and reminder from this division are transmitted back the PC where a check for a match with the locally computer quotient and remainder is made. 5. If a mismatch in either the check-length or check-sum is detected, an appropriate message is issued and the stimulation profile is re-transmitted to the micro-controller. 2.4. Real-time display capability of the system Fine-tuning a drop foot correction system like this to meet the unique requirements of a particular subject can be difficult. Typically, a data acquisition system may be used to record the foot-switch and stimulus intensity signals while the person is walking to make sure that the footswitch threshold levels are correct and that the specified stimulus intensity envelope is appropriate. The subject’s gait would be observed and adjustments to the stimulation scheme proposed. The developed system facilitates this process by having a second mode of operation, using a data capture capability, where the stimulation intensity envelope signal output from the stimulator and the corresponding gait events are recorded and charted (Fig. 6). The top of Fig. 6 shows the stimulation envelope that was downloaded to the device. The lower part of the figure shows the signal output of the stimulator. It may be noted how the algorithm behaved when events did not occur at the time expected. This facility potentially eliminates the need for an expensive data acquisition unit and allows the clinician to determine, from the sensor activity, if the threshold values are correct and, from the applied stimulus signal, if the stimulus is being properly delivered. Thus, the stimulation envelope that is set can be compared to the envelope that is actually recorded.
3. System test The system was fully bench tested to confirm performance to specification and was also tested under gait conditions, with a healthy subject fitted with heel and toe switches. The University of Limerick Research Ethics Committee approved the test procedures used to evaluate the system and the test subject gave informed consent prior to testing. The system was tested with a healthy subject walking on a treadmill with a data acquisition unit recording footswitch voltage levels and output from the system. Three performance tests were completed: • Consistency test—To show that the system consistently and continuously output the stimulation envelope in a
185
cyclic manner. Fig. 7 shows the result for a linear stimulation envelope. Note that the period of consecutive simulated strides are similar and the output changes from 0 to 5 V in proportion to time. This test shows that without any change in stride time the system will constantly regenerate the same stimulation envelope and output the complete stimulation envelope as was expected. • Continuity test—To show that the system will operate with a variety of stimulation envelopes downloaded to the device. For this test, the output was recorded with the stimulation envelope changed to a bi-phasic one shown in Fig. 8. Fig. 8 shows that without any change in stride time, the system will constantly regenerate the same stimulation envelope and output the complete stimulation envelope as was expected irrespective of the downloaded stimulation envelope (Fig. 6). • Actual output versus theoretical output—The footswitch voltage levels were processed using the algorithm implemented in MATLAB and this theoretical output was compared to the actual output. A match was obtained during acceleration, deceleration and at a constant walking speed with natural changes in stride length (Fig. 9) showing that the algorithm as described was correctly implemented on the micro-controller. Acceleration/deceleration may be noted by the shortening/lengthening of the stride time.
4. Discussion and conclusions A working system for the delivery of a customised stimulus intensity envelope has been successfully developed. The developed system allows an infinite number of complex stimulus intensity envelope shapes to be applied. The system has a novel algorithm for the adjustment of the delivered intensity envelope to reflect changes in stride time as would occur during acceleration and deceleration. The ability to predict the next gait event accurately is essential for applying complex stimulation envelopes where the stimulus needs to be applied prior to gait events. Preliminary testing of the system on a healthy subject is promising with the stimulus control signal being dynamically adjusted to reflect changes in stride time. Further testing will be carried out on patients with drop-foot pathology. Like most drop foot stimulators, the system has the limitation that the patient should not use the system when climbing stairs, as the output of the stimulator under those conditions may not be appropriate.
Acknowledgements We wish to acknowledge the support of Enterprise Ireland under the Research Innovation Fund (IF/2002/641) for the financial support of Mr. Breen and BMR Ltd., Galway, Ireland for the supply of the NT2000 stimulator.
186
P.P. Breen et al. / Medical Engineering & Physics 28 (2006) 177–186
References [1] Liberson WT, Holmquest HJ, Scott D, Dow M. Functional electrotherapy in stimulation of the peroneal nerve sychronized with the swing phase of gait in hemiparetic patients. Arch Phys Med Rehabil 1961;42:202–5. [2] Lyons GM, Sinkjaer T, Burridge JH, Wilcox DJ. A review of portable FES-based neural orthoses for the correction of drop foot. IEEE Trans Neural Syst Rehabil Eng 2002;10:260–79. [3] Vodovnik L, Dimitrijevic MR, Prevec T, Logar M. Electronic walking aids for patients with peroneal palsy. In: Presented at European Symposium on Medical Electronics. 1965. [4] Burridge J, Taylor P, Hagan S, Swain I. Experience of clinical use of the odstock dropped foot stimulator. Artif Organs 1997;21:254–60. [5] Pedersen E, Petersen T, Hansen C, Klemar B. Clinical experience with new peroneal stimulator. J Neuro Rehabil 1988;2:103–8. [6] Acimovic R, Gros N, Malezic M, Strojnik P, Kljajic M, Stanic U, et al. A comparative study of the functionality of the second generation
[7]
[8]
[9]
[10]
of peroneal stimulators. In: Presented at 10th RESNA Conference. 1987. Stanic U, Trnkoczy R, Acimovic N, Gros A. Effect of gradually modulated electrical stimulation on the plasticity of artificially evoked movements. Med Biol Eng Comput 1977;15:62. O’Halloran T, Haugland M, Lyons GM, Sinkjær T. Modified implanted drop foot stimulator system with PC-based GUI for customised stimulation intensity profiles. Med Biol Eng Comput 2003;41(6):701–9. Malezic M, Bogataj U, Gros N, Decman I, Vrtacnik P, Kljajic M, et al. Application of a programmable dual-channel adaptive electrical stimulation system for the control and analysis of gait. J Rehabil Res Dev 1992;29:41–53. O’Halloran T, Haugland M, Lyons GM, Sinkjær T. An investigation of the effect of modifying stimulation profile shape on heel rocker function, during FES-corrected drop foot. Neuromodulation 2004;7(2):113–25.