ECG Artifacts when using the AD8232 analogue front-end - Page 1
Forum section: electronics / projects

author: willPowell
author_rank: Contributor
timestamp: April 15, 2022, 11:33:27 am
content: Happy Easter everyone!I am trying to record ECG with the AD8232https://cdn.sparkfun.com/datasheets/Sensors/Biometric/AD8232.pdf?bcs-agent-scanner=1a04c9bc-14af-e84a-94b9-006fb5926745front-end using the breakout board from sparkfunhttps://www.sparkfun.com/products/12650.The breakout schematic is on page 28 of the datasheet and looks like this:For context:- LA = Left Arm Electrode, conventionally placed on the Left Arm or Chest (closest to heart therefore strongest signal)- RA = Right Arm Electrode, conventionally placed on the Right Arm or Chest- RLD = Right Leg Drive Electrode, conventionally placed on Lower abdominal or Leg (allows for common-mode rejection, reducing noise)Look up Einthoven's Triangle for more information.When recording with electrodes placed in correct configuration (RA and LA on the Right and Left Upper Chest and the RLD on the Right Abdominal) I get the following ECG:Notice how the R wave has a much smaller amplitude than the S wave. The T wave is also incredibly large.I then recorded again with the LA and RLD switched (LA is now on the right abdominal and the RLD is on the left chest):This shows a much more realistic ECG (granted the S wave is still too large). WEIRD!!My current idea is that placing the LA, near the heart (in the correct position) provides too large an amplitude for the AD8232 and is therefore attenuated, making the S and T waves look larger as a result.Perhaps due to the op-amp circuitry?Any ideas much appreciated.Thanks in advanceP.S. I also tried the two electrode configuration but this lead to the same phenomenon.I modified the SparkFun board by moving the 10M Ω resistors to the RLD pin (red annotation) and then pulled the AC pin HIGH (blue annotation). These changes were done as described in AC leads off detection from page 21 of the datasheet.

author: CaptDon
author_rank: Super Contributor
timestamp: April 15, 2022, 02:03:03 pm
content: I am not familiar with that I.C. from analog devices. I am familiar with the circuitry from SpaceLabs patient monitors. All of our inputs have the exact same circuit components where as the A.D. chip uses a radically different RL circuit compared to the others. In SpaceLabs there is a steep rolloff filter to suppress unwanted response above a certain frequency. That rolloff is accomplished in several stages, not all in one place giving sort of a brick wall effect. In the simplest hookup it is left abdomen (over left and slightly higher than navel), upper left chest and upper right chest. "The cloud (white lead right chest) sees smoke (Black lead left chest) over the fire (Red lead left abdomen)" and only if you really want it the green lead on the right abdomen. You can view several 'Leads' in this simple attachment with Lead II being the most commonly viewed and the most commonly encountered 'picture' of ECG/EKG. There is some confusion among newbies as to the term 'leads' and I wish they would have chosen a different name to eliminate the confusion of 'Leads' as in Views VS. leads as in Wires/Electrodes. 12 Lead View does not consist of 12 Wires/Electrodes.I am not sure how the AD chip could give you Lead I, Lead II, and Lead III views which are easily obtained through differential measurement between the 3 or 4 simple electrode placements.

author: CaptDon
author_rank: Super Contributor
timestamp: April 15, 2022, 02:27:37 pm
content: When looking up the AD8232 online it appears to be sold as a 'Heart Rate Monitor' and 'Single Lead' with two or three electrode configuration. I am not really sure it was ever capable of producing 'clinical' Leads (Views) and I didn't see any Lead specified as in I, II, or III which can normally be viewed with a 3 or 4 electrode connection. With that crazy Right Leg Drive circuit I really don't see a clinical ECG use for this device other than 'Heart Rate' in BPM. It seems if you really want a Lead II view you need to look at some other device completely with three or four electrically identical inputs, analog and/or digital processing.

author: sw2022
author_rank: Contributor
timestamp: April 15, 2022, 05:30:53 pm
content: Might be worth trying the arm electrodes on your actual arms, see what happens. ECG morphology will only be standardised if you have the electrodes in the right places. The voltage detected is essentially measuring a vector quantity and direction with reference to the heart plays a big part in what you get. If the LA/RA electrodes are placed close to the heart small shifts in position may have big effects on R,S and T amplitudes. Using the arms standardises the direction of the vector. How I know this is from veterinary cardiology where the chest shape is very different to humans. We tend to use a position partway down the limb, you get something more like your second trace from chest placed leads on an animal, also dependent on where on the chest. Cant use it for amplitudes, only rhythm assessment. Useful for ambulant rate/rhythm monitoring though. Oh and recent heart attacks could mess with your T waves. I guess that’s unlikely.Steve

