Microcontroller based biosignal acquisition and analysis system.
Szakacs Simon, Peter ; Moraru, Sorin-Aurel
Abstract: This paper presents a microcontroller-based project for
acquisition of the EKG and EOG signals and transfers to the computer for
recording and data analysis. The main purpose of the project is to
record both type of signals using the same multichannel device, the
instrumentation amplifier and the power amplifier of every channel
supports adjustable gain, so can be calibrated. The importance of
calibration is due to difference in voltage of the EKG and EOG signals
and because every person has different gain of those signals. Analog
signal is converted in digital with Atmel microcontroller and
transferred to the computer trough serial interface. We developed a PC
based software for data recording and signal analysis, resulting the
values of the heart rate and the direction of the eye movement
Key words: biosignal, microcontroller, data acquisition, EKG, EOG
1. INTRODUCTION
Biosignal analysis is part of the modern medicine, is noninvasive,
used for detect a wide range of disease (heart, muscle, or neurological
disorders). Eye activity is suitable to drive human interface devices
like computer mouse, joystick or remote controller.
The EKG signal is one of the simplest procedures to evaluate the
heart, based on its electrical activity recording. Electrodes are placed
at certain locations on the arms, legs and chest. The resulting signal
is differential type with respect to the virtual ground electrode (e.g.
right leg). (Dale D. 2008)
The eyes are the origin of a steady electric potential field, which
can also be detected in total darkness and if the eyes are closed. It is
generated by a dipole with its positive pole at the cornea and its
negative pole at the retina. The magnitude of this so-called
corneo-retinal potential difference (CRP) lies in the range of 0.4 mV to
1.0 mV. On the assumption of an unchanging CRP, the electric signal that
can be derived using two pairs of skin electrodes placed at periorbital
positions around one eye is called Electrooculogram (EOG). EOG typically
shows signal amplitudes ranging from 5[micro]V to 20[micro]V and
essential frequency content between 0Hz and 30Hz. (Bulling A. et al.
2009)
For developing biosignal-based applications, we need a data
acquisition system at low cost, suitable for EKG and EOG recordings.
Existing applications use one of the signals, for our needs, we
developed a multichannel hardware with adjustable gain and PC based
software for data analysis. EKG cable is very expensive; we made it from
quality shielded audio cable. The quality of the signal is good, due to
digital noise filter, shielded cable, and low noise instrumentation
amplifier and low noise power amplifier we used. The system we developed
implements the following functions: EKG recording, calculating heart
rate, detecting eye movements left, right, up, down, blinking. In the
next step, we purpose to extend the numbers of EKG channels, detailed
automatic waveform analysis, and development of human interface devices.
2. EXISTING HARDWARE PARTS
After studying the market about existing hardware resources like
electrodes, cables, instrumental amplifiers, power amplifiers, filters
and microcontrollers, we decided for Atmega 8 microcontroller, AD620A
instrumentation amplifier, MAX 7426 fifth order low-pass digital filter.
[FIGURE 1 OMITTED]
[FIGURE 2 OMITTED]
[FIGURE 3 OMITTED]
[FIGURE 4 OMITTED]
[FIGURE 5 OMITTED]
The first stage of our design is the electrodes. The electrodes
were chosen with the concern of protecting the eyes from hazardous
elements. ECG disposable electrodes were used because of their easy
availability. Silver/Silver-Chloride electrodes were chosen because the
half-cell potential was the closest to zero. (Vinodh R. et al. 2008)
On Figure 1 we present the functional block diagram of the system,
it can receive the EKG or EOG signals, which are processed, displayed
and recorded. Figure 2 and Figure 3 presents the input hardware, we used
the same type of AgCl electrodes for both biosignals. Signal
conditioning board presented on Figure 4 includes the following:
reference driver for virtual ground electrode, instrumentation amplifier
for quality signal acquisition, analog high pass filter and digital low
pass filter for noise filtering, power amplifier and voltage scaler to
adjust input for the ADC.
Figure 5 presents the microcontroller board with serial interface.
3. SOFTWARE RESOURCES
This project includes two software parts, the first is developed to
drive the microcontroller (***2010) and the second for presenting the
results on the computer.
To develop the microcontroller software, we used AVR Studio
development environment and PoniProg memory programming software. (***
2005)
The PC based software was developed in Lab Windows CVI environment
and displays the results of the acquisition and analisis. This software
contains the following functions: serial port initialization, EKG signal
acquisition, Acquisition reset, EKG waveform display, Heart rate
calculation, heart rate abnormalities detection, EOG signal detection
for left, right, up, down movements and blinking.
For PC based software we used multi threading technology, one tread
is for data acquisition and the others are for analisis and recordings.
We used this programming method because in one thread version, all the
interface buttons are inactive until the data acquisition completes.
4. CONCLUSION
The system designed for biosignal acquisition can record the EKG
and EOG signals, the waveforms are displayed on the screen of a
computer, the software calculates the heart rate of the patient and
detects the presence and type of EOG signals. This design with
adjustable gain is more economical compared to separate amplification
and filter circuits.
The high frequency noise was successful rejected due to fifth order
digital low-pass filter. The cost requirements are met, and the system
can be used to develop other biosignal-based projects.
We used hardware filtering because software filtering it will
significantly affect on the real-time nature of the system, as the
software like MATLAB takes heavy time to process and filter the digital
data. (Malik A. et al. 2007)
Today, it is not so difficult to construct such a device, but there
are many standards concerned to human safety especially for intensive
health care usage. (Petrov G. 2004)
5. FUTURE DIRECTIONS
The next step of our research is to minimize the size of the heart
monitor, add wireless module, and use it for assisted living project. A
medical-oriented sensor network system for assisted living facilities,
integrates heterogeneous devices, some wearable on the patient and some
placed inside the living space. Together they inform the healthcare
provider about the health status of the resident. Data is collected,
aggregated, preprocessed, stored, and acted upon using a variety of
replaceable sensors and devices (activity sensors, physiological sensors
and environmental sensors). (Stankovic, J. A., 2006)
In the assisted living project, we intend to use EOG based
interactions to control the environment status and home appliances. An
advantage is that EOG processing requires less computational power than
video due to lower data rates. This enables an embedded and low-power
design and results in low data storage. (Bulling A. et al. 2009)
6. ACKNOWLEDGEMENTS
This paper is supported by the Sectoral Operational Programme Human
Resources Development, financed from the European Social Fund and by the
Romanian Government under the project number POSDRU/107/1.5/S/76945.
6. REFERENCES
Dale, D., (2008) Rapid Interpretation of EKG's, 6-th edition,
Medical edition, Bucuresti, ISBN: 978-973-339-0647-6
Bulling, A., Roggen, D., Troster G., (2009) Wearable EOG goggles:
Seamless sensing and context-awareness in everyday environments, ETH,
Wearable Computing Laboratory, Zurich
Stankovic, J. A., (2006), Wireless Sensor Networks, Department of
Computer Science, University of Virginia Charlottesville, Virginia 22904
Malik. A. Q., Ahmad, J., (2007), Retina based mouse control, World
Academy of Science, Engineering and Technology, 31, 2007.
Petrov, G. (2004), www.codeproject.com, ECG recording, storing,
filtering and recognition
*** (2010) http://ham.elcom.pub.ro/, RC_microcontroler.PDF, Aspects
of using the AVR microcontrollers resources, M.S.
*** (2005), AVR simulation with the ATMEL AVR Studio 4, Purdue
University, Rev.C.