Note: * is required.
[Please fill in during the registration stage↓]
Our team members are all graduate students in electronic information-biomedical engineering. Our team members have won multiple provincial/national awards/champions in electronic/computer design competitions. I love electronic design, like to delve into technology, and have a strong pursuit of electronic technology. The captain worked as an electronic engineer in a research institute for two years and has rich practical experience.
Cardiovascular disease is the number one killer that endangers the lives of Chinese people. Currently, most of the mature ECG monitors cost more than 600 yuan. This price makes it difficult to popularize them. We want to develop one that is cheap enough and portable enough. An automatic ECG monitoring and analysis device that is useful enough. Help protect the cardiovascular health of Chinese people.
This project is a three-lead ECG electrocardiogram detection and analysis device. The hardware part is a USB ECG signal acquisition card. The ECG signal is collected and processed, and finally uploaded to the computer. In the computer, python is used to develop the host computer and process it, and display it. It can output electrocardiogram, spectrum, etc., and provide various analysis functions for heart fibrillation detection. This project is a derivative product independently developed by members of our laboratory's R&D mission. It aims to stably, quickly and reliably identify atrial fibrillation and ventricular fibrillation in complex environments, and provides a very economical ECG monitoring method, laying the foundation for the overall work of large projects. The foundation will continue to be developed in the future.
[Please fill in during the competition stage↓]
The hardware part of this project uses GD32F130F8P6 as the main control to provide the function of collecting data and uploading it. Use operational amplifiers to build various amplification/filter trap circuits to extract the three-lead ECG signals and filter out common interference. The USB to serial port chip is used to solve the communication problem between the MCU serial port and the host computer. The following is a general block diagram of the hardware structure:
On the host computer side, we used python/C++ mixed programming to build a host computer that integrates ECG recording/display/analysis, providing analysis such as heart rate detection, spectrum analysis, atrial fibrillation and ventricular fibrillation, and invited well-known professional doctors to provide guidance and verification ( laboratory partnership). The following is the general framework of the host computer software design:
Our initial plan was to use the AD8232 chip to extract ECG signals. However, after testing, we found that both our test circuit and the DEMO board we bought can only maintain good work in an interference-free state (turn off all AC appliances in the room). ), the anti-interference performance is extremely poor. The picture below is a typical waveform. This is the output waveform when we turn off all electrical appliances and turn on only one desk lamp (testing the AD8232 red module bought on Taobao): As you can see in the picture above, there is a very high amplitude We analyze that the 50Hz power frequency noise is due to the insufficient driving capability of the feedback from the right leg and internal design reasons. Of course, if it is pure 50Hz interference, we can achieve it through post-stage filtering. After consulting the datasheet and practice, we found that due to the internal design reasons of AD8232, when the 50Hz interference reaches a certain level, oscillation will be caused:
Considering that our project will need to work in a more complex environment in the future, such as being applied to an electric defibrillation environment, which requires high anti-interference performance and flexibility guarantee, we chose to use discrete operational amplifiers to build our own small signal extraction circuit:
< br> After testing, the anti-interference performance is much stronger than AD8232. The conditions for our test are that air conditioners, induction cookers and other relatively high-power equipment are fully turned on. The picture below is the test report saved by the oscilloscope:
The 50Hz power frequency interference is almost completely filtered out, leaving only the 100KHz switching noise that is easy to process (it is too different from the operating frequency, so no need to process).
In terms of ECG analysis, how to analyze ventricular fibrillation and atrial fibrillation has become a key issue in the software. We have developed a "spectral feedback closed-loop approximate entropy cardiac fibrillation detection algorithm" to solve the identification problem of atrial fibrillation while greatly reducing the number of leads. Misjudgment problems caused by poor connection or strong interference. Algorithms have also been developed for identifying heart rate and other functions. The following is the general framework of the spectral feedback approximate entropy heart fibrillation identification algorithm:
< br> In actual programming, we encountered the problem of excessive program calculations:
For the first calculation, the PC took 3 hours to calculate the data.
The second time, we optimized the calculation amount based on actual needs, and the calculation time was reduced to 12 minutes.
For the third time, we optimized the running efficiency of the python program, and the calculation time was further reduced to 1.2S.
However, this still cannot meet our requirements, because the program not only needs to be real-time, but also has the ability to be transplanted to embedded devices, which is obviously not feasible. We transplanted the algorithm to C/C++, leaving an external interface, and compiled it into a dynamic link library, which is dll on windows and so on linux/macOS. Python calls the dynamic link library when calculations are needed to achieve acceleration. The measured calculation speed has increased by 150 times.
< br>
We need to overcome the 50Hz interference problem in various environments. In terms of hardware, we made a fourth-order double-T active notch circuit, which also enhanced the signal of the right leg driving part and enhanced the anti-interference ability of the device (compared with the online Comparison of AD8232 modules on sale). In terms of software, we adopt a spectrum dynamic closed-loop feedback method, which greatly reduces the probability of misjudgment of heart fibrillation. We use the method of calculating information entropy to analyze the orderliness of the ECG signal. In atrial fibrillation and ventricular fibrillation, the approximate entropy can be as high as 0.6-0.9, while in normal conditions, the approximate entropy is only between 0.1-0.4. In the interference state, heart fibrillation can be clearly identified. In the case of severe interference, the entropy will increase greatly, and the dynamic feedback of the spectrum can solve this problem. The project software is divided into three parts:
1. The main function of GD32 slave computer firmware software is to collect the conditioned ECG signal, perform preliminary processing such as filtering, and upload it in real time.
2. The host computer software written in Python is responsible for the graphical interface and algorithms with low time complexity. Python’s cross-platform features allow the software to be easily transplanted to various platforms, such as Raspberry Pi, Orange Pi, industrial computers, mobile phones, etc. . Portability makes secondary development extremely easy. For example, you only need to purchase a minimum Linux system board and a small screen to easily change this project into a handheld ECG monitor, and the cost is still far lower than Worldly products. ~~~~
3. The dynamic link library is written and compiled in C/C++. This part is mainly responsible for time-consuming algorithms such as entropy analysis and calculation. Entropy algorithms often take several seconds to calculate in python. Writing in C/C++ can reduce it to milliseconds. Ensure the real-time and performance of the host computer program. Python calls the C/C++ dynamic link library to analyze atrial fibrillation and ventricular fibrillation. When porting to a different architecture CPU, the dynamic link library needs to be recompiled.
5.1. Print the competition logo picture on the PCB. Failure to do so will be deemed as giving up the competition . 5.2. Other pictures of the project
6.1. Video upload contest official website
uploaded.
6.2. Video title and link at Station B
Project introduction: < /span> https://www.bilibili.com/video/BV1nV411S7pG?from=search&seid=15477962878967354335 < br> < br> < br> Team introduction: < /span> https://www.bilibili. com/video/BV1Tk4y1y7RW?from=search&seid=15477962878967354335 < br> < br> < br> Function demonstration & performance test: < /span> https://www.bilibili.com/video/BV1vv41117U7?from=search&seid=15477962878967354335 < br> < br> < br> < br> Notes: ①: Video requirements: Please shoot horizontally, the resolution is no less than 1280×720, the format is Mp4/Mov, the size of a single video is limited to 100M; ②: Video upload: Please upload it to the official website of the competition and Station B ( www.bilibili.com ) at the same time. The top 10 most popular projects at Station B will receive a cash reward of 1,000-5,000 yuan, and other uploaded projects will receive a 100-yuan Lichuang Mall no-threshold coupon; ③: Video title: No. The 5th Lichuang Electronic Design Competition: {Project Name}-{Video Module Name}; such as the 5th Lichuang Electronic Design Competition: "Autonomous Driving" Project - Team Introduction. ~~~~
7.1. Please indicate whether the project has been published or won awards before.
Answer: The project is released for the first time.
7.2. If the project is optimized on the original basis, please explain the optimization part
none
see attached.
None
Click the link for more details: https://www.szlcsc.com/go/dsxq
All reference designs on this site are sourced from major semiconductor manufacturers or collected online for learning and research. The copyright belongs to the semiconductor manufacturer or the original author. If you believe that the reference design of this site infringes upon your relevant rights and interests, please send us a rights notice. As a neutral platform service provider, we will take measures to delete the relevant content in accordance with relevant laws after receiving the relevant notice from the rights holder. Please send relevant notifications to email: bbs_service@eeworld.com.cn.
It is your responsibility to test the circuit yourself and determine its suitability for you. EEWorld will not be liable for direct, indirect, special, incidental, consequential or punitive damages arising from any cause or anything connected to any reference design used.
Supported by EEWorld Datasheet