You are on page 1of 19

Int. J. Biomedical Engineering and Technology, Vol. 4, No.

3, 2010 257

Design and development of a wireless internet-based


ECG monitoring system for ambulatory applications

Vivek Agarwal*
Applied Power Electronics Lab,
Department of Electrical Engineering,
Indian Institute of Technology Bombay, Mumbai, India
E-mail: agarwal@ee.iitb.ac.in
*Corresponding author

Ranganadh Thatha
Multimedia and Streaming Solutions Department,
N K Electronics,
Plot 42, Sector 12,
Vashi, Navi Mumbai 400703, India
E-mail: ranganadh@iitbombay.org
E-mail: thatha.ranganadh@gmail.com

C. Chandramouli
Applied Power Electronics Lab,
Department of Electrical Engineering,
Indian Institute of Technology Bombay, Mumbai, India
E-mail: cmouli@iitb.ac.in

Abstract: The visual observation of the Electrocardiogram (ECG) signal(s)


helps in detecting the presence and nature of heart disease(s). This paper
presents the design and development of a portable ECG monitoring system
integrated with an ethernet link for secured transmission of real-time ECG data
using TCP/IP protocol to a remote terminal. To incorporate the advantages of
wireless internet technology for ambulatory applications, a highly configurable
and future proof model of ECG monitoring system, which can be easily
integrated with IEEE 802.11b/g, IP over GSM, CDMA networks and WiMAX,
is presented.

Keywords: ECG; electrocardiogram; EWS; embedded web server;


bio-telemetry; on-board ambulatory system; embedded Linux; HTML; CGI;
Java Applets; wireless internet; IEEE 802.11b/g; GSM; CDMA; WiMAX.

Reference to this paper should be made as follows: Agarwal, V., Thatha, R.


and Chandramouli, C. (2010) ‘Design and development of a wireless
internet-based ECG monitoring system for ambulatory applications’, Int. J.
Biomedical Engineering and Technology, Vol. 4, No. 3, pp.257–275.

Biographical notes: Vivek Agarwal received Bachelor’s Degree in Physics


from Delhi University, India in 1985, Master’s Degree in Electrical
Engineering from the Indian Institute of Science, Bangalore, India, in 1990,

Copyright © 2010 Inderscience Enterprises Ltd.


258 V. Agarwal et al.

and PhD in Electrical Engineering from the University of Victoria, Canada,


in 1994. After briefly working with Statpower Technologies, Canada, he joined
the Department of Electrical Engineering, Indian Institute of Technology
Bombay, India, where he is currently a Professor. His main fields of interest are
power electronics and electronic systems. He is a senior member of IEEE,
fellow of IETE and a life member of ISTE.

Ranganadh Thatha received a BTech in Electrical Engineering in 2001 from


Nagarjuna University, India, and an MTech in Electrical Engineering from
Indian Institute of Technology Bombay, India, in 2003. After completing his
studies, he joined a Mumbai-based start up company, where he developed
several innovative multimedia and streaming related technologies. He is
currently working as a Mentor of Multimedia and Streaming Solutions
department at N K Electronics, India. His research interests include patient
monitoring, home automation, video compression, streaming technologies and
multi-core, multi-OS-based system design.

C. Chandramouli obtained a Bachelor’s Degree in Instrmentation and Control


Engineering from Adhiyamaan College of Engineering, India. He is currently
pursuing a Master’s Degree in Electrical Engineering with specialisation in
Electronic Systems from the Indian Institute of Technology Bombay, India.
His research interests include electronic biomedical applications and image
processing.

1 Introduction

