Design of intelligent heart rate and body temperature detection system based on single chip microcomputer

Publisher:熙风细雨Latest update time:2022-05-01 Source: eefocus Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

This article introduces a heart rate and body temperature detection system based on a single-chip microcomputer. The circuit part of this design mainly includes: sensor measurement circuit, amplifier circuit, filter shaping circuit, AD conversion circuit, control circuit, power supply circuit, etc. The host computer is programmed through the VC interface.


Through the control of the host computer buttons, the weak signals input by PT100 and TCRT5000 are amplified and shaped, and finally AD acquisition conversion is transmitted to the microcontroller, and the relevant body temperature and heart rate information is displayed on the host computer interface.

1 Hardware Block Diagram Design 

The heart rate and body temperature data acquisition device designed this time is based on STC89C52, so a temperature sensor and an infrared sensor for measuring human heart rate signals are required. The temperature sensor uses PT100 and amplifies the captured voltage through an amplifier circuit, and then performs AD conversion through ADC0804 and finally sends it to the 52 single-chip microcomputer.


Experiments have shown that if TCRT5000 uses a reflective connection, the changes in the human heart rate signal it obtains are relatively weak and the waveform is difficult to capture. Therefore, two TCRT5000s are used in the design to obtain the human heart rate signal by docking.


The weak heart rate signal obtained by the TCRT5000 receiving end is amplified by a secondary analog amplifier circuit, and then the waveform quality is improved by a filter circuit. Finally, the waveform is changed into a square wave circuit by a comparison circuit, and its amplitude is converted into a 5V standard digital level that can be recognized by the microcontroller, and output to the microcontroller for collection.


The host computer design uses 3 buttons in the design, which can be used to start and stop the test and control the system. The heart rate and body temperature values ​​obtained are displayed through the host computer interface. The specific circuit diagram is shown in the appendix, and the overall framework diagram is shown in the figure:


Hardware design block diagram


2 Body temperature collection circuit design 

The body temperature collection circuit is mainly composed of three parts: PT100 sensor circuit, signal amplification sampling circuit, and AD conversion circuit, and finally sends the signal to the microcontroller for processing.


2.1 PT100 sensor circuit

The PT100 sensor circuit mainly converts the resistance change of PT100 caused by temperature change into voltage change, which is convenient for the subsequent circuit collection. Since the resistance of PT100 is 100 ohms at 0 degrees, the corresponding voltage can be obtained by comparing with the resistance of 100 ohms. Part of the circuit is shown in the figure:

PT100 sensor circuit


2.2 Signal Amplification Circuit

Since the resistance of PT100 changes little with temperature, the voltage value obtained through the series circuit of 5V and 100 ohm resistor changes little. If it is obtained directly, there will be a large error, so signal amplification is required.


The amplifier circuit uses the differential method to filter out the error of the circuit itself, subtracts the reference voltage 2.5V from the standard 100 ohm, and amplifies the changing voltage through an adjustable resistor. Finally, the amplified voltage value is transmitted to the AD conversion chip through the subtraction circuit. The relevant circuit is shown in the figure:


Signal amplifier circuit


2.3 AD conversion circuit

AD0804 converts the amplified analog voltage value output by the signal amplifier circuit into 8-bit binary data and transmits it to the microcontroller. The reference power supply of AD0804 takes half of the maximum value of the input signal voltage. For example, when the input signal voltage range is 0-5V, the reference power supply is selected as 2.5V.


ADC0804 has a clock generation circuit inside. As long as a pair of resistors and capacitors are connected to the external clk1 pin and clkr, the clock required for AD conversion can be generated. Its oscillation frequency is fclk=1/1.1RC. Typical application parameters are: R=10K, C=150PF, fCLK=640KHZ, and the conversion speed is 100us. The specific connection method is as shown in the figure below:

AD conversion circuit


3. Heart rate signal acquisition circuit design 

The heart rate acquisition circuit includes several parts such as infrared transmitting circuit, infrared receiving circuit, signal amplifying circuit, filtering circuit and waveform conversion circuit.


3.1 Infrared Transmitter Circuit

The infrared transmitting circuit mainly connects the transmitting end of the infrared reflective TCRT5000 to the corresponding power supply to generate an infrared signal. The specific circuit is as follows:


Infrared transmitter circuit


3.2 Infrared receiving circuit

The infrared receiving circuit receives the infrared signal from the transmitting end, and obtains the corresponding infrared signal value by obtaining the voltage of the receiving end C and E. Because the human heart rate signal is an AC signal, a capacitor is used to isolate the DC signal at the receiving end. The circuit is as follows:

Infrared receiving circuit


3.3 Secondary signal amplification circuit

The heart rate signal obtained from the receiving circuit is very small, so it needs to be amplified by an amplifier circuit. This time, the signal is amplified by the negative feedback reverse proportional amplifier circuit of the operational amplifier. The circuit is shown in the figure:

Secondary signal amplifier circuit


3.4 Filter Circuit

The amplifier circuit amplifies the required heart rate signal, and also amplifies some noise signals at the input end, generating some sharp pulses. Therefore, these noise signals need to be filtered out through a filter circuit. This design uses a 2-stage RC circuit for filtering. The specific circuit is as follows:


Filter circuit


3.5 Waveform Conversion Circuit

The waveform obtained from the filter circuit is analog, similar to a sine signal, with a relatively gentle rising and falling edge, and cannot be directly obtained by the single-chip microcomputer. Instead, this gentle waveform needs to be transformed into a relatively steep pulse signal in the form of a square wave, and the amplitude is a 5V level that can be recognized by the single-chip microcomputer. Therefore, the waveform transformation can be achieved through the comparator LM393. By setting a reference voltage value for comparison at the input end, a 5V high level is output when it exceeds this reference voltage, and a 0V low level is output when it is lower than this reference voltage. A pull-up resistor is connected to the output end to improve the output drive capability of the LM393. The specific circuit is as follows:

Waveform conversion circuit


4 Alarm circuit design 

The alarm circuit mainly realizes that when the test is in progress, if the value obtained by the test exceeds the set range, the microcontroller controls the switch of the buzzer to alarm. The circuit is shown in the figure:

Alarm circuit


5 Software Programming 

When powered on, the program initializes all parameters and the timer 2 working mode starts running. When receiving the key input of external interrupt 0, the key value pressed is saved and which key is pressed is determined. The host computer key controls the start and stop of the test. In the test state, the body temperature and heart rate are collected by delaying a certain time, and then the collected values ​​are displayed and the alarm is determined. If it is not within the range, an alarm is issued.


Reference address:Design of intelligent heart rate and body temperature detection system based on single chip microcomputer

Previous article:Course Design of Intelligent Temperature Meter Based on Single Chip Microcomputer
Next article:Design of automobile drunk driving monitoring system based on single chip microcomputer

Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号