author: CaptDon
author_rank: Super Contributor
timestamp: April 15, 2022, 05:53:59 pm
content: It appears the AD8232 can only produce a Lead I signal since the RLDrive seems to be a noise reducing output as opposed to an input necessary for the most often appearing 'Lead II' ECG graph. Compare your various signal captures with these 'standard' Leads. Best wishes!! B.T.W., for Lead I, II, and III chest placement is fine. No need to go out on the limbs, chances are the signal would have even more stray noise in the home environment.

author: dietert1
author_rank: Super Contributor
timestamp: April 15, 2022, 06:37:24 pm
content: The leg electrode is meant to force body potential into the input voltage margin of the amplifier. Whether this works, will depend on several factors. It's best to equip the ECG frontend with an isolation barrier. Then the force electrode can be just a voltage divider to provide mid voltage and this is guaranteed to work, even if the proband touches somewere with his/her hand.In the systems i have seen this is necessary anyway for safety reasons. E.g. an isolated UART plus isolated DC-DC for the frontend including the digitizer.Regards, Dieter

author: sw2022
author_rank: Contributor
timestamp: April 15, 2022, 08:10:38 pm
content: Quote from: CaptDon on April 15, 2022, 05:53:59 pmWhy, surely you would just connect the amp inputs to RA and LL for a leadII trace?Steve

author: sw2022
author_rank: Contributor
timestamp: April 15, 2022, 08:15:16 pm
content: Back in the day when I was making ECG circuits I used a front end based on the INA118 datasheet with great results. Could record any of the main three standard leads depending on where you connected the inputs. Attached screenshot.Steve

author: willPowell
author_rank: Contributor
timestamp: April 16, 2022, 06:05:48 pm
content: Thank you CaptDon for your responses and clearing up the Lead confusion.Since there is plenty of discussion about what application this will be used for:1. This does not need to be clinical grade and ideally used for precise R-R rate (heartrate) so I think Lead 1 view is good.2. I would like to have only two electrodes (i.e. without an RLD) and place on a chest strap like the Polar H10.3. Ideally, after this project I'd like to test it with EEG (brain wave recording). However this is likely a harder feat.Do you have an applicable circuitry/circuit diagrams for these requirements? And a suggestions to try achieve Lead 1, without the strange electrode placement with the AD8232?Thank you for all your help.

author: willPowell
author_rank: Contributor
timestamp: April 16, 2022, 06:09:35 pm
content: Thank you Dieter for your response.I am a bit confused how to isolate the frontend. The output of the AD8232 is connected to an ADC which needs to be referenced to the same GND as it is only one wire. (From here, the ADC goes to the microcontroller over SPI, again over a common GND.

author: moffy
author_rank: Super Contributor
timestamp: April 16, 2022, 11:16:52 pm
content: If you use some digital isolators you could isolate the AD8232/ADC from the microcontroller through isolating the SPI connections.

author: dietert1
author_rank: Super Contributor
timestamp: April 17, 2022, 12:54:58 am
content: I have been using ADuM5240 or one of its variants to supply and connect the whole ECG frontend including the microcontroller. In my case the ADC was inside the microcontroller. Later i used ADuM5400. It includes another isolated channel to provide primary side regulation of the isolated DC-DC. Less heat.Regards, Dieter

author: Terry Bites
author_rank: Super Contributor
timestamp: April 17, 2022, 01:34:55 pm
content: It looks like you have excess peaking in the circuit.The filter bandwidth should be 0.5Hz to 150Hz. Check the Q of the LP section is <.7 . See Fig 56 and 57 and the use of Rcomp to reduce ringing in the HPF. The bandwidth and Q of the system are crucial to obtain something resmbling a clinical ECG. The gain and phase/ frequency response of the RLD amplifier can cause stabilty problems leading to unexplected peaking. I've found that RLD works well when attached at the top of the right shoulder. These days clinical ECGs use DSP to clean up the waveform and fix the baseline wander.I've not been too happy this the module when the signal and power are mains earth referrenced (something not permitted in a clinical device).Ideally you'd want to run it on a battery or an isolated DC-DC converter and use low cost isolation amp. Say, an IL300 or similar linear optocoupler. This significantly boosts the effective CMRR and kills any ground loops.