Heart attack is the most common cause of death among the heart related disorders.
Heart failure is a serious condition and can be cured only with timely detection and
diagnosis followed by proper medication. Heart attack occurs when the blood supply to a
part (myocardium) of the heart muscle is severely reduced or stopped. Deposition of fats
on the walls of coronary arteries, which supply blood to the heart, leads to their
blockage – a condition known as Coronary Heart Disease (CHD) (Santamore et al., 2004;
American Heart Association). A heart related disorder can also occur due to variations in
the wall thickness of the heart chambers and improper closure and opening cycles of the
valves.
The sino-atrial node in the right atrium of the heart initiates an electrical impulse
causing opening and closure of valves enabling the blood pumping activity. This impulse
spreads a voltage difference on the skin surface, which can be measured by placing
special (Ag-AgCl) electrodes at specific locations on the human body. The signals
measured through electrodes constitute the ECG of the heart – basically a set of
waveforms in time domain representing the electrical activity of the heart. A typical ECG
waveform of a healthy person is shown in Figure 1. In 1895, Dutch Physician Einthoven
published one of his seminal papers in which he identified and labelled five ECG waves
P, Q, R, S and T as marked in Figure 1. As ECG measurements are non-invasive,
it is widely accepted but proper location and electrical connection must be ensured
between the skin and the electrode to minimise the contact resistance. The electrodes are
fixed on the skin by tapes, and conductive gel is applied at the point of contact.
Development of a wireless internet-based ECG monitoring system 259

Figure 1 Typical QRS waveform of an ECG signal

A major issue with the treatment of heart ailments (as also in other types of disorders) is
the lack of specialist doctors within close proximity of the patient. In a heart attack case,
any delay in administering the required medication to the patient can have serious
repercussions. Even if the patient is driven to a nearby hospital (i.e., if it exists) in an
ambulance, there is a need for constant medical supervision. It is for such situations that
the internet is really handy. Internet provides a full duplex large bandwidth channel with
sufficient speed for the transfer of real-time diagnostic data and medical supervision.
Though appropriate signal conditioning (e.g., converting analogue ECG data into digital
domain) is required, it provides a reliable and fast communication medium.
Figure 2 shows an analogue data collection unit with an ethernet link for transmission
of data over internet. The concept of telemedicine came into existence due to the broad
bandwidth communication available for transfer of large amount of data that includes
voice and video streaming. A telemedicine system using internet through GPRS is
discussed by Ping et al. (2005). Research has also been done on deploying telemedicine
and choosing critical medical parameters for online diagnosis (Kong et al., 2000;
Kyriacou et al., 2001). The transfer of data through the commercially available wireless
channels like IEEE 802.11b/g, IP over GSM, CDMA networks and WiMAX provide
enough bandwidth, which improves the system reliability and the positioning of
local transceiver stations is optional in case of GPRS and CDMA link as the
data is routed through existing mobile towers. In the case of WiMAX, the distance
between adjacent transceiver stations can be 30 kms. The systems that are supposed
to communicate with each other via the internet need only have to communicate
using TCP/IP protocols. The medical diagnosis of a patient generates a large amount
of data, but this is hardly a problem because (Santamore et al., 2004) TCP/IP protocol
supports bulk transfer of data. Lovell et al. (2001) have discussed the storage of bulk
medical data, retrieved online during medical diagnosis. The following are the
advantages of such a system:
• It is possible to access the system via the web from any corner of the world.
For example, the ECG of a patient, suffering from a heart ailment, can be monitored
by a specialist doctor sitting hundreds of miles away.
• Irrespective of the place and time, diagnosis can be performed and suggestions can
be given by specialists in their respective fields.
260 V. Agarwal et al.

• Medical data generated out of a surgery/diagnosis can be readily made available to


the emergency critical care units, hospitals with research and development centres,
artificial limb manufacturers, mobility aid manufacturers for physically challenged
and pharmaceutical research centres, etc. (Guo and Moulder, 2004).
• The system comprises minimum hardware components, hence it costs less to extend
the network to rural areas.

Figure 2 Overview of a system with an ethernet communication link

The usefulness and convenience of operation, makes this system an obvious choice for
remote applications. As discussed earlier, monitoring of the heart condition is a perfect
case for web-based telemedicine and is the focus of this paper. This application needs
processing of ECG signals, which involves signal conditioning (e.g., to remove noise, to
amplify the weak signals, etc.) and Analogue-to-Digital (A/D) data conversion.
The logged data should then be packed with the protocol headers and transmitted over the
ethernet. Wireless connection to the internet provides flexibility to the transfer of data
while the equipment is on the move. Thus, an ECG measurement integrated with a
wireless Embedded Web Server (EWS) on an ambulance vehicle will enable critical data
available for online diagnosis during emergency situation. The scheme for data transfer
from an ambulance vehicle is shown in Figure 3.

