Author Topic: Pictures within microcontrollers  (Read 15996 times)

0 Members and 1 Guest are viewing this topic.

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #50 on: December 04, 2014, 08:52:04 pm »
Quote

It's a noble enough project, but more sited for a Uni degree or something like that IMHO.

yes i do agree, and i would like to go to do my hnc/hnd,and further into the field, but for now, all i can do is work with what i have, and at least attempt to work on it, and try and complete until im able to go to uni.
Jules
 

Offline free_electron

  • Super Contributor
  • ***
  • Posts: 8518
  • Country: us
    • SiliconValleyGarage
Re: Pictures within microcontrollers
« Reply #51 on: December 04, 2014, 09:07:36 pm »
maybe a silly question but let's take a look at step 1 :

do you have a working circuit that can pick up the heartbeatsignal and reject all the unwanted 'noise' ( baby tossing an turning, hitting the side of the bed, some kid with a badly dampened motorcycle nextdoor gooing brumbrumbrumbwabwabwabweeeeeeee ( you know what i mean , those undampened spark plugs cause massive noise in the spectrum ) ,and all other possible sources of disturbances.

that alone is not easy to do : picking up reliably the heartbeat.  you say you want to put the sensor in a blanket.. what if the kid shifts a bit in respect to where the sensor is.

have you actually tried those things with a real baby ? does it work 100% ?

if not -> back tot the drawing board. you ain't even close to tackling the cpu part.
a cpu with display showing pictures is the easy part.

the hard bit is the acquisition and conditioning of a reliable clean signal ... that is where most of the hard work will be
Professional Electron Wrangler.
Any comments, or points of view expressed, are my own and not endorsed , induced or compensated by my employer(s).
 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #52 on: December 04, 2014, 09:19:40 pm »
maybe a silly question but let's take a look at step 1 :

do you have a working circuit that can pick up the heartbeatsignal and reject all the unwanted 'noise' ( baby tossing an turning, hitting the side of the bed, some kid with a badly dampened motorcycle nextdoor gooing brumbrumbrumbwabwabwabweeeeeeee ( you know what i mean , those undampened spark plugs cause massive noise in the spectrum ) ,and all other possible sources of disturbances.

that alone is not easy to do : picking up reliably the heartbeat.  you say you want to put the sensor in a blanket.. what if the kid shifts a bit in respect to where the sensor is.

have you actually tried those things with a real baby ? does it work 100% ?

if not -> back tot the drawing board. you ain't even close to tackling the cpu part.
a cpu with display showing pictures is the easy part.

the hard bit is the acquisition and conditioning of a reliable clean signal ... that is where most of the hard work will be

Hi thanks for your comment, yes i have a working circuit, when i say working i mean it picks up my heartbeat, when in bed, the sensors are embedded into a sheet, with conductive thread, its not wireless at the moment,
i have a bandpass filter, which was accurate enough for my college project, and had no problems picking up my heart beat, for 48 hours, i have not tried it on a child, simple because im not prepared to put anyone in any form of danger, until im told by someone whom is qualified in hnc/d checks the circuit, although i was told by my college teacher, it was fine, but i prefer to be the test subject, until i know its protected from anyone else getting any type of feedback, bear in mind this circuit which works is without a mcu.
Jules
 

Offline Wilksey

  • Super Contributor
  • ***
  • Posts: 1329
Re: Pictures within microcontrollers
« Reply #53 on: December 04, 2014, 09:39:21 pm »
Well, that escalated quickly!

It won't have medical approval so it can't be used as the holy saviour of the medical world, but for a bit of monitoring, where's the harm?

Purely depends on how it is marketed, it is not a device to prevent heart failure, it is a monitoring TOOL.

Am I oversimplifying this? The tool can be used to alert parent's / carers if anything is awry, serious cases will be hooked up to a pukka heart monitor in the hospital anyway.

This can be used on adults as well as infants.

If a child is born with a hole in it's heart for example, I guess you could monitor for abnormal rhythms and the like.

I still think it's a good idea, just expect to put in a LOT of work if it has to ever meet medical approval.

And hey, even if it doesn't sell, at least you will have learned a lot by trying!
 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #54 on: December 04, 2014, 09:58:13 pm »
Well, that escalated quickly!

It won't have medical approval so it can't be used as the holy saviour of the medical world, but for a bit of monitoring, where's the harm?

Purely depends on how it is marketed, it is not a device to prevent heart failure, it is a monitoring TOOL.

Am I oversimplifying this? The tool can be used to alert parent's / carers if anything is awry, serious cases will be hooked up to a pukka heart monitor in the hospital anyway.

This can be used on adults as well as infants.

If a child is born with a hole in it's heart for example, I guess you could monitor for abnormal rhythms and the like.

I still think it's a good idea, just expect to put in a LOT of work if it has to ever meet medical approval.

And hey, even if it doesn't sell, at least you will have learned a lot by trying!

Hi there wilksey, thanks for your input so far,
The way it started was to build an ecg, some way i could watch and monitor my heart beat,
then my son was born, thats what made me think, hmmmm, why cant i use this type of device, to monitor and and possibly prevent infants from heart conditions,
so yes to answer your question,
it has been built as a monitoring tool, and to try and prevent infants from dying whom have heart conditions from an early age, with the idea, of being able to put the sheet under infants cot, and it alerts the parents /careers or guardian of any possible up and coming heart conditions, there is alittle more to it within the coding side, ( ie to be able to give guidance on what to do and what not to do ( depending on what type of heart condition is happening) this will be done by professional medical personnel only)).
The basic idea behind it, and please do correct me if im wrong here, but if a infant was at home, after birth and is known to have heart problems, ( that im aware off heart attacks etc normally only last upto 2 minutes, that im aware off an ambulance takes around 5 upto 10 mins, depending on where they live of course,
therefore if i infant was to have a attack, they would have around 2-5 minutes max before possible death,

If i can get this device to work how im wanting it too, the basic idea is, infants "hooked up to it", parents are alerted say 20 mins before it happens and machine tells they to take infant to hospital as childs having congestive heart failure.
With the hopes the paretns would take the child to hosptial, child can then be seen by professional docts, who might be able to save childs life,
And yes it is possible it could work on adults, and oap's,

"If a child is born with a hole in it's heart for example, I guess you could monitor for abnormal rhythms and the like." yes i completely agree there, i have a list of heart related problems, how they are caused, what patterns to look for, what i t looked like on an oscilloscope etc.
Jules
 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #55 on: December 04, 2014, 10:03:29 pm »
Differentiating the P-, QRS- and T-waves
Because of the anatomical difference of the atria and the ventricles, their sequential activation, depolarization, and repolarization produce clearly differentiable deflections. This may be possible even when they do not follow one another in the correct sequence: P-QRS-T.

 Identification of the normal QRS-complex from the P- and T-waves does not create difficulties because it has a characteristic waveform and dominating amplitude. This amplitude is about 1 mV in a normal heart and can be much greater in ventricular hypertrophy. The normal duration of the QRS is 0.08-0.09 s.
 If the heart does not exhibit atrial hypertrophy, the P-wave has an amplitude of about 0.1 mV and duration of 0.1 s. For the T-wave both of these numbers are about double. The T-wave can be differentiated from the P-wave by observing that the T-wave follows the QRS-complex after about 0.2 s.





Supraventricular rhythms

Definition
Cardiac rhythms may be divided into two categories: supraventricular (above the ventricles) and ventricular rhythms.
 The origin of supraventricular rhythms (a single pulse or a continuous rhythm) is in the atria or AV junction, and the activation proceeds to the ventricles along the conduction system in a normal way. Supraventricular rhythms
Normal sinus rhythm
Normal sinus rhythm is the rhythm of a healthy normal heart, where the sinus node triggers the cardiac activation. This is easily diagnosed by noting that the three deflections, P-QRS-T, follow in this order and are differentiable. The sinus rhythm is normal if its frequency is between 60 and 100/min.<

The extra Definition part, is a reminder for me for when I look back at this part.


Name   Description   Heart and beat
Sinus Tachycardia   If the sinus rhythm is irregular such that the longest PP- or RR-interval exceeds the shortest interval by 0.16 s, the situation is called sinus arrhythmia. This situation is very common in all age groups. This arrhythmia is so common in young people that it is not considered a heart disease. One origin for the sinus arrhythmia may be the vagus nerve which mediates respiration as well as heart rhythm. The nerve is active during respiration and, through its effect on the sinus node, causes an increase in heart rate during inspiration and a decrease during expiration. The effect is particularly pronounced in children.
 Note, that in all of the preceding rhythms the length of the cardiac activation cycle (the P-QRS-T-waves together) is less than directly proportional to the PP-time. The main time interval change is between the T-wave and the next P-wave. This is easy to understand since the pulse rate of the sinus node is controlled mainly by factors external to the heart while the cardiac conduction velocity is controlled by conditions internal to the heart.   
Wandering Pacemaker   Paroxysmal atrial tachycardia (PAT)
Paroxysmal atrial tachycardia (PAT) describes the condition when the P-waves are a result of a reentrant activation front (circus movement) in the atria, usually involving the AV node. This leads to a high rate of activation, usually between 160 and 220/min. In the ECG the P-wave is regularly followed by the QRS-complex. The isoelectric baseline may be seen between the T-wave and the next P-wave.
Atrial flutter
When the heart rate is sufficiently elevated so that the isoelectric interval between the end of T and beginning of P disappears, the arrhythmia is called atrial flutter. The origin is also believed to involve a reentrant atrial pathway. The frequency of these fluctuations is between 220 and 300/min. The AV-node and, thereafter, the ventricles are generally activated by every second or every third atrial impulse (2:1 or 3:1 heart block).
the AV-nodal impulse reaches the atria before, simultaneously, or after the ventricles, an opposite polarity P-wave will be produced before, during, or after the QRS-complex, respectively. In the second case the P-wave will be superimposed on the QRS-complex and will not be seen.   
Junctional Rhythm   In ventricular arrhythmias ventricular activation does not originate from the AV node and/or does not proceed in the ventricles in a normal way. If the activation proceeds to the ventricles along the conduction system, the inner walls of the ventricles are activated almost simultaneously and the activation front proceeds mainly radially toward the outer walls. As a result, the QRS-complex is of relatively short duration. If the ventricular conduction system is broken or the ventricular activation starts far from the AV node, it takes a longer time for the activation front to proceed throughout the ventricular mass.
 The criterion for normal ventricular activation is a QRS-interval shorter than 0.1 s. A QRS-interval lasting longer than 0.1 s indicates abnormal ventricular activation. Ventricular arrhythmias are presented in Figure 19.3.
Premature ventricular contraction
A premature ventricular contraction is one that occurs abnormally early. If its origin is in the atrium or in the AV node, it has a supraventricular origin. The complex produced by this supraventricular arrhythmia lasts less than 0.1 s. If the origin is in the ventricular muscle, the QRS-complex   
Ventricular Tachycardia   When ventricular depolarization occurs chaotically, the situation is called ventricular fibrillation. This is reflected in the ECG, which demonstrates coarse irregular undulations without QRS-complexes. The cause of fibrillation is the establishment of multiple re-entry loops usually involving diseased heart muscle. In this arrhythmia the contraction of the ventricular muscle is also irregular and is ineffective at pumping blood. The lack of blood circulation leads to almost immediate loss of consciousness and death within minutes. The ventricular fibrillation may be stopped with an external defibrillator pulse and appropriate medication.   
Ventricular Fibrillation   A ventricular rhythm originating from a cardiac pacemaker is associated with wide QRS-complexes because the pacing electrode is (usually)   
A-V Block, First Degree   If the PQ-interval is longer than normal and the QRS-complex sometimes does not follow the P-wave, the atrioventricular block is of second-degree. If the PR-interval progressively lengthens, leading finally to the dropout of a QRS-complex, the second degree block is called a Wenkebach phenomenon.   
A-V Block, second  Degree   Complete lack of synchronism between the P-wave and the QRS-complex is diagnosed as third-degree (or total) atrioventricular block. The conduction system defect in third degree AV-block may arise at different locations such as:
•   Over the AV-node
•   In the bundle of His
•   Bilaterally in the upper part of both bundle branches
•   Trifascicularly, located still lower, so that it exists in the right bundle-branch and in the two fascicles of the left bundle-branch.
 
Third-degree atrioventricular block.
Bundle-branch block
Definition
Bundle-branch block denotes a conduction defect in either of the bundle-branches or in either fascicle of the left bundle-branch. If the two bundle-branches exhibit a block simultaneously, the progress of activation from the atria to the ventricles is completely inhibited; this is regarded as third-degree atrioventricular block (see the previous section). The consequence of left or right bundle-branch block is that activation of the ventricle must await initiation by the opposite ventricle. After this, activation proceeds entirely on a cell-to-cell basis. The absence of involvement of the conduction system, which initiates early activity of many sites, results in a much slower activation process along normal pathways. The consequence is manifest in bizarre shaped QRS-complexes of abnormally long duration. The ECG changes in connection with bundle- branch blocks are
Right bundle-branch block

If the right bundle-branch is defective so that the electrical impulse cannot travel through it to the right ventricle, activation reaches the right ventricle by proceeding from the left ventricle. It then travels through the septal and right ventricular muscle mass. This progress is, of course, slower than that through the conduction system and leads to a QRS-complex wider than 0.1 s. Usually the duration criterion for the QRS-complex in right bundle-branch block (RBBB) as well as for the left brundle- branch block (LBBB) is >0.12 s.
 With normal activation the electrical forces of the right ventricle are partially concealed by the larger sources arising from the activation of the left ventricle. In right bundle-branch block (RBBB), activation of the right ventricle is so much delayed, that it can be seen following the activation of the left ventricle. (Activation of the left ventricle takes place normally.)
 RBBB causes an abnormal terminal QRS-vector that is directed to the right ventricle (i.e., rightward and anterior). This is seen in the ECG as a broad terminal S-wave in lead I. Another typical manifestation is seen in lead V1 as a double R-wave. This is named an RSR'-complex.   
Right Bundle Branch Block       


Jules
 

Offline mtdoc

  • Super Contributor
  • ***
  • Posts: 3575
  • Country: us
Re: Pictures within microcontrollers
« Reply #56 on: December 04, 2014, 10:13:41 pm »
Warner, the problem is that those ECG findings are generally  not sensitive or specific enough to be of use in evaluating pediatric heart disease - at least not in the context you are looking at.

To learn more about what I mean by sensitivity and specificity in a medic context see HERE
 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #57 on: December 04, 2014, 10:18:53 pm »
Warner, the problem is that those ECG findings are generally  not sensitive or specific enough to be of use in evaluating pediatric heart disease - at least not in the context you are looking at.

To learn more about what I mean by sensitivity and specificity in a medic context see HERE

Hey mtdoc,
completely agree with you, but it is a learning curve, i need to understand the basics of the heart conditions before i can work out how to do it electronically, without me understanding how these problems occur, happen causes etc, then i wont be able to work out how to be able to pick them up/ detect, or know where to start on being able to do this.
Jules
 

Offline paulie

  • Frequent Contributor
  • **
  • !
  • Posts: 849
  • Country: us
Re: Pictures within microcontrollers
« Reply #58 on: December 04, 2014, 10:40:37 pm »
Ok, well if you're going to be like that, then please be kind enough to explicitly define what you mean by "real time", "detection", "EKG" (number of leads, position?) and "EKG anomalies".

By real time I assume the few seconds required to take remedial action. As far as leads there don't seem to be any except for wires embedded in a sheet. My only experience resembling anything like this was an EEG analyzer for interpreting brainwave patterns. Research not medical. Even with sophisticated electrode design and electrolyte composition signals were too noisy for a run of the mill MCU so we resorted to a PC at 1/10th the development and 1/5th production cost. Practicality and economy prevailed over portability. It was some time ago but things have probably not changed that much. In my experience the relationship between signal to noise and processing requirement was not a linear nor a favorable one.

Also, please read this: http://link.springer.com/chapter/10.1007%2F978-3-642-53862-9_31

I'm not willing to shell out the 80 bucks to actually read your document but the vague reference to "electrocardiographic registers" and FPGA tells me there was a lot of preprocessing going on and maybe no MCU at all. No mention of JPG database either although we are not sure if OP is on the right track there either.

In any case whether FPU is used or not a PC would probably be a more practical and cost effective solution to what is proposed in this thread. Most certainly first iteration anyway. And VERY unlikely the OPs msp430 based design is up to the task.
 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #59 on: December 04, 2014, 10:47:08 pm »
wow love it, loads of info, awesome thank you love the links,
thank you,

and thank you too all whom give me advice muchly appreciated
Jules
 

Offline Wilksey

  • Super Contributor
  • ***
  • Posts: 1329
Re: Pictures within microcontrollers
« Reply #60 on: December 04, 2014, 11:14:34 pm »
What you are trying to achieve is perfectly do-able.

As others have said, there is a lot of information contained in this thread, I will not admit to knowing anything about medical equipment, just that it needs to have met certain approvals to be used professionally.

I can imagine it being sold in a similar capacity to a baby monitor almost, in the fact that it is an aid rather than anything else, regardless of it's uses if anything occurs whilst the device is being used, i.e. it alerts you to a heart attack etc.

If you work within the medical profession, or even if you know people who do, you can always ask them, if in doubt, you can always consult a lawyer about potential come backs if the product went into production, there's a lot of them in the UK that will give you 30 mins free advice, just find a decent one!

It's amazing how many useful products have emerged from someone's prototype which might or might not have been all that safe at one point, they may have even been told it was a rubbish idea, they don't have the right approvals etc etc  ;) so even if you do manage to produce a working prototype, it might not be that hard afterwards to improve it to the point where you can get approvals!  You just don't know!

Most of all, have fun and good luck with your project!
 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #61 on: December 04, 2014, 11:25:38 pm »
thank you wilksey
appreciated
Jules
 

Offline edavid

  • Super Contributor
  • ***
  • Posts: 3385
  • Country: us
Re: Pictures within microcontrollers
« Reply #62 on: December 04, 2014, 11:45:12 pm »
i need to understand the basics of the heart conditions before i can work out how to do it electronically...

So why are you here asking about electronics  :-//



 

Offline warnerTopic starter

  • Contributor
  • Posts: 48
  • Country: gb
    • UADV
Re: Pictures within microcontrollers
« Reply #63 on: December 04, 2014, 11:53:19 pm »
i need to understand the basics of the heart conditions before i can work out how to do it electronically...

So why are you here asking about electronics  :-//

im asking about mcu's, and i already understand the basics of heart conditions, i learnt that over a year ago whilst doing research, im here to learn more about electronics, and about mcu's especially, plus gather information and advice on building it.
Jules
 

Offline suicidaleggroll

  • Super Contributor
  • ***
  • Posts: 1453
  • Country: us
Re: Pictures within microcontrollers
« Reply #64 on: December 05, 2014, 12:04:28 am »
i need to understand the basics of the heart conditions before i can work out how to do it electronically...

So why are you here asking about electronics  :-//

im asking about mcu's, and i already understand the basics of heart conditions, i learnt that over a year ago whilst doing research, im here to learn more about electronics, and about mcu's especially, plus gather information and advice on building it.

You need to start by developing and testing your algorithm on a regular computer with a regular compiler, graphics, debugger, etc.  Only after you know exactly what mathematical operations, precision, and processing power you're going to need should you even consider moving to an embedded system.  You're putting the cart WAY before the horse here.  Develop the algorithm first, turn it into a product second...not the other way around.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf