Holter ECG (AD8232, Bascom, KokkeKat FAT)
Hi!
I wanted to share with you the description of the construction that my life forced me to make.
I had some periodic heart problems and every time I got Holter it all calmed down
If any of you have ever tried to sign up for Holter, you know that it is not easy. He waits and waits.
I decided to take matters into my own hands and build a simple, single-channel device.
While searching the internet, I came across a specialized differential amplifier (AD8232) with a filter, which is used in heart rate recorders. So I decided not to balance the open door by building a differential amplifier from scratch and ordered a few pieces of this circuit.
The layout is located on a double-sided PCB with dimensions of 42 x 32 mm. The use of the AD8232 chip requires a fairly precise PCB - the pins of the system are in a 0.5 mm raster. I make the tiles using photosensitive foil to expose screen printing screens. As a cliché, I use tracing paper printed on a laser printer and optically compacted in vapors of nitro thinner. The guides are Bungard 0.6 mm (O.D.).

The system is powered by a small Li-Poly 250 mAh battery. Its capacity is enough for about 5-7 days of continuous operation.
The battery is charged via the microUSB socket and the MCP7381 system, and the power supply to the system is provided by the MCP1703 stabilizer (3.3 V).
The amplifier operates in the configuration shown in the catalog note in figure 68 (PORTABLE CARDIAC MONITOR WITH ELIMINATION OF MOTION ARTIFACTS).
The signal from the amplifier is fed directly to the ADC input of the Atmega 168 controller.
One TACT button is used to operate the recorder. Long (> 3 s) press turns on / off, short press is "event button" - it gives a characteristic, well recognizable pin in the record.
The blue diode shows that the button is pressed, the green diode shows active recording, the red diode shows a card error or the disconnection of one of the electrodes.
The recorder saves on the card hourly files in binary format, 16 bit unsigned and with the sampling frequency of 250 Hz. Numbering is automatic from "000.PCM"
The easiest way to preview a recording is to open it in an audio processing program (Audacity - free, Audition - paid), which allows you to preview the graph in a large window (Audacity: view -> vertically fit).
The construction of the Holter was also an opportunity to "face" an alternative to AVR Dos - the KokkeKat FAT library. KokkeKAT allows you to use a processor with less RAM than AVR Dos. And here, unfortunately, I must say that it is better to invest in a larger processor and use AVR Dos than to fight KokkeKAT. The latter is very capricious, poorly documented, and there are very few described structures operating with it. It is also not updated and corrected. Following the attached PDF file will result in either compilation errors or failure to read / write to the card. Until the end, I was unable to read the entire 8 + 3 file name. Only works for names no longer than 4 characters plus the extension. And not always. Reading the file name often fails and the processor (after a reset) writes the numbering over again, luckily without overwriting the existing files. Fortunately, this is not a big problem. You just have to remember to delete all files from the card in case of reprogramming the processor or disconnecting the power supply. If any of you want to bite into the program, I will be happy to find out where I made a mistake.
The plate design (Corel 9, PDF) and the program files are attached.
Best wishes
I wanted to share with you the description of the construction that my life forced me to make.
I had some periodic heart problems and every time I got Holter it all calmed down

If any of you have ever tried to sign up for Holter, you know that it is not easy. He waits and waits.
I decided to take matters into my own hands and build a simple, single-channel device.
While searching the internet, I came across a specialized differential amplifier (AD8232) with a filter, which is used in heart rate recorders. So I decided not to balance the open door by building a differential amplifier from scratch and ordered a few pieces of this circuit.
The layout is located on a double-sided PCB with dimensions of 42 x 32 mm. The use of the AD8232 chip requires a fairly precise PCB - the pins of the system are in a 0.5 mm raster. I make the tiles using photosensitive foil to expose screen printing screens. As a cliché, I use tracing paper printed on a laser printer and optically compacted in vapors of nitro thinner. The guides are Bungard 0.6 mm (O.D.).



The system is powered by a small Li-Poly 250 mAh battery. Its capacity is enough for about 5-7 days of continuous operation.
The battery is charged via the microUSB socket and the MCP7381 system, and the power supply to the system is provided by the MCP1703 stabilizer (3.3 V).
The amplifier operates in the configuration shown in the catalog note in figure 68 (PORTABLE CARDIAC MONITOR WITH ELIMINATION OF MOTION ARTIFACTS).
The signal from the amplifier is fed directly to the ADC input of the Atmega 168 controller.
One TACT button is used to operate the recorder. Long (> 3 s) press turns on / off, short press is "event button" - it gives a characteristic, well recognizable pin in the record.
The blue diode shows that the button is pressed, the green diode shows active recording, the red diode shows a card error or the disconnection of one of the electrodes.
The recorder saves on the card hourly files in binary format, 16 bit unsigned and with the sampling frequency of 250 Hz. Numbering is automatic from "000.PCM"
The easiest way to preview a recording is to open it in an audio processing program (Audacity - free, Audition - paid), which allows you to preview the graph in a large window (Audacity: view -> vertically fit).
The construction of the Holter was also an opportunity to "face" an alternative to AVR Dos - the KokkeKat FAT library. KokkeKAT allows you to use a processor with less RAM than AVR Dos. And here, unfortunately, I must say that it is better to invest in a larger processor and use AVR Dos than to fight KokkeKAT. The latter is very capricious, poorly documented, and there are very few described structures operating with it. It is also not updated and corrected. Following the attached PDF file will result in either compilation errors or failure to read / write to the card. Until the end, I was unable to read the entire 8 + 3 file name. Only works for names no longer than 4 characters plus the extension. And not always. Reading the file name often fails and the processor (after a reset) writes the numbering over again, luckily without overwriting the existing files. Fortunately, this is not a big problem. You just have to remember to delete all files from the card in case of reprogramming the processor or disconnecting the power supply. If any of you want to bite into the program, I will be happy to find out where I made a mistake.
The plate design (Corel 9, PDF) and the program files are attached.
Best wishes
Comments
Hello I can see one electrode in the photo, maybe I am wrong, while ECG uses 12-15 electrodes as standard, while checking the heart rate requires 3 to 5 leads. Each of them has a specific place on the... [Read more]
I only put one electrode in the photo to show that I used system solutions. There are actually 3 electrodes - one "zero" and two differential for one channel (you can see 3 wires coming from the recorder). ... [Read more]
Yes, to be precise: the standard ECG test is performed with 10 electrodes - 4 limb electrodes ("R", "L", "F", "N") and 6 precordial electrodes ("V1" ÷ "V6"). Leads "I", "II" and "III" are obtained from... [Read more]
But the Holter is not a standard EKG, it only has three electrodes and that's it. Apparently enough to see deeper heart disorders is enough, I also had it done and showed something. [Read more]
YES, YES and YES again! My correction (?) Concerned post # 2 - which had some confusion with the nomenclature (leads vs. electrodes). In the simplest case, 3 electrodes are enough - 2 as a differential... [Read more]
Can you show the device operation graph? [Read more]
From what I can see this is the second and third photo in the first message. [Read more]
I didn't know there were such arrangements. As I read the article, I thought about an expensive and rare integrated circuit. I entered it in google and here's a surprise: https://obrazki.elektroda.pl/5603990500_1603388597_thumb.jpg... [Read more]
Where did your colleague get these leads with electrode connectors? Does this connector have a name? In my searches, I was able to find some ready-made sets of cables for several dozen euros. [Read more]
Tu oferta Banggood Link [Read more]
A single-channel ECG will give the doctor the basic possibilities of recognizing the nature of an arrhythmia, sometimes it will answer the question of what type it is. Moreover, it is a completely objective... [Read more]
Question to the author of the thread - can you interpret the second graph? The first one is nice, almost textbook. The second is different - significant difference in amplitude - measurement error or actual... [Read more]
Numerous additional supraventricular stimuli, artifacts. [Read more]
On Aliexpress, there is a plate with wires below PLN 20. [Read more]
This is atrial fibrillation. Cables - search on Allegro: tens electrodes in the same place: ecg electrodes The matter is very simple. The AD8232 outputs an amplified (and filtered) signal of... [Read more]
This is called atrial flutter, however irregular. [Read more]
Hi By using this topic (hopefully neither the author, nor the administration, nor any of the users will be angry) as it is very topical, especially in the times we have today. First of all, I would like... [Read more]
Welcome. Long press turns the system on / off. Registration is continuous when the system is turned on. A short press gives a characteristic pin on the graph. In this way, you can mark the moment of problems,... [Read more]
Hi Thank you for your answer. For me, you are a professional, unfortunately I can only call myself a beginner, especially in the field of electronics / automation. I do not want to take any steps rashly,... [Read more]