DESIGN AND IMPLEMENTATION OF A FPGA BASED PORTABLE SYSTEM FOR ECG SIGNAL ACQUISITION, PROCESSING AND MONITORING

Prashant Agrawal, Abhijeet Kumar, Ajit Pal

Department of Computer Science & Engineering, Indian Institute of Technology Kharagpur
Kharagpur INDIA 721302

E-mail:

Abstract

Electrocardiogram (ECG) is the most commonly used biomedical signal for diagnostic purpose. It can be used to diagnose heart disease, identify cardiac arrhythmias, and evaluate effect of drugs. In this paper, the design and implementation of a FPGA based system and the techniques used to delineate the ECG signal are presented. We are designing and implementing a FPGA based system for clinical use. It can be used to acquire ECG signal from the patient and display it on a graphical LCD. The signal is analyzed to delineate PQ, QRS and ST complexes and derive parameters like heart beat rate and PR, PQ and QT intervals. There are several options to transfer the data from our system to a computer. The data can be stored in a USB thumb drive, which in turn can be sent to the desired location. The system can be directly connected to a local computer through the USB port. It can also be connected to a remote computer using a dial-up connection through an external modem. The system adheres to the standards and protocols specified by HL7.

1. Introduction

India’s 1 billion populations are predominantly rural and distributed in distant geographical locations apart from the high-density urban areas. The quality and availability of medical facilities is far from satisfactory in non-urban areas. Adaptation of telemedicine technology offers one of the best solutions for delivering healthcare facilities in rural and geographically distant locations [1, 2].

The objective of our project is to design and implement the IC for a low-cost, easy-to-use portable 12-lead ECG signal acquisition, processing and monitoring system. It would be possible to use the proposed system with little training by healthcare personnel at places where adequate medical/ treatment facilities are not available. Our project is being sponsored by Ministry of Human Resources Development under their initiative to promote and implement Telemedicine in India.

This paper presents the design of a FPGA based system. We have developed it as a prototype for the design of a single ASIC which will integrate the analog front end, digital backend and controllers of external peripherals like LCD module, MODEM & USB port. There are several advantages of an ASIC implementation. First, it leads to reduction of the physical dimension of the system. Second, ASIC along with advanced CMOS process technology will lead to reduction in power consumption of the system. Third, ASIC will lower the cost of the system for high volume production. Fourth, ASIC leads to improved system reliability. By using an ASIC no unreliable and unstable external components are needed. This has the effect of increasing the reliability of the system as a whole. Furthermore, an ASIC also uses less external connections (wires or copper strips), which may induce unwanted electro-magnetic fields affecting ECG recording.

The proposed system is intended to be a portable and battery operated device. Hence, power optimization is our major focus in designing the system.

The paper is organized as follows. Section 2 gives a description of the architecture of the system which is spread over several subsections. Section 3 provides the concluding remarks besides outlining the future scope for this work.

2. Architecture of the system

The complete system consists of an analog front end and a digital back end. The analog front end acquires ECG signal from the patient’s body, amplifies, filters and digitizes it. The digital output is then received by the digital back end.The focus of this paper is thedesign of the digital back end. The datapath of the architecture of the digital portion is shown in Fig.1.

The main elements of the system’s architecture are signal acquisition unit, signal storage unit, user interaction unit, signal processing unit and communication unit.

Details of these units are given in the subsequent sub-sections. We have implemented the


Fig. 1 Datapath of the architecture of the system

controller of the system using the micro-programmed approach rather than the hardwired approach.

Telemedicine is still in nascent stage in India and its standards and protocols are continuously evolving. Micro-programmed controller will give us the flexibility to modify the system when newer versions of standards and protocols come up and the requirements or system specifications change.

2.1 Signal acquisition unit

ECG signal has a bandwidth of 0.05–200Hz. According to Nyquist’s rule the sampling frequency (fs) should be greater than the twice of the highest frequency contained in the signal being sampled. Thus fs for ECG signal should be greater than 400Hz. Hence we have selected fs of 500Hz for our system.

The Signal Acquisition Unit (SAU), shown in Fig. 2, acts as a controller of the Analog-Digital Converter (ADC) block. ADC is read only when the start signal is asserted and the system is in scroll mode.

In this case, the SAU unit asserts ADC_RD every 0.2ms to read the ADC output (ADC_DATA). After reading theoutput, it asserts the ADC_WR to start ADC conversion again. The data read from the ADC is written into thememory (Memory_Data).

Fig. 2 Signal Acquisition Unit

Fig. 3Signal storage unit


The ADC is stopped being read when either the mode is freeze or the Stop signal has been asserted.

2.2 Signal Storage Unit

The Signal Storage Unit (SSU), shown in Fig. 3, consists of a Memory Controller and the Memory. The memory being used is a dual-port Sequential Access Memory (SAM). We had a choice between SRAM and SAM. We opted for a low power implementation of SAM based on [4]. It is advantageous to use SAM when the application requires sequential read/ write accesses to the memory. In our system, the read/ write accesses to the memory are strictly sequential. Besides, SAM eliminates the power dissipation due to address decoding and the power dissipation is almost independent of the memory size [4].

The Memory_Data from the Signal Acquisition Unit is stored in the memory. Doctors recommend that at least 4 cycles of ECG signal are required for proper diagnosis. Average heart beat rate in humans is 72 bpm (~0.833 secs per beat). Thus the duration of 4 beats is approximately 3.3secs. An ECGrecording of 3.3secsgenerates 1667 data values. We are using memory block of 2K words for each lead. Since our system is a 12-leadsystem, the memory consists of 12 banks and each bank is of 2K word (16bit) size. Data corresponding to aparticular lead is stored into a particular pre-assignedblock.

