Collect and analyze ECG data
posted Aug 22nd 2009 12:00pm by Zach Banksfiled under: downloads hacks, Medical hacks, peripherals hacks

Although we’ve covered DIY ECGs before, [Scott Harden] sent in his version that gives an in-depth explanation of what to do with the collected data. He built a basic battery-powered op-amp-based ECG for under $1. The circuit just amplifies the signal from the chest leads and feeds it into a computer via the microphone port. He then used GoldWave to record, filter, and save the signal. From there, he used python to analyze the heartbeat and calculate his heart rate and further manipulate the data. His previous blog posts go into more detail on how the python code works and why he chose software over hardware filters.








Be VERY careful with this, you will have a really good electrical connection to some very expensive equipment that’s really hard to replace.
For the dense of you: That means you could easily die from simple mistakes with this.
Some opamps will output the supply voltage if ony one half of the powersupply is hooked up.
If the PC is improperly grounded, you’ll get several hundred volt on the chassis.
Safety is hard, you don’t want to be hooked up to an good path to ground if you happen to touch a live wire, but on the other hand you want to ensure that any nastyness coming in via the output isn’t allowed to flow into the test subject.
I’d probably not feel safe unless:
* The output was run though an optoisolator.
* The inputs are all clamped to common using diodes, so it’s absolutely certain that the device can’t output more than 0.7 V even in the worst case failure mode.
* The entire device should be packaged securely in an isolated case, so no lose wires can poke into it.