Figure 3 Remote monitoring of ECG data from an ambulance unit


Development of a wireless internet-based ECG monitoring system 261

The aim of the work is to develop a portable, highly configurable and future proof model
of ECG data acquisition system, which would be able to acquire up to three ECG signals
and can easily be integrated with any of the wireless internet technologies (IEEE
802.11b/g, IP over GSM, CDMA networks and WiMAX). The proposed system is unique
in the following manner:
• It can be connected to Local Area Network (LAN) if the client and server are
connected to the same LAN.
• It could be connected to internet if client and server are far away from each other.
• It is easily configurable.
• It uses embedded Linux and has a rich set of peripherals. It is easily programmable.
The platform allows us to design a future proof system. The system is designed in such a
way that the digital data from the ECG can be coupled to any future wireless internet
technologies.
It must be pointed out that although this paper focuses on the ECG application, the
system can, in fact, be used for other applications like Electroencephalogram with
minimal modifications in the hardware and software.

2 Architecture of a web server-based data acquisition system

A web server mimics the function of a terminal server, but with application specific
hardware and software. Its operation is briefly explained here. A measurement system
with an ethernet interface operated in a remote location logs the data and sends it to the
control (monitor) room upon request. Here, the measurement system is the server
(data supplier) and the control and evaluation facility is the client (data consumer).
The server capabilities are embedded in to the data acquisition system, hence the name
“Embedded Web Server (EWS)-based data acquisition system” (Finkelstein et al., 1998;
Szymanski, 2000; Gupta and Ganz, 2004). Figure 4 gives an idea of this concept. In the
work presented in this paper, the EWS-based system is the ECG equipment, which acts as
the server and provides data (graphical/numeric) to the client through an internet browser.

Figure 4 Client–server model

A Linux kernel 2.4.14 resides in the hardware, hence necessary settings need to be made
to prioritise this application on the system. The architecture of the web server is shown in
Figure 5.
262 V. Agarwal et al.

Figure 5 Hardware architecture of the web server

The details of the various hardware components are briefly summarised here.
• Processor core: The processor acquires the data as well as communicates with the
ethernet controller. Therefore, it must have enough computing power to handle the
data acquisition and the ethernet control functions.
• Ethernet controller chip: To decrease the overhead on the master processor, a
separate dedicated processor is used to communicate with the internet. It takes care
of different protocols on the physical layer used in different types of networks.
• Memory: External memory is important for this application, because the on-chip
memory is not sufficient. One must add both SDRAM and permanent memory
(generally flash memory in development stage, ROM for final product) to store the
operating system and application software. A serial memory is used to store
permanent data (to store configuration data).
• Data acquisition: It is part of the ‘input device’ and includes transducers, analogue
multiplexers, sample and hold circuits and A/D converters.
• Display device: It is part of the ‘output device’ and is used for local display of the
status of the system. LED’s or LCD displays may be used for this purpose.
• Serial and parallel ports: These ports are used to interface any external devices and
for debugging purpose.
• RJ-45 connector and wireless connectivity: This is required to connect the EWS to
the LAN. The embedded devices may also be connected to the internet through a
MODEM for dial-up connection (telephone line). An IEEE 802.11 based wireless
LAN can be used to provide the data transfer path to the nearest node.
• Auxillary circuits: These circuits are essential for successful operation of the system.
They are clock, reset and booting circuit. Regulated power supply is necessary for all
the devices in the system. The system can be alternatively operated with a battery
power also.
Development of a wireless internet-based ECG monitoring system 263

3 ECG signal acquisition

This section deals with general aspects of ECG and also discusses the importance of
various components (filters and amplifiers) of the ECG signal acquisition system.
The heart is a muscle, which pumps blood for circulation. During its contraction and
expansion, it creates a bio-potential. This potential generates electrical currents, which
originate from heart and spread throughout the body. Owing to these electrical currents,
electrical potential is generated all over the body, which can be recorded. The waveform
produced by these potentials is called the ‘ECG’.

3.1 Standard lead system


In standard ECG recording, there are four electrodes connected to the Right Arm (RA),
Left Arm (LA), Left Leg (LL) and Right Leg (RL), respectively. RL acts as the return
path and the remaining three electrodes produce three waveforms with different
amplitudes with respect to RL (Lin et al., 2006; Kim et al., 2004). A pair (combination)
of two electrodes is called a ‘lead’and is represented by one of the sides of the dotted
triangle, called the Einthoven triangle, as shown in Figure 6. The resulting three leads are
connected to a separate differential amplifier as follows:
• Lead 1: The LA electrode is connected to the non-inverting terminal and RA is
connected to the inverting terminal of the differential amplifier.
• Lead 2: The LL electrode is connected to the non-inverting terminal and LA
electrode is connected to the inverting terminal of the differential amplifier.
• Lead 3: The LL electrode is connected to the non-inverting terminal and RA
electrode is connected to the inverting terminal of the differential amplifier.

Figure 6 Einthoven triangle

The magnitude of the ECG signal, obtained from the body of a human being, is in the
frequency range 0.05–100 Hz with typical amplitude of 1–2 mV (Carr and Brown, 2001).
Hence, the signal must be amplified before A/D conversion. As the signal is mixed with
low-frequency noise due to interference, the direct conversion after amplification
will contain the noise frequency components, so the amplification is done in two
phases – pre-amplification and main amplification, interleaved with high- and low-pass
filters.
264 V. Agarwal et al.

Lower frequency components are filtered using a high-pass filter with a cut-off
frequency of 0.05 Hz and the higher frequency components are filtered out using a
low-pass filter with a cut-off frequency of 100 Hz. Signal voltage is amplified to a
suitable level before connecting to the A/D converter. Figure 7 shows the various
subparts of an ECG amplifier circuit.

3.2 The surface electrodes


These are the transducers, which actually convert the bio-potentials into electric potential
so that the signal can be processed in the electronic circuit. There are different types of
electrodes available: strap-on electrode, suction-cup type electrodes and foam baked
column electrodes (Ag-AgCl electrodes).

Figure 7 Block diagram of the ECG amplifier for Lead 1

Generally, first two types of electrodes are used for a short period of time. Column-type
electrodes, which are generally used for monitoring a patient for a longer period, have
been used in this work. The electrode consists of a metallic button, which is
manufactured with Ag-AgCl metal. Column between this button and the body of the
patient is filled with a conducting gel, which reduces the impedance between the
electrode and the skin.

3.3 The pre-amplifier


Pre-amplifier is required to provide high-input impedance and high common mode
rejection ratio. The reasons are as follows: skin tends to have very high impedance
compared with other voltage sources. Typically, normal skin impedance, as seen by the
electrode, varies from 0.5 kΩ for sweaty skin surfaces to more than 20 kΩ for dry skin
surfaces. Dry or diseased skin may reach impedance in the range of 500 kΩ. So the
pre-amplifier should have high-input impedance. Generally, it should be 10 times the
impedance between the electrode and the skin. So, the pre-amplifier should have at least
5 MΩ input impedance. As the common mode noise (mostly from nearby power cables)
is prevalent, and sometimes the magnitude of this noise may become comparable with the
actual ECG signal.
So, the pre-amplifier should have a very high common mode rejection ratio.
Instrumentation amplifier INA118 has been used as the pre-amplifier in this work, as it
has extremely high-input impedance (104 MΩ) and high CMRR (107 dB). Figure 8
shows the pre-amplifier circuit. The preamplifier gain is kept less than 30 as the
amplification of the dc offset voltage, present in the input signal, may lead to a saturated
output.
Development of a wireless internet-based ECG monitoring system 265

Figure 8 Instrumentation amplifier

3.4 The high-pass filter


This filter is necessary because the acquired ECG signal always has some offset (DC)
voltage, which must be eliminated. Cut-off frequency of the high-pass filter is different
depending upon the case in hand, as given here:
• 0.05 Hz (for diagnostic quality ECG)
• 0.5 Hz (for monitoring)
• 2 Hz (for quick offset restorer).
In this work, a second order high-pass filter has been designed for diagnostic purpose.
So the cut-off frequency is set to 0.05 Hz. Figure 9 shows the high-pass filter circuit
implemented.

Figure 9 Schematic diagram of the high-pass filter for diagnostic quality ECG

3.5 The main amplifier


This module amplifies the ECG signal to sufficient level just before A/D conversion,
because the pre-amplifier gain is not sufficient. As described in Subsection 3.3,
the pre-amplifier gain is intentionally limited to a lower value to limit unwanted/noise
frequencies creeping into the system. To achieve good performance, the gain of the
high-pass filter is kept at unity.
A gain of 26 is provided by the instrumentation amplifier. The gain of the main
amplifier is set to 100. A potential divider is used to adjust the gain during calibration.
Figure 10 shows the schematic diagram of the main amplifier circuit.
266 V. Agarwal et al.

Figure 10 Schematic diagram of the main amplifier circuit

3.6 The isolation amplifier


To avoid the patients coming in contact with potential electrical contact, the patient’s
body should be isolated from the rest of the circuit. Two types of isolation are provided:
• power supply isolation
• signal isolation from the storage or display system (here EWS-based system).
Power supply isolation has been realised by using DC–DC isolated converter
– DCR010505P. For signal isolation, an isolation amplifier is used in between the main
amplifier and the low-pass filter. Since the high frequency noise produced by the
isolation amplifier is eliminated by the low-pass filter, the isolation amplifier is
introduced here.

3.7 The low-pass filter


As explained earlier, an ECG signal spectrum occupies 0.05–100 Hz range. So, it is
necessary to eliminate higher frequency components. So the cut-off frequency of the
low-pass filter is set to 100 Hz. Figure 11 shows the schematic diagram of the low-pass
filter.

Figure 11 Schematic diagram of the low-pass filter

3.8 The right-leg drive circuit


ECG amplifier circuit suffers from the noise created by the power supply lines.
Even though instrumentation amplifier reduces this noise, it is necessary to
reduce it further. The common mode voltage is inverted by the right-leg amplifier
as shown in Figure 12. This signal is given to the electrode connected to the RL of the
Development of a wireless internet-based ECG monitoring system 267

patient after amplification. To minimise the current flow, the common mode voltage is
fed to a voltage follower circuit instead of directly connecting to the inverting amplifier.
This circuit acts as a feedback loop to reduce the common mode noise to a low level.
As discussed in earlier subsections, a pre-amplifier with gain 26, a high-pass filter
with a cut-off frequency 0.05 Hz, a low-pass filter with a cut-off frequency 100 Hz and
an amplifier with a gain of 100 were designed and tested. The total gain of the ECG
amplifier is about 2600. This gain is fine tuned during calibration. A similar circuit has
been designed for the remaining two leads (lead 2 tapped from LL and LA, lead 3 tapped
from LL and RA).

Figure 12 The right-leg drive circuit

In the next stage, the three signals are multiplexed before giving to the ADC.
Burr-Brown’s ADS574 A/D converter has been used (Data sheet of ADS574). Data bits
of the ADC are connected to the parallel port of the Axis communication’s developer
board. The control bit of the A/D converter and the selection lines of the multiplexer are
connected to the control pins of the parallel port. The complete schematic diagram of the
hardware for Lead 1 is shown in Figure 13.

Figure 13 Schematic diagram of the ECG amplifier for one of the channels
268 V. Agarwal et al.

4 Software

