adaptive ecg filtering

of 46 /46
Adaptive ECG Filtering Group 2: Edward Jezisek, Brandon Autrey, Edward Nowlin Renato Ortega Sponsored By:

Upload: brinly

Post on 23-Feb-2016




1 download

Embed Size (px)


Adaptive ECG Filtering. Group 2: Edward Jezisek, Brandon Autrey , Edward Nowlin Renato Ortega Sponsored By: . Motivation. To improve the quality of ECG signals acquired from patients in an MRI environment ECG quality in MRI machines is lacking Current filter selection is confusing - PowerPoint PPT Presentation


Page 1: Adaptive ECG Filtering

Adaptive ECG FilteringGroup 2:

Edward Jezisek, Brandon Autrey, Edward Nowlin Renato Ortega

Sponsored By:

Page 2: Adaptive ECG Filtering

Motivation• To improve the quality of ECG

signals acquired from patients in an MRI environment• ECG quality in MRI machines is

lacking• Current filter selection is confusing• Current filters are imperfect• New MRI scans create problems

Page 3: Adaptive ECG Filtering

Objectives• To filter out 80% of magnetic interference on an ECG signal caused by

an MRI machine • To convert an analog ECG signal into a digital signal that can be

processed on a computer• To convert a digital signal back into an analog signal that can be

processed by legacy analog devices

Page 4: Adaptive ECG Filtering

Goals• To further the use of adaptive algorithms in medical practice• Improve the quality of ECG Signals• Save a life

Page 5: Adaptive ECG Filtering

Specifications• Receive and filter signals up to 250 KHz• Perform real time ECG filtering• Provide patient and device protection• Function in an MRI environment

Page 6: Adaptive ECG Filtering

RequirementsRequirements• Analog Front End – Patient protection and differential Amplifier• Data Acquisition – Analog to Digital Converter• Data Processing – Filter out the noise sources• Raw ECG Out – Provide clean ECG output

Page 7: Adaptive ECG Filtering

Project Implementation• Receive ECG signals from 3 leads on the

patient• Receive magnetic field gradient signals from 3

leads• Convert these 6 signals from analog to digital• Use the microprocessor to subtract the

gradients from the ECG signal• Apply adaptive LMS algorithm to smooth out

the signal and filter other noises• Convert from digital to analog

Page 8: Adaptive ECG Filtering

Overall System Diagram

Page 9: Adaptive ECG Filtering

Noise Contributions• Electrical interference from power lines add 50 or 60 Hz power-line

frequency.• Muscle contraction and muscle activity can generate high frequency

electromyography (EMG) noise. • Motion artifacts such as movement of the electrode over the skin


Page 10: Adaptive ECG Filtering


Page 11: Adaptive ECG Filtering

PCB Design considerations• Routing of traces for high speed communications• Electrical isolation• Battery powered vs power outlet• Cost• Use of available components

Page 12: Adaptive ECG Filtering

Analog Front End• Consists of 3 ECG inputs• Consists 3 inputs from magnetic

gradient• Provides patient protection• Provides front end filtering

Page 13: Adaptive ECG Filtering

Analog Front End• Removed because of NDA

Page 14: Adaptive ECG Filtering

Analog Front End

• Sallen Key Filter• Used for anti aliasing• Low Pass Filter• Sampling Frequency is 500 KHz• Nyquist Frequency is 250 KHz • Cut Off Frequency is 50 KHz

Removed because of NDA

Brandon Autrey
Page 15: Adaptive ECG Filtering

Analog to Digital Converter (TI- ADS8556EVM)• It contains six low-power, 16-, 14-, or 12-bit, successive approximation

register (SAR) based analog-to-digital converters• Excellent Signal-to-Noise Performance of 91.5 dB• Supports both serial and parallel • At speeds up to 720 kSps • Supports 6 channels

Page 16: Adaptive ECG Filtering

Alternative ConvertersLTC2376IMS analog to digital converter by Linear Technology• 250 KSps Throughput Rate• 16 bit • Guaranteed 16-bit No Missing Codes• SPI-Compatible Serial I/O with Daisy-Chain Mode

Page 17: Adaptive ECG Filtering

Digital to Analog Converter (AD5660)• 16 Bit• Single channel • 3 wire serial interface• Clock rate up to 30 MHz

Page 18: Adaptive ECG Filtering

Microprocessor Design Requirements• I/O speed of the CPU is determined by the output of the A/D • Minimum of 0.5 MHz with a device limited maximum of 20 MHz

• Must support enough memory to hold the program code plus at least 10 past data points of each signal• Clock speed must be high enough to perform the algorithm at the I/O

speed in real time

Page 19: Adaptive ECG Filtering

ARM Cortex M4F• Works with Matlab Embedded Coder• 80 to 160 MHz clock speed• RISC based microprocessor

Page 20: Adaptive ECG Filtering

Xilinx Spartan 3E• I/O speed of 33MHz• Processor speed is 50MHz• 376 Digital I/O pins• FPGA based• Very customizable especially with high speed special purpose applications

• Philips is able to advise us with this architecture

Page 21: Adaptive ECG Filtering


Page 22: Adaptive ECG Filtering

Adaptive Filter Experimentation• Verifies which adaptive filtering

algorithm will work best• Matlab and Simulink is faster to

prototype• Model Based Design

• Prototyping various algorithms on microcontroller would be very time consuming

Page 23: Adaptive ECG Filtering

Noise Cancellation• d(k) - input signal • s(k) - clean desired signal• n(k) - noise contributions • e(k) - converges onto the input data signal• n’(k) - correlated to the noise in the signal • When , then .• As long as the input noise remains

correlated to the unwanted noise, the adaptive filter adjust its coefficients to reduce the value difference between d(k) and y(k).

Page 24: Adaptive ECG Filtering

Least Mean Square Filter (LMS)• Common filter for Signal

Processing• Adaptively removes noise• Very good at removing noise as

shown in the results.• Matlab provides this filter

The signal in Matlab before and after filtering, when using the Least Mean Squares Filter.

Page 25: Adaptive ECG Filtering

Butterworth Filter• Linear filter to remove unwanted

frequencies• Easier to provide a first approach• Low memory usage• Can be Digital and Analog

Page 26: Adaptive ECG Filtering

MatlabBenefits• Quick to create various adaptive filters due to a lot of them already

being built in• Removes a lot of debugging timeDownfalls• The Embedded Coder is expensive and doesn’t work on all embedded


Page 27: Adaptive ECG Filtering

Matlab vs. Embedded Coding• Using Matlab to compare various filters and will possibly use the

networking system through USB to offload tasks from the processor to the computer itself

Benefits of Matlab Benefits of Embedded Coder

Decreases risk in the project Less hardware

Lowers the amount of required work Uses less energy


Page 28: Adaptive ECG Filtering

Comparison Methods• The perfect result will be stored.• Noise will be added to the perfect result• The filters results will be measured by subtracting the

absolute value of the output from the result and squaring it• The results will be divided by the number of input points to

get a running average

Page 29: Adaptive ECG Filtering

Software Development Process• Allows us to develop code while

the PCB board is being designed and produced• Development board enables us

to test code on hardware to additional debugging tools• Matlab enables fast testing of

complex algorithms

Page 30: Adaptive ECG Filtering

Data Processing• Networking System• Graphical User Interface• File Write System• Filter Comparison System

Page 31: Adaptive ECG Filtering

Networking System• Used to transfer data from the

microcontroller to the program that modifies the data and back to the microcontroller.• Asynchronous I/O utilizing


Page 32: Adaptive ECG Filtering

Publish/Subscribe System• The software will be built with a

list of publishers and subscribers• The publishers will post data to a

topic• The event manager will send all

subscribers the data that the publisher posted• Publishers do not need to know


Page 33: Adaptive ECG Filtering

Topic Manager• Manages the publish subscribe system• Sends data received to a list of subscribers• Manages the memory of the publishers and subscribers• Can send data to a subscriber without knowing whether the receipt

was successful

Page 34: Adaptive ECG Filtering

Subscriber• Receives data from the topic manager• Does not know about the Publisher• Will be used for a lot of the input/output processing• Will filter the signals• Some subscribers will also be publishers

Page 35: Adaptive ECG Filtering

Publisher• Publishes data to the Topic Manager in the form of a Topic• Does not know about the subscribers• Will send data to other applications to retrieve a result• Many publishers will also be subscribers

Page 36: Adaptive ECG Filtering

Topic• The topic is the data being sent by the Publisher to the Subscriber• The topic will contain various types of data and an known amount of

data• The data will be sent as bytes and will be reconstructed based on the

topic type

Page 37: Adaptive ECG Filtering

Graphical Display• Displays the ECG signal• Should be simple and easy to

use• Should work on a tablet

computer• requires touch screen for the


Page 38: Adaptive ECG Filtering

Compare Various Filters• Uses a filter interface• Needs to be easy to compare• Requires some functions to be

created on each filter to show the results.

Page 39: Adaptive ECG Filtering

File I/O• Store filtered signals for each filter• Will be used to compare various files/results• Will allow us to test easily

Page 40: Adaptive ECG Filtering

Testing Methods• Perform functional test in an MRI environment• Perform test in a simulated environment. A simulated environment

will consist of a rapidly rotating magnet placed over ECG cables while collecting a signal.

Page 41: Adaptive ECG Filtering

BudgetParts Price Quantity Total

Tiva C Series Dev. Board $200.00 2 $400.00

Analog to Digital Converter (ADS8556EVM)

$101.00 1 $101.00

Circuit Board $750.00 2 $1500.00

Total Costs $1101.00

Total Budget $10,000.00

Extra Budget $8899.00

Page 42: Adaptive ECG Filtering

MilestonesItems Dates

PCB design completion February 3rd

Successful interface between processor and A/D

February 5th

PCB board arrival February 15th

PCB board populated March 1st

Successful interface between all components

March 1st

Operational filter March 10th

Final Testing March 20th

Page 43: Adaptive ECG Filtering


Project Development0







Research PCB Completion Parts AcquisitionSoftware Development Testing Total

Page 44: Adaptive ECG Filtering

Work DistributionTasks Group Member

Front End Design Edward Nowlin

PCB Design and Layout Edward Nowlin and Renato Ortega

Integration of Experimental Board Brandon Autrey and Edward Jezisek

Filter Comparison Programming Edward Jezisek

Least Mean Squares Filter Edward Jezisek

Matlab Display Edward Jezisek and Brandon Autrey

ADC Brandon Autrey

DAC and SPI Edward Jezisek and Brandon Autrey

Page 45: Adaptive ECG Filtering

Issues• Takes time to manufacture PCB• Learning to code to the microprocessor• Time constraint

Page 46: Adaptive ECG Filtering