The heart’s pumping action is driven by powerful waves of electrical activity that cause weak currents to flow in the body, changing the electric potential between different points on the skin by about one thousandth of a volt (one millivolt, 1mV). Hidden within that activity is an enormous amount of information about what the heart is doing, and anyone who can detect it can peer into the workings of this incredible organ.
Fortunately, you don’t have to be a cardiologist with expensive equipment to pick up and decipher that signal. Anyone can do it with this homemade electrocardiogram (ECG) device, an analog-to-digital converter (ADC) to digitize the signal and send it to a computer, and a remarkable book that I’ll tell you about later.
You can assemble the circuit itself in an afternoon for about $40. The ADC will cost a bit more, between $50 and $300. But these devices open a universe of opportunities to the home-based experimenter, and so every citizen scientist should invest in one. (I’ve negotiated a great deal on one of these devices especially for MAKE readers. Read on.)
The experimental challenge is that the signal we’re looking for measures only about 1mV, it can change in as little as 1/100 of a second, and it’s embedded in a noisy environment. To keep up with the signal and boost it to a digitizable 1V level, you need an amplifier with a gain of about 1,000 and a frequency response of at least 100Hz. But standard operational amplifiers (op-amps) like RadioShack’s 741 won’t work because of the surrounding noise.
When electrodes are placed far apart on the body, our skin acts like a crude battery and generates an irregular potential difference that can exceed 2V, dwarfing our 1mV heart signal. Even worse, your body and the wires that connect to the electrodes make wonderful radio antennas that pick up the 60Hz hum emanating from every power cable in your home. This adds a sinusoidal voltage, which further swamps the tiny pulses from your heart, and because its frequency lies close to the 100Hz resolution we need to track your heart, it’s hard to filter out.
Now, you electronics types might think this shouldn’t matter because op-amps are “difference amplifiers” — that is, they subtract out any voltage that runs equally to both inputs. Unfortunately, op-amps don’t do that job perfectly, and when the swells are thousands of times bigger than the signal, as they are here, you’re sunk. To ensure that this “common-mode” garbage adds no more than a 1% error to our measurement, we need what’s called a common-mode rejection ratio (CMRR) of at least 100,000 to 1. In electronics parlance, CMRR is measured in decibels (dB), where every factor of 10 increase in voltage is equivalent to 20dB. This makes our required ratio 105, which equals 20*5 or 100dB — a precision beyond that of most op-amps.
The Instrumentation Amplifier
When an application calls for both high gain and a CMRR of 80dB or greater, experienced experimenters often turn to special devices called instrumentation amplifiers. These remarkable devices were once bulky and expensive, but today, they can be purchased for just a few dollars as an integrated circuit. To make the construction as simple as possible, I designed this ECG around the Rolls-Royce of instrumentation amplifiers, the AD624AD from Analog Devices, which you can buy from Digi-Key (digikey.com) for under $25. You select a gain of 1,000 with the AD624AD by simply shorting certain pins together, and at this setting the amp’s CMRR exceeds 110dB.
The AD624AD is easy to use, but experienced gadgeteers should also feel free to experiment with less expensive options, such as the Analog Devices AD620AN. And if you’re a real Daniel Boone-type maker, you can construct your own instrumentation amplifier using three RadioShack op-amps and a handful of 100K resistors.
Some simple circuitry supports our instrumentation amplifier. A two-stage resistor-capacitor (RC) filter weeds out frequencies higher than about 50Hz. As filters go, this one is pretty wimpy, but it works well enough to do the job. I used a four-wire phone cord to carry the signals between my body and the amplifier, but you only need three of the wires. The side of my project box sports a phone jack for easy connection and disconnection.
The Electrodes
I fashioned my first electrodes out of quarters smeared with a conducting layer of shampoo, taped firmly to my body, and connected to wire leads. They worked, sort of. Then I discovered anyone can buy bags of the real thing — the peel-and-stick electrodes used by cardiologists. The cost is about $13 for 50. (Google “ECG electrodes” for a host of suppliers.) I used alligator clips to connect the signal wires to the metal nipples on the backs of the electrodes.
Connect the instrumentation amp’s negative lead to just under your subject’s left armpit and its positive lead just under the right armpit. You must also connect a ground lead for the circuit to the left shin just above the ankle. Without the leg as a ground, bad things happen to the signal, and it’s a great little experiment to record an ECG this way for about ten minutes and see the problems that creep in.
Logging the Data
To examine the ECG signal, you’ll need to digitize and record it on your computer. This requires an ADC or data logger device that can sample at 200Hz. (The Nyquist Theorem states that reading an oscillating signal requires sampling it at a minimum of 2x its frequency.) I’ve tried many data loggers, and my favorite is the Go Link from Vernier Software, which has 12 bits of resolution and samples at up to 200Hz. Add the matching voltage probe unit, and you’re ready to rock-and-roll literally hundreds of other science projects. I’ve negotiated a deal with Vernier especially for MAKE readers: $67 for both logger and voltage probe; see sas.org/make.html for details.
Once you’ve connected body electrodes to our circuit, plug the Go Link into your laptop’s USB port, plug the voltage probe into the Go Link, and wire the probe to our circuit’s ground and low-pass filter output. For safety, the laptop should be unplugged.
SAFETY
Unless you’re doing something exotic, battery-powered instruments are generally safe to connect to people. The Go Link is powered through its USB port, so if the laptop you’re using is unplugged, you’ve got no worries.
Unlike the editors of MAKE, I personally think it’s OK to use our ECG device with a plugged-in computer, provided you take some additional precautions; see more discussion on my website at sas.org/make.html. The 10M (that’s 10 million ohms!) resistor between the subject and ground will choke any current in the unlikely event that an AC adapter fails and the laptop fries. The 47K resistors also limit the current. Even with a freak power surge, the subject’s arms lie outside of any path between the electrodes, so if she experiences any pain, she’ll be able to grasp and pull off the wires. Keep someone else in the room, or if that’s not possible, make the electrode leads short and run ECGs while standing. That way, if lightning does strike, you’ll break the connection by falling down.
In any case, never attach electrodes to the arms, and don’t connect the device to anyone in weak health. No matter how much of a do-it-yourselfer you are, don’t fire up your homemade ECG if you think you might be having a heart attack. Resist your curiosity and dial 911.
In hospitals, some monitoring equipment adds yet another layer of safety: opto-isolation. In this scheme, battery-powered devices connected to the patient transmit readings via LEDs to matching optical sensors inside a wall-powered display device. Since the only link between the two devices is a stream of photons, large currents can’t reach the patient through any wires. If you care to, you can add opto-isolation to your ECG to protect against a meteor-falling-from-the-sky-probability-level chain of events. Opto-isolators come in DIP-style ICs that you can plug into your system between the filter and the data logger. You’d ground the LED transmitter side to the amplifier circuit’s ground, and the photodiode receiver to the data logger or to ADC’s ground.
Interpreting the Results
Once you’ve mastered the art of tracking your ticker, you’ll need to decipher what it all means. There’s just one must-have reference, Rapid Interpretation of EKG’s by Dale Dubin, MD. You’ll find this easy-to-master mainstay of medicine on nearly every doctor’s bookshelf in America. Dr. Dubin also happens to be a good friend of the Society for Amateur Scientists, so we’re able to offer new copies of this classic to MAKE readers at a 30% discount; see sas.org.
ADVERTISEMENT