The software for EWS includes both application specific software and TCP/IP protocol
suite. Figure 14 shows the required protocols for the web server and the various layers,
which constitute a TCP/IP stack. These are briefly explained next.
a Link layer. This layer includes the device drivers in the operating system and the
corresponding network interface card in the computer. Together, they handle all the
hardware details of the physical interface with the cable.
b Network layer. This layer, sometimes called the internet layer, handles the movement
of packets around the network. Routing of packets, for example, Internet Protocol
(IP) and Internet Control Message Protocol (ICMP) constitutes the network layer in
the TCP/IP protocol suite.
c Transport layer. In the transport layer there are two major protocols, which offer two
different kinds of services:
• TCP, which is a reliable delivery service and
• UDP, which offers an unreliable service.
TCP also offers flow control for re-transmission of segments and acknowledgement
of received segments.
d Application layer. The application layer handles the details of a particular
application. Common TCP/IP applications include:
• Dynamic Host Configuration Protocol (DHCP)
• Telnet for remote login (Telnet)
• Browser support for displaying web pages (HTTP)
• File transfer applications (FTP)
• E-mail applications (SMTP).
The three lower layers take care of communication details only.

Figure 14 TCP/IP Stack

4.1 Device drivers


An embedded system always communicates with an external device, through a device
driver and is the fundamental source of communication with the device. All computer
Development of a wireless internet-based ECG monitoring system 269

programs have input, processing and output paradigms. Application programs are mainly
concerned with processing, whereas the details of input and output are left to the
underlying operating system. Input and output hardware devices, such as keyboards, disk
drivers and monitors can only be accessed through special programs called device
drivers. Direct access to the devices is not permitted by the operating system,
so an application program has to go through device drivers to gain access (Khan, 2002).
Figure 15 shows how application programs communicate indirectly with the devices.
Device driver programs are modules that are basically part of the underlying
operating system, and are executed inside the memory space of the operating system
kernel. Most of the operating systems (for example, Linux) treat them as files.

Figure 15 Communication between devices and application programs

The application program can open, close, read and write to these device driver files.
But application programs are not allowed to open and close some device drivers like
keyboard and screen files – they are always open.

4.2 Configuring the kernel


Configuring the Linux kernel is very critical while preparing the Embedded Linux
operating system because target system memory is used for important data. During the
configuration, only the required device drivers should be selected, other drivers should be
disabled. For example, if the given application needs a parallel port driver, the
corresponding driver should be enabled, and if USB port is not necessary for the
application, the corresponding device driver should be disabled to limit the final kernel
image size.
Linux 2.4.14 kernel has been used in the development of the Embedded Linux
operating system for ETRAX100LX microcontroller (Document on “The Linux 2.4
Parallel Port Subsystem”). Axis Company provides kernel patch, which actually contains
architecture specific code. When the original Linux kernel is patched with the Axis’s
patch file, it replaces the architecture specific device drivers in the kernel with the
Axis’s specific drivers and also adds processor-specific device drivers, for example,
driver needed for the in-built network port (USB port etc.).
Kernel configuration can be done using make xconfig or make menuconfig in the
Linux source code directory. These two are graphical interfaces to the actual
configuration file. Using these interfaces, kernel can be easily configured, it also has
in-built help menu. At the time when configuring the kernel, care should be taken that the
270 V. Agarwal et al.

final kernel image does not exceed the flash memory partition size. After completing the
kernel configuration, the configuration settings are saved in .config file.

4.3 Memory partition


Flash memory in the target system is like a hard disk in a personal computer. Partitioning
of the flash memory is necessary. Some part of the memory is dedicated to storing
permanent information like the MAC address or serial number of the system. Some area
is dedicated to storing the kernel and root file system. These two partitions are read only
type. Remaining portion is used for storing the configuration information like IP address
of the target system. This part of the memory is both read and write type.
The flash memory is divided into the following partitions:
• Rescue partition. contains rescue code and read-only parameters set at factory, such
as serial number. It is written at the factory/distribution and normally not written to
after that. It can however be overwritten using the flashitall script.
• Kernel partition. The kernel that boots up the system is usually stored together with
the romfs (root file system). It can be compressed and the image then contains a
small piece of code that decompresses the kernel image. The partition table is stored
at the beginning of this partition.
• JFFS partition. Journaling Flash File System – a writable flash file system for
configuration files, custom applications, etc.
The partitioning of the memory depends upon the application. If the application needs
more read and write memory then the JFFS partition should be larger and if the
application needs more kernel image and root file system image, then kernel partition
should be larger.

4.4 Parallel port programming