2.3 User Interaction Unit


There are two user interfaces of the system – keyboard and the graphical LCD. The keyboard is interfaced with the Keyboard controller (Fig. 4).

The keyboard contains 12 keys. Each key is directly connected to the keyboard controller. The controller continuously senses the keys and generates an interrupt (Key Press) for the main controller whenever state of any key changes. The keyboard controller keeps the ‘Key Press’ signal asserted till it receives the ‘Key Press Ack’ signal



Fig. 4 Keyboard Controller

from the maincontroller. The main controller also asserts the ‘Read Key’ signal to read the 4bit output of the keyboard controller. This 4-bit number (Key No) uniquely identifies the key pressed.

A graphical LCD module has been used as the display of the system. It is used to display the acquired ECG signal and the user menu. We are using a 128x128 pixel graphical LCD which has an on-board 32K display RAM and T6963C controller [5, 6, 7]. The LCD controller, as shown in Fig. 5, is a part of our design and is used to interface the LCD module with our system. We are implementing the LCD controller using micro-programmed approachso that the controller can be easily modified if the external LCD module changes, giving more adaptability and flexibility to our system.

2.4 Signal Processing Unit

This unit analyzes and delineates the acquired ECG signal to extract the characteristic points of thesignal. Following are the parameters which are usually considered while diagnosing an ECG signal:

  • Time of onset, maximum and offset of P-wave, T wave and QRS segment


Fig. 5 LCD Controller

Fig.6 Steps of the algorithm for delineating the ECG signal

  • Amplitude of P-wave, T wave and QRS segment
  • Deviation of slope of ST segment
  • RR, PQ & QT intervals

Our method of signal delineation and parameter extraction is based on discrete wavelet transformation as suggested in [3]. The algorithm in [3] detects QRS

QRS complex, T and P waves from which other detailed characteristics can be obtained. The steps of the algorithm are shown in the Fig. 6.

2.5 Communication Unit

The system is proposed to be a hand-held device which can be carried to the field. ECG signal will be acquired there and stored on the system. Theacquired signal can be transferred to a computerthrough a USB port. It can either be stored in a USBthumb drive or the system can be directly connected toa local computer through the USB port.

We are using ISP1362 which is a commercially available off the shelf USB On-The-Go (OTG) controller [10]. ISP1362 acts as an interface between the USB port and the custom designed on-chip USB controller (Fig. 7). Our system will be dual role device; it acts as a host when connected to a thumb drive and as a peripheral when connected to the PC. The functionalities of the on-chip controller are:

  • Establish, maintain and terminate connection with a PC or thumb drive

Fig.7 USB Controller

  • Build packets for transferring data to a PC.
  • Store and retrieve data from a USB thumb drive

The system adheres to the communication standards and protocols specified by HL7 [8, 9].The on-chip controller has been implemented using micro-programmed approach so that the controller can be easily modified if the external COTS USB controller IC changes.

3. Conclusion

In this paper we have presented the design of a FPGA based system to acquire, monitor and process

ECG signal. At the time of writing this paper, we have completed the design and the initial implementation of the system. We have implemented the system using Xilinx ISE 7.1i tool suite and Spartan2 based Pegasus development board. Currently we are finalizing the implementation of the modem controller.

The future scope of this work is to implement the system which integrates the analog front end, digital back end, controllers of LCD, USB and Modem on a single IC. In the next phase of the project, we shall be working on the single IC implementation.

4. Acknowledgements

We are thankful to Xilinx Inc. for providing us the Xilinx ISE 7.1i tool suite and Spartan2 based Pegasus development board under their Xilinx University Program.

5. References

[1]
Technical Working Group for Telemedicine Standardization,“Recommended Guidelines and Standards for Practice of Telemedicine in India,”Department of Information Technology, Ministry of Communications and Information Technology, New Delhi, 2003

[2]Marilyn J Field, Telemedicine – A Guide to Assessing Telecommunications in Health Care, National Academy Press, Washington DC, 1996.

[3]C. Li, C. Zheng, and C. Tai, “Detection of ECG characteristic points using wavelet transforms”,IEEE Transactions on Biomedical Engineering, IEEE Volume 42 Issue 1, Jan. 1995, pp. 21-28.

[4]J. S. Moon, W.C. Athas, P. A. Beerel, and J. T. Draper, “Low-power sequential access memory design”, Custom Integrated Circuits Conference 2002, Proceedings of the IEEE 2002, 12-15 May 2002, pp. 111-114

[5]“Datasheet of LG121281 Graphical LCD Module”, Lampex Electronics Ltd.,

[6]“Datasheet of Toshiba T6963C LCD Controller”, Toshiba Corporation, 7 April 1997

[7]“Application Notes for the T6963C LCD Graphics Controller Chip”, Toshiba Corporation, Oct 1995

[8]

[9]P. Ganguly, and P. Ray, “Telemedicine over enterprise-wide networks: a case study”, Global Telecommunications Conference 1998, IEEE Volume 2,8-12 Nov. 1998, pp. 1297-1302.

[10]“Datasheet of ISP1362 Single-chip USB On-The-Go Controller”, Philips Semiconductors, Dec 2004

[11]Jan Axelson, USB Complete: Everything You Need to Develop Custom USB Peripherals, Lakeview Research, 1999.