Some experiments with the Electrocardiogram (ECG) circuitry in the St Jude Pacemaker Monitor Heart Rate Analyser.
Forum: http://www.eevblog.com/forum/blog/eevblog-660-electrocardiogram-(ecg)-experiments/'>http://www.eevblog.com/forum/blog/eevblog-660-electrocardiogram-(ecg)-experiments/
EEVblog Main Web Site: http://www.eevblog.com
The 2nd EEVblog Channel: http://www.youtube.com/EEVblog2
EEVblog Amazon Store (Dave gets a cut):
http://astore.amazon.com/eevblogstore-20
Donations:
http://www.eevblog.com/donations/
Projects:
http://www.eevblog.com/projects/
Electronics Info Wiki:
http://www.eevblog.com/wiki/
Forum: http://www.eevblog.com/forum/blog/eevblog-660-electrocardiogram-(ecg)-experiments/'>http://www.eevblog.com/forum/blog/eevblog-660-electrocardiogram-(ecg)-experiments/
EEVblog Main Web Site: http://www.eevblog.com
The 2nd EEVblog Channel: http://www.youtube.com/EEVblog2
EEVblog Amazon Store (Dave gets a cut):
http://astore.amazon.com/eevblogstore-20
Donations:
http://www.eevblog.com/donations/
Projects:
http://www.eevblog.com/projects/
Electronics Info Wiki:
http://www.eevblog.com/wiki/
Hi. In the previous video, I did a teardown of this sinewed medical House Call Plus transmitter. It's designed to connect up to your pacemaker and extract the data from it and send it back via the phone line. Well, this particular model, the House Call Plus transmitter has an ECG function as well, and we took a look at some of the circuitry last time and what some people wanted me to play with this.
So okay, let's see if we can actually get some ECG data out of this. Normally it's just they've got a separate isolator thing goes across the transformer into and the ADC here into the DSP and then it's I You know, presume like a snapshot of that is that sent back or maybe even live data sent back to the Medical Center or your doctor or whatever it is. the I think it's a service online you subscribe to and then your doctor can access it and all that sort of stuff. But anyway, I Thought it'd be interesting to see if we can actually get some ECG data out of this because these can actually go quite cheaply.
I've seen there's one currently on eBay for like you know, 26 bucks Buy It Now or something. so it could be a really good way to get like an experimental wire ECG system because it's nice and safe. As I pointed out in the previous video, not only do we have a medical grade power supply with it and yes, I will do a separate teardown of that medical grade plug pack in it, but we've got a medical grade isolation transformer in here. We've got all the grounds: Separation: We've got the high value high voltage resistors in here in series with it, in series with each of these leads.
and you know, in the ground isolation. So pretty much you know. even if there's a lightning strike or something, you're not going to die if you've got these hooked up to both of your wrists. so it's pretty darn safe way to experiment.
So let's probe around and see if we can extract data out of this, because all it is. all this circuitry around here is just the analog stuff. It's just going to be a an ECG amplifier, a difference amplifier, and then ascend that buffering center over the transformer to the ADC over here. All right.
So let's have a look at some of the circuitry here. And as I said, this is all the isolated. So you can see the big safety isolation here and also going under the two big power resistors there. And of course, these aren't power resistors because they're dissipating a huge amount of power.
They're 330 K a pop. Here, they're used because they're high voltage resistors, so that's what they're being used for. So all the big safety isolation here. and so all these grounds are completely separated.
Now we've got ourselves an Opto coupler here, the Vishay CNY 64 and if you go look at the data sheet for that thing, then this side over here. These two pins are the LED and this side is the up photo transistor. So it's sending data back in that direction so it's sending something from over. In all this analog stuff, these are all just Op amps and comparators and stuff like that. So this is purely just an analog amplifier for the ECG signal which is picked up over here, so it's obviously sending something back so we don't have to worry. although we might want to probe off that to actually see what's coming out of it. But really, what we want out of this thing, of course, is an ECG signal to see if I can get my you know, heartbeat out of the thing. So anyway, there's data coming back across the transformer like this.
and obviously they're up powering over the transformer as well. so they've got to be transferring that to that power over I. Don't see how else they're doing it. Something has to be powering all these Anyway, we should be able to pick data off here.
and now this is the ADC Sorry, that's the ADC chip there and that's our DSP processor. and you know we don't really want to read the digital data out of this. ADC That's just you know, Silly. So what we want to do is probe the analog signal and look, there's a test point there.
Tp5. Look at that. that's handy. And there's also other test points on this side here.
and well, they could be a power supply test points, but you know more likely they're actually a signal. Test points anyway are worth checking out to see if we can actually tap off the signal from one of these test points so we don't even have to. Maybe if we're lucky, don't even have to go in and reverse-engineer any of the circuitry to find out where the signal path is and actually probe the thing. you don't want to be probing over here.
By the way, this is all going to be the differential amplifier. You want to probe it. the final driving point. The ECG signal should already be scaled up by all this circuitry and maybe level shifted or whatever on the ADC here so that it inputs the right signal level so you maximize your 10 bit dynamic range of your ADC there.
So let's have a program now. First things first. We want to find a ground point on this thing and usually these are PCB mount. studs here aren't a bad way to do it.
and they're you know, well worth doing. but check out here. Here's a test point which says to ground so there might be separate grounds here. so I'm just going to check these I'm going to just make sure that these are grounded.
and yep, so that stud there is grounded. and if we go all the way up here and probe these other ones, we can see that yep there. Also, because you can see that the ground is continuous, you see that dark green under the board means it's all sharing a common ground. So you know what? We hello that that, um, that mounting pad there is is connected to this ground over here.
but this one is not. That is bizarre and they're on the same. Look at that. they're on the same.
looks like they're on the same ground plane. You can see all the dark green under there, but that one's not actually connected through. That's interesting. So why is that so? Well, it's a trap for young players If you have a look here. I've actually got it switched on There we go. The LED is on and we're probing around why it was switched on. Oops. So look if we probe between these two points here, look at that.
We get minus 85. K That is completely screwy. but if we disconnect tada that we're grounded. So what we obviously had There is enough voltage differential there to completely screw up and confuse this meter.
So just be careful when you probe around this sort of stuff. If you are proving it, if you do a resistance checking like this, make sure you got it unpowered. Alright, the other thing I Want to do is actually probe around to see if we got voltage on this side of the transfer or the isolation here. So to power all this sort of stuff so that sells a big-ass tantalum cap there.
So it's obvious that we're going to probe across that. And hello, we got 0 volts. We got nothing across that cap cap next to it. Zero.
Another tantalum over here? Zero. What's going on? Powers onto the unit. I've got the lid on. But we're getting nothing across these caps.
There's no power. It's almost as if there's no power coming across here at all to power this stuff, huh? All right. So let's start probing around to see what we get here. We have established that that ground point.
It's got a little wire connecting to the crystal there, so we can conveniently hook onto there. Otherwise, we could have like soldered a wire onto one of the those mounting nut posts or something like that. So that's convenient place to put a ground point. And let's let's measure a few things.
Let's measure our power supply first. We're one volt per division. There we go. So where looks like we're You know, 1.8 volts there? Or something? That's probably the supply for the DSP perhaps? Let's go over to this other tantalum over here.
One volt per division? There we go. 3.3 volts. So yep, that's all right. That's our typical 3.3 volt rail.
Yeah, 3.3 Everybody happy. So all the power on this side is good. Now, of course, if you keep your ground probe on this side of the transformer and then probe the other side over here, there is no ground reference on this point. so watch what happens.
We're just going to pick up a whole bunch of 50 Hertz Crap is it? Yeah, Yeah, there we go. Spot-on 50 Hertz We're just picking up a whole bunch of 50 Hertz Crap because there is no longer any ground reference over there and it doesn't matter what part of this circuit you probe over here, you're just going to pick up 50 Hertz Crap. It's useless. So and just a little tip, if you didn't already know if you have got your ground reference point on the other side of an isolator transformer like this, you're not going to be able to measure anything on this sides that don't even try. And actually if I wanted to probe on this isolated side I haven't even found a good ground point for it yet. There's a mounting screw there, but it's not actually connected properly through. Yeah, I can see where one side of that one side of the capacity. It probably goes down to the internal ground plane in there, but you know? there's no convenient hookup point and it looks like there's no ground test point like we got on these digital side over here.
We've got a few ground test points over here conveniently so. Yeah, you'd have to solder in something in there to do it anyway. I Want to get this side first now if we measure on the side of the transformer here, I've actually measured one side of the transformer is connected through to the main ground here and we're getting nothing basically on there. So there's you know.
There's no surprise though. that's just you know. 50 Hertz Crap, Don't worry about that. So yeah, we've got nothing.
There is nothing powering this side of the circuitry at all. and you've got to think, well, that's because that's under Software Art Control and the thing hasn't connected. sides realized. Oh, I don't have to measure anything I don't have to do that ECG stuff because I'm not probably not connected through to the phone line and established a connection.
blah blah blah. So that is incredibly disappointing. So much for an easy just be able to probe. you know the output of the amplifier here and get an ECG signal on the scope.
It's not going to be that easy at all. You know it's possible, you can obviously coax it into doing it eventually, or you can hack into it to actually supply power to the circuitry and reverse-engineer it and you know, figure out and just you know, eliminate all this other stuff like rip like, tear out the transformer and just you know, wiring some power and onto here and just you know, get the output of the final stage amp and Bob's your uncle, but she is very disappointed. Hmm. and we're definitely getting no voltage on this side of the this side of the transformer here.
Nothing. There's no power on these chips at all. Okay, so what I've done here? Because we're getting no power on this side at all. Obviously, the software is not driving this side or there's getting no signal on this side, so there's no power over here.
So what I've done is I've sucked out that little puppy and we can actually see what's going on here. And it's pretty obvious that the output of the transformer here I've been. You know, assuming that this site is the input over here, which it is, then the output here. I don't even have to look up those two parts.
I Know that they're diodes. Okay, so we're getting some rectification happening there to generate the power. and that's our main filter cap. So that's all that this thing is doing is just powering the transformer to get as just an isolation transformer purely to get power over here. That means the signal data must be going back over the opto coupler here because we've already established. If you look at the data sheet for this thing, then the LED is on this side and the photo transistor is on that side. So there you go. Um, it's much easier now to simply go and apply power to here.
We can have a look at the data sheet for these chips and try and figure out what the maximum voltage here cuz we don't have any schematic or aspects or anything like that. Figure out the maximum voltages like a voltage across here and then we can start then probing around here and see if we can get a signal out. So I'm just going to ignore all of the rest of the circuitry, not even going to bother to pair it up anymore because it's completely I Say look at that and then we should be able to. maybe at least get this powered up.
Get an ECG signal out of here somewhere. Before we do that, we have to find out which one of these pins is connected through to the ground plane. and it's pretty obvious there's the positive of the cap there. So that's just going to be going through.
That's going to be a diodes going through. So I reckon this one here is connected through to the ground point and the ground points likely the negative side of that cap. and bingo There it is. and you can go down.
Say the negative side of this cap down here. Yep. and as I said, there's no ground test point so we should actually solder in. just a little loop on there so that we can attach our ground probe down to that.
But that entire ground plane there you can see you can see down in there the V R Go in. right down in there. There it is. From the negative side, it's going nowhere except down to that ground plane down there.
So yep, that one is definitely connected through. So that's a negative input. That's our positive input. Just look at the data sheets for these Op amps.
You know if they're maximum voltage, say they're a low voltage. one might be 6 volts and you might just, you know, whack 5 volts on there, for example. And as it turns out, we've got nothing to worry about there. Look, we've got an Lm317 voltage regulator here.
There we go, so we could read those resistor values, figure out exactly what we've got there. But there you go. So it's going to do the regulation for us. Beauty, All right.
So soldered on myself, a ground test point here, and a couple of flowing wires I've got that going up to? well? I will have it connected to the bench power supply. and because this is a Lm317, it's only got a Lm317 L low pal version. It's only got a current limit of 100 milliamps, so it's a good idea just to set your current limit on your supply to an arbitrary value of also a hundred milliamps. So I'm just going to start out at a low voltage whine the weak up until we can see the Lm317 regulate because I haven't bothered to read the values on those resistors and actually know what this thing operates out. and then you would set it like at least two volts above that. So I've got the probes just across the output capacitor there. Let's whine the wick up and see if we get any regulation on the output. One point 6 volts, keep winding up, winding up.
it's drawing now: 710 milliamps, 4.2 volts, 5 point 6 volts input. so 2.5 volts out. Now you've actually got to be careful here. This It turns out, this Lm317 is not actually powering everything.
it's powering. Well, it's obviously powering something, but the chips themselves. We have a look at this: LM R 3, 9 3 Comparator for example. Dual Comparator.
There you go. It's four and a half volt, so it's actually powered from the input directly. So it's nothing to do with the Lm317 there. So I've got 5 volts going in of course, and we're going to get, you know, half a volt drop on the diode of course.
So ya got to be careful there not to wind up the input wick too hard because it turns out it actually bypassed that Lm317 regulator there and went straight to these and straight to the Op Amps and comparators. Now these are LM V8 to four Op Amps on here if you look at the data sheet for those. Well, they're only low-power devices. They're only up to 5.5 volts voltage range.
so you know, really like 5 volts input is fine for this sort of thing. You definitely don't want to go over 5 point, 5, or 6 because of the diode drop. Then your risk of, well, you are damaged the Op amps. so yeah, I mean even.
You know, even if you were down at like 3 volts or something, it's probably enough dynamic range. You know these iPads can work down to low voltage so you know pretty much is going to work. So yeah, I reckon 5 volts in there. It's just err, perfectly fine and dandy.
Now in terms of safety, of course, because I'm going to put these or I've already touched the MiG Oh jeez no. I'm just fine because I we're only working at 5 volts from our isolated Our bench power supply. Just like you used to for all your projects, There's nothing dangerous there at all. And yeah, we are connecting the ground to a ground reference in this circuit.
But once again, it's just like powering a regular circuit. and we got the two big-ass 330k resistors in series there. We don't even need those for stuff that we're going to do here. so this is all completely safe.
You can muck around, even beginners can muck around with these sort of stuff when you've only got like a fight and isolated Five Art Supply. No problems at all. And here we go: Yes, I've got my wrist strap on. No, it doesn't matter that I'm wearing the watch and let's see.
let's probe a couple of the test points around here and and see what we get, shall we? So now I've got it powered from my five volts. So let's get in here and give it a bell. And of course, this is not the best way to get an ECG of course yet. like right at the end of your arms like this. As you know, it's one of the worst ways to actually get it. They need to be like on your chest, proper chest sensors and things like that to do it properly because you might get you know impulses and noise coming from your muscles and you know everything else so you're probably got to be in a relaxed state. Anyway, we just need to see. So I'm just going to probe a random test point here as we saw before.
I'm going to probe Tp8 and hello, hello, what do we got there? We got something All right. Let me probe Tp6. Oh yeah, hello. look at that.
We definitely had something there and all of a sudden it, oh, it's all over the shop. it's all over the shop. but we're getting we're getting something. Oh ah, all right, this is rather rather unusual.
Hmm. oops. trap for young players. Look at this Tp8 that we had before.
watch if I touch the ante steak Matt look at that. So yeah, oops. Um, something's going on there. Okay, let's not touch the anesthetic Matt Even though this is year people go.
Oh yeah, the anesthetic Matt is conductive. no their dissipative so they're you know, a ridiculously ridiculously high resistance. but it's obviously enough to pick up something. I mean we're dealing with very low level our signals here.
So I'm not going to touch the bench at all. and let's have a look see if we can I see. Couple that sucker and yeah, I'm not sure what's going on there, but is that a cardiac pulse? new? I don't think so. All right, we've got an oscillator.
They're just fine and dandy. 2.19 That's gonna be not only getting zippity-doo-dah R at the moment. Alright, so what I've done is I've got it up on a wooden frame isolated here so none of the input circuitry is touching the ESD Mad at all. I'm gonna probe Tp8 again.
Hello! What do we got there? And there you go. That's exactly the same signal that's probing before, but I don't have the wrist straps on anymore, so let me actually just touch them again. Here we go: Tada! So I'm now holding I'm just holding them I haven't put them on, but there you go. Have we got something? Okay, what? I'm probing now is actually are the output to that optocoupler.
Okay, so what's driving that lead on the optocoupler there and you can see jitter on this signal and I'm if I'm not mistaken, this might actually change with my pulse rate. So I'm going to jog here I'm jogging on the spot see if I can get my pulse rate up Here I am haha come on come on. it's hard to get my I'm quite fit. it's hard to get my pulse rate up I'm sorry, hang on lost my probe I have a naturally low heart rate by the way but I don't know I reckon I reckon if I get my heart rate up I work in this more jitter there and if I stand still again and relax you can almost see it beat in to my chest if I was moving my arm there sorry I was putting my hand over my Chester and I think it's jitter in to my heartbeat I think that could be an illusion, but that's the impression I'm getting. Now back to the signal that we're getting on test point eight here. it's a girl does not show it up in there. but yeah, it's a complete furphy because well, it's nothing like an ECG see no and it's not even in the same ballpark. In fact, we're using the wrong measurement technique on the scope here because we're talking in a heartbeat.
like once per second. You know, boom boom boom right? So obviously we need to get into. Now let's go into a horizontal menu here. we need to get our time base instead of put it on your usual time base.
You want to enroll mode like this and this is what roll mode is actually good for. And there's nothing on this test point that I can see anyway. But if we move it over to another one Tp6 Bingo. look at that.
Hang on. We've still got some crap on here, but boom boom boom boom boom There we go and that follows my heartbeat. So that's that Tp6 test point down in there it's the output of one of the quad Op amps there and I've checked out some of the output other outputs and I can't really find anything. This is like the best sort of signal I can find that actually matches my art cardiac pulse so you can clearly see my pulse in there and watch this.
if I go like that I can make it see I can make it do stuff because I'm just you know this is as I said, this is not the best technique for doing this sort of thing. You're going to pick up all sorts of crap. but cardiac pulse is definitely in there, right? and I should be able to prove that by closing my eyes and measuring my pulse. And I'll tap on the oscilloscope every time I feel my pulse so ready? Let's make sure got a good wave on there.
Yep, seat lip-lip So here we go. Is there any correlation there? They should be. And if I stop that and turn on the curses here, you see that we've got a delta of about 980 Millie her there, which of course is slightly faster than 1 Hertz so slightly higher than 60 beats per minute works out to around about 61 beats per minute there. That's much higher than my naturally resting heart rates.
I'm working here and doing all sorts of jazz, so you know it's a little bit elevated. Anyway, let's take that as a baseline. I'll keep the same roll rate and time base and we'll be able to see. Let's now do some exercise and see if we can increase it.
Well there we go. Here we go. Got a few jumps in there and yeah, you can see it's now much much quicker. And there you go.
We've got a daughter of two Point One Seven Hertz there which works out to about 130 beats per minute and I'm back on my regular time base mode now. and unfortunately, um, I can't turn averaging on at such a slow time. Basin averaging doesn't work in role mode either, but I can like change to high res Mo which does that boxcar roll in average but still, we can't really clean up that signal much and we're not really going to be able to see that cardiac pulse I'm afraid Here we go. Settle down. yet weird. You know it's kinda sort of there. But yeah, and because I know some people ask, no it's not the scope ground in here if I use something like my Lacroix differential probe here, it's just it's just even noisy. I mean a single point ground because our power supply is floating so a pink single point oscilloscope ground there is not going to do anything, but that's just picking up all sorts of crap so that's no good at all.
And yes, I've tried all sorts of things like my Australian safety boots here. you know, just to isolate myself from the floor and die. You know stuff like that and well, nothing's working I'm not copping a break, you know I can't seem to get like an ECG an actual ECG waveform out of the thing, which is a bit of a bummer, but it probably needs a needs some more work and stuff like that with you know, really tricky business trying to our probe. this sort of thing.
you've got to eliminate all sorts of, you know, environmental, our stuff, and test setup and probing issues and things like that from the equation. so that's not easy at all. You have to systematically go through and cater for those things. But anyway, I think I did get at least something out of that.
See if there's any correlation between my tapping and the slight modulation on that waveform. Here we go. make sure, yet, everything's fine. Okay, here we go.
any correlation? So obviously what they're doing is that you know, squaring up this signal really early and getting some sort of you know, modulation of a clock out of it and decoding it that way. So I'm not even sure if this thing actually, you know, can record like an issue and ECG signal as such. So yeah, I'm not not entirely sure what's going on there, but I'm pretty sure I found that that is modulating in time with my heartbeat I fade. you know if I hold my hand there and do you know I can actually correlate it to what's going on on that scope there.
Anyway, it requires further investigation and decoding and stuff like that, but there you go. That was my first crack at that thing anyway. so that's all the time for today. unfortunately for playing around with this thing.
but I whacked up this video anyway. I don't like leaving things around, you know, until I absolutely complete them because I might not get around to what playing with this thing again. but there you go. There's just a couple of little like experiments.
I was a bit disappointed I couldn't just get you know, a single-ended ECG waveform out of this thing I'm although that maybe that was unrealistic. but anyway, I think I've found a correlation there with that digital output. So yeah, maybe that's how it's actually doing. It's probably squaring it up early. and yeah, you might have no chance of getting an ECG out of this particular circuitry here. So anyway, I hope you enjoyed that fun little playing around. And if you've got any ideas or suggestions, please leave it in the comments. Catch you next time you you.
i960 blast from the past – Stratus I/o
Interesting video, always good to see medical device content!
output of optocoupler could be puted trought low passs filter not eaven actice but mby 3 stage RC thats how i transefd my woofer audio signal galvanicly
I think you didn't connect the ground to your right leg that might be the problem. what is that white colour round thing anyway?? I thought its going under your feet
I like it so much
Well, 100 mA through heart? Better not pierce your skin with a probe… (Or get too sweaty.)
This is why there are those high value resistors in there and additional ground plane isolation.
I love when dave probes around trying to extract some "dator"
You can plot the "frequency" or "duty cycle" statistics in your scope.. Go "Measure" (Button) ->Then go "down" -> History -> History to "ON", Display to "Graph".. It will Plot the Horizontal axis statistics, you selected..
Dave, the neighbors downstairs called and want you to cut out the noise. 🙂
of course the DSP is doing the real low-pass filtering digitally to get the nice waveform
Hmm. use a 4046 PLL to decode the FM?
why not put the PWM-ed ECG signal thru a RC filter…?
I Wonder why it needs an adc when the optocoupler output is a pulsetrain
The test point gave you your ECG reading for Limb Lead 1, you need 3 or 4 leads to get all limb leads, and more for a 12 lead (10 total leads for a 12 lead… math seems wrong but that is the truth). For most waveforms two leads are active, one as negative and the other positive, for AVF, AVL, and AVR 3 are used – two leads are differential and one is negative; if used a 4th electrode is used as a ground reference to help clean up the signal (right leg lead). 3 lead ECG is typically done in "field" mode using a 0.5 to 500Hz filter and 12 lead is 0.5 to 100Hz. In both modes the signal received from the leads is then run through a fourier analysis to derive the actual waveform. Limb lead 1 is also the lead with the lowest response to the p-wave and typically shows a smaller amplitude of all waves as it is measuring flow across the heart and the actual impulse is diagonal from top right to bottom left normally, so you are only picking up the small horizontal signal rather than the large vertical one. The "antenna" cannot be part of the ECG as pacemakers may be implanted in different areas and that would mess up the reading of a waveform. Try to find information on Lifepack 12 or 15 monitors and you could get some real cool info as these are our standard EMS and trauma room units with all sorts of whiz-bang stuff in them like CO monitoring, blood pressure, O2 saturation, and defib/cardioversion/pacing.
I sexually Identify as an Attack Helicopter. Ever since I was a boy I dreamed of soaring over the oilfields dropping hot sticky loads on disgusting foreigners. People say to me that a person being a helicopter is Impossible and I'm fucking retarded but I don't care, I'm beautiful. I'm having a plastic surgeon install rotary blades, 30 mm cannons and AMG-114 Hellfire missiles on my body. From now on I want you guys to call me "Apache" and respect my right to kill from above and kill needlessly. If you can't accept me you're a heliphobe and need to check your vehicle privilege. Thank you for being so understanding.
wonder why they would go through the trouble to modulate the signal with a whole bunch of crap instead of just pulsing High on a heart beat :/
Good job dave. thanks