ADS574 – an 8-bit, single channel A/D converter is used along with an analogue
multiplexer for ECG signal acquisition. This converter needs two control signals ( R / C ,
CS) and channel select signals (CS1, CS2) for multiplexer and gives out one status signal
(STATUS). The parallel port has eight data lines, four control lines and five status lines.
So this A/D converter can be easily interfaced with the microcontroller through the
parallel port. Parallel port programming in Linux is not as easy as in Windows operating
system. Application programs need special permissions from the kernel.
There are three approaches to parallel port software development for data acquisition
and control. The first approach, port I/O, is simple, functional and clearly demonstrates
the low-level hardware control, but this approach is not supported in the Axis’s
development software. The second approach uses Linux’s parallel port device driver to
control the parallel port. This approach can be used for interfacing the converter.
The third approach is to develop a custom device driver. Figure 16 explains the flow
chart of acquiring the ECG data.
Development of a wireless internet-based ECG monitoring system 271

Linux parallel port device driver, ppdev has been used to control the A/D converter
and the multiplexer, connected to the parallel port. This facilitates:
• examination of status lines
• setting up the control lines
• setting/examining the data line (and controlling the direction of the data lines)
• waiting for an interrupt (triggered by one of the status lines)
• setting up a response to an interrupt
• using IEEE 1284 negotiation (for instructing the peripheral which transfer mode to
use)
• transferring of data using a specified IEEE 1284 mode.
A program has been developed to change the status of the pins of the parallel port using
ppdev.

Figure 16 Flow chart for accessing the signals from the ADC
272 V. Agarwal et al.

4.5 CGI programming


Web documents are written in HTML – a simple mark-up language that attempts to
describe the logical structure of the text. Most often, HTML is stored in static files on the
server’s hard drive. Static documents are typically delivered from the file system of the
web server. The web server software locates the file on the hard drive, opens it directly,
and delivers it to the client (browser). But in the example application presented in the
paper, this simple static HTML document does not serve the purpose. A mechanism is
required, which can interact both with the hardware (device drivers) and the web server.
This is provided by Common Gateway Interface (CGI) programming. This programming
can be done in any high level language like C, perl etc. In the given application,
embedded Linux operating system, Boa web server has been used. It is specially designed
for embedded systems and occupies less memory. Before running the server software,
it needs to be configured so that it supports CGI programming. Whenever a particular
CGI script is requested, the server first executes the script and the output of the script is
passed on to the client (web browser).

5 Results and conclusions

The design and implementation of an ethernet enabled biomedical system poses a


challenging multi-disciplinary problem. Nevertheless, it offers several advantages like
remote diagnosis, monitoring and treatment of patients. It is particularly useful under
emergency situations such as transit of a patient to the hospital during a heart attack.
Figure 17 shows the three ECG signals obtained with three combinations – LA to RA,
LA to LL and RA to LL.

Figure 17 Signals from each of the three leads: (a) ECG signal acquired between RA and LL;
(b) ECG signal acquired between LA and RA and (c) ECG signal acquired between
LA and LL

(a)
Development of a wireless internet-based ECG monitoring system 273

Figure 17 Signals from each of the three leads: (a) ECG signal acquired between RA and LL;
(b) ECG signal acquired between LA and RA and (c) ECG signal acquired between
LA and LL (continued)

(b)

(c)

Figure 18 shows how the ECG signals would appear on a web browser to a remotely
located specialist.
The selection of the processor and operating system involves careful consideration of
the following factors:
• the processor should have enough computing power and ports to schedule the
process and resources
• availability of cross compilers, development software and source codes
• the System On Chip (SOC) should support as many peripherals as possible to
minimise the cost and size of the system.
274 V. Agarwal et al.

Figure 18 Snap shot of ECG signals monitored from a remote location

The system has rich set of peripherals (parallel port, serial port, USB) and embedded
Linux, which enabled the testing of the developed system with various Wireless internet
technologies. The system has been tested with wired ethernet (IEEE 802.3), wireless
ethernet (IEEE 802.11b/g), IP over GSM and CDMA from remote locations on the IIT
Bombay campus. The performance of the system is found to be consistent and
encouraging. The system can be easily integrated with future wireless internet
technologies such as WiMAX. As a future work, it is proposed to integrate this system
with appropriate software to enable logging in of data related to the medical history of the
patients.
Development of a wireless internet-based ECG monitoring system 275

References
Carr, J.J. and Brown, J.M. (2001) Introduction to Biomedical Equipment Technology, Pearson
Education Asia, New Delhi, India.
Finkelstein, J., Cabrera, M.R. and Hripcsak, G. (1998) ‘Web-based monitoring of asthma
severity: a new approach to ambulatory management’, IEEE International Conference
on Information Technology Applications in Biomedicine, Washignton, USA, pp.139–143.
Guo, Z. and Moulder, J.C. (2004) ‘An internet based telemedicine system’, Proceedings of the
IEEE Conference on Engineering in Medical and Biology, Washignton, USA, Vol. 2, No. 4,
pp.3076–3079.
Gupta, S. and Ganz, A. (2004) ‘Design considerations and implementation of a cost-effective,
portable remote monitoring unit using 3G wireless data networks’, 26th International
Conference IEEE Engineering in Medicine and Biology Society, San Francisco, CA, USA,
Vol. 2, pp.3286–3289.
Khan, A.A. (2002) Practical Linux Programming: Device Drivers, Embedded Systems, and the
Internet, Charles River Media, INC., Hingham, Massachusetts.
Kim, K.K, Lim, Y.K. and Park, K.S. (2004) ‘The electrically non contacting ECG measurement on
the toilet seat using capacitively-coupled insulated electrodes’, Proceedings of 26th IEEE
Conference on Engineering in Medicine and Biology, San Francisco, CA, USA, Vol. 1,
pp.2375–2378.
Kong, K.Y., Ng, C.Y. and Ong, K. (2000) ‘Web-based monitoring of real-time ECG data’,
Computers in Cardiology, Vol. 27, pp.189–192.
Kyriacou, E., Pavlopoulos, S., Koutsouris, D., Andreou, A.S., Pattichis, C. and Schizas, C. (2001)
‘Multipurpose healthcare telemedicine system’, Proceedings of the 23rd IEEE Annual EMBS,
Istanbul, Turkey, Vol. 4, pp.3544–3547.
Lin, C-C., Chiu, M-J., Hsiao, C-C., Lee, R-G. and Tsai, Y-S. ((2006)) ‘Wireless health care service
system for elderly with dementia’, IEEE Transactions on Information Technology and
Biomedicine, Vol. 10, No. 4, pp.696–704.
Lovell, N.H., Magrabi, F., Celler, B.G., Huynh, K. and Garsden, H. (2001) ‘Web-based acquisition,
storage and retrieval of bio medical systems’, IEEE Engineering in Medicine and Biology,
Vol. 20, No.4, pp.38–44.
Ping, W., Jin-gang, W., Xiao-bo, S. and Wei, H. (2005) ‘The research of telemedicine system
based on embedded computer’, Proceedings of the 27th Annual IEEE Conference on
Engineering in Medicine and Biology, Shanghai, China, pp.114–117.
Santamore, W.P., Homko, C., Marble, J., Wald, J. and Bove, A.A. (2004) ‘Improving heart failure
care by using a telemedicine system’, Proceedings of the IEEE Conference on Engineering in
Medical and Biology, San Francisco, CA, USA, Vol. 2, pp.3076–3079.
Szymanski, J.W. (2000) ‘Embedded internet technology in process control devices’, Factory
Communication Systems, Proceedings, Porto, Portugal, September, pp.301–308.

Websites
American Heart association, http://www.americanheart.org/ presenter.jhtml?identifier=4578
Data sheet of ‘AVR460 Embedded Web Server’, Atmel corp, http://www.atmel.com/atmel/
acrobat/doc2396.pdf
Data sheet of Analog to Digital converter ADS574, http://www-s.ti.com/sc/ds/ads574.pdf
Document on ‘The Linux 2.4 Parallel Port Subsystem’, on parallel port programming using
‘parport’ device driver, http://people.redhat.com/twaugh/parport/html/parportguide.html

You might also like