- Home made ECG number 1

Home | ECG # 1 | ECG # 2 | FreeECG | About ECGs | More Info | FAQ | Site Map

Yes, it strikes me as a little unfortunate that the brand on the tin can that this ECG is in reads 'heaven' (the patient's next destination?) and that the name of this site is neozap. If we can pass this awkward position, let me introduce the home made ECG #1

Objective: Build an ECG for giggles, make sure it works, eliminate 50Hz interference.

>> Here is the first post I made on the overclockers forum (

I've built a home made ECG to these designs:

Unfortunately, while I can see the QRS complex, the P & T waves get lost in the noise. It looks like everybody has atrial fibrillation - not good!

Here's the physical device:

As you can see, I have surface mounted it inside a tin can, intending to reduce the interference.

I've also used shielded audio cable (single core, braided outer) for the electrode leads. The braiding is earthed to the tin can via the outer rim of the RCA plug.

This is a view of the 'inside' of the can. As you can see, the three blue wires connect the 'leads' to the RCA plugs. I don't think they're the source of interference, even though they're not shielded, as there is no interference effect when the RCA cables (the black ones in the previous picture) are plugged in.

Finally, here's a trace from the ecg, as recorded by my computer's sound card. The QRS is clearly visible, but the S & T are pretty much obscured by that lovely 50hz (i think it's 50hz) hum. Our power in australia is 240v/50hz, so this would make sense.

So, i've put the electrics in a tin box. I've shielded the wire (although this may not be the correct procedure). I've earthed all the circuit earths to the main earth. I've even earthed the tin box to my computer's case. The noise persists.

I'm totally out of ideas - and would love any input on how to reduce this interference! ECG's are really prone to noise (especially $7 ones) because of their design - amplifying a tiny signal many times.

If you can't help - I hope you enjoyed the brief project outline anyway

I was pretty pleased with the results of the project so far - but it needed more work to suppress the noise. A post by link1896 gave me more information to hemp me ensure noise was supressed.

Originally Posted by link1896 View Post
What lever are the peaks? If no where near clipping, and are way down in level, you are probably using 18 to 24db of your sound cards ADC input range.
A half decent sound card that has 16 bit ADC's MIGHT have 72-84db of dynamic range, older on board realtek's under 50db of wideband noise. (50/100hz noise can sometimes be less then 20db down)

Add more gain to your adc until the peaks are near -0dB full scale on the sound cards ADC input if the above is true

Not sure what you mean regarding the peaks. The amplitude is fully adjustable using the potentiometer - however as the amplitude of the QRS increases, so to does the amplitude of the noise. My sound card is a 16 bit excel super-crapola one.

Do you think it is sound card related noise given the following:

Normally (no ECG connected) no noise, or a very slight 50hz function visible.
Ecg connected, but no leads plugged in to the RCA plugs - no noise
Ecg connected, leads connected - lots of noise.

Seems to be rather related to the cables that you connect to the electrodes. But how could it be - given that they're shielded?


Another poster helped to track down the problem with all the noise

If this is the schematic you actually used

there is an error.
Ground should connect to the sleeve of the output jack, not the ring.

And some more good information

I meant the 3.5 mm output socket on your ECG. The sound card uses a 3.5 mm stereo input plug also known as a TRS (for Tip, Ring, Sleeve) connector. The body of the plug is called the sleeve and is connected to ground. The tip of the plug is left channel in and the ring in between is right channel in. If you connect it as shown in the schematic, you'll have the ECG ground on the right channel in, which is incorrect.
I can't tell from the photo of the box interior but have you connected the lid of the box to the circuit board ground.


But again, that wasn't the problem

Originally Posted by wabbit View Post
Quote from "The Biomedical Engineering Handbook", second edition, chapter 13, "Principles of
Electrocardiography", section 13.2, "Instrumentation":

"The general instrumentation requirements for the ECG have been addressed by professional societies through the years. Briefly, they recommend a system bandwidth between 0.05 and 150 Hz. Of great importance in ECG diagnosis is the low-frequency response of the system, because shifts in some of the low-frequency regions, e.g., the ST segment, have critical diagnosis value. While the heart rate may only have a 1-Hz fundamental frequency, the phase responses of typical analog high-pass filters are such that the system corner frequency must be much smaller than the 3-dB corner frequency where only the amplitude response is considered."

If your intended application is general interest and non-clinical, you could probably get away with low-pass filtering with a cutoff of 15-20 Hz.
The sound card low frequency response would certainly not go anywhere near the recommended minimum.

My ECG is definitely for personal use - you'd never get away with trying to hook up a patient to a home made ecg in a chocolate milk tin smile
Thanks for that information. I'll definitely investigate low pass filters - although they're quite past my current electronics expertise. I assume i would be filtering the audio cable core (i.e. tip)?

EDIT: I've put together a schematic for this:
This is applied to the core of the audio cable connecting the ECG to the computer. The GND is the shielding of the audio cable, connected to case ground.

Is this likely to work?

Needless to say, it didn't

More suggestions
here's a 50Hz notch filter that should help. It will reject the 50Hz hum, whilst not drastically affecting the shape of the wave for other frequencies.
the 193k can be made with a 150k in series with a 43k. The 9.65k can be made with a 15k in parallel with a 27k.

This one is a 150Hz low pass filter, which will give much better results than your passive filter. It can go right after the notch filter, which can go right after the input amplifier.
component substitutions:
160n = 150n || 10n
240n = 120n || 120n
68n = 68n
43n = 10n || 33n
2k79 = 2k4 --- 390R
18k1 = 13k --- 5k1
2k57 = 3k || 18k
16k5 = 33k || 33k

These two filters can be built with a single 4-opamp IC, like the TL074 or the OPA4134, and a handful of passive components which should be readily available at your local electronics shop.

I'm with odje, your input amplifier really ought to be a quality instrumentation amplifier, like the INA114, or the AD627, both available from RS components for <$20.

At this point I discovered that I got a much clearer trace when it was connected to a laptop running on battery, and took some more photos.

Originally Posted by LethalCorpse View Post
Can you give us a photo of the board front and back? It might also be worthwhile measuring the exact values of the components you used, though you'd have to take them off the board.
Sure, i'll dig it up and take some photos.

Carefull, these are moderately large photos.


Sorry about the fugliness of my soldering/construction - i just did what fitted in.

At this point the decision was made to abandon ship. The ECG did work, and did make a nice trace, but there was *way* too much 50hz hum. This was not going to be 'correctable' until a new piece of hardware was to be used, so the home made ECG mk 1 has been put out to pasture for now.

I have recently started making mark 2 - using some ridiculously antiquated gear and a lot of duct tape (out of picture) - see the new homemade EKG here