Temperature detection circuit and temperature detection device
By combining a microcontroller and a high-precision analog-to-digital converter in the temperature detection circuit, and utilizing a switchable analog switch circuit with a multi-point calibrated precision resistor, the problem of nonlinear effects in PTC thermistor temperature measurement is solved, achieving high-precision temperature detection and stable calibration.
Patent Information
- Application Number
- CN202520399883.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-07
- Publication Date
- 2026-02-24
- Estimated Expiration
- 2035-03-07
AI Technical Summary
In existing technologies, PTC thermistor temperature measurement suffers from nonlinear effects, resulting in low accuracy of temperature measurement results and making it difficult to achieve high-precision calibration.
By combining a microcontroller with a high-precision analog-to-digital converter, and using a switchable analog switch circuit and a multi-point calibrated precision resistor, a temperature detection circuit is formed, enabling high-precision measurement and convenient calibration of a four-wire temperature sensor.
It improves the accuracy and stability of temperature detection, reduces system errors, simplifies the calibration process, and enhances the accuracy of temperature measurement and the stability of the system.
Smart Images

Figure CN223940410U_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of temperature detection technology, and in particular to a temperature detection circuit and a temperature detection device. Background Technology
[0002] Nowadays, in many industries, the requirements for temperature measurement accuracy are getting higher and higher. Even a small measurement error can lead to a decline in product quality or an increase in safety risks.
[0003] In related technologies, PTC thermistors are used for temperature measurement. A PTC thermistor is a temperature-dependent resistor with a high positive temperature coefficient (PTC). When the external temperature reaches a certain temperature, its resistance will increase significantly. Therefore, the measured temperature can be calculated by measuring its resistance value.
[0004] However, in the solutions provided by related technologies, factors such as the performance differences of the components used in the circuit, circuit design and layout, and power supply voltage stability can all have a nonlinear effect on temperature measurement. Under this nonlinear effect, error calibration is difficult, resulting in low accuracy of temperature measurement results. Utility Model Content
[0005] The purpose of this application is to provide a temperature detection circuit and a temperature detection device. By combining a microcontroller with a high-precision analog-to-digital converter, and with a switchable analog switch circuit and a precision resistor with multi-point calibration, high-precision measurement and convenient calibration of a four-wire temperature sensor are achieved, thereby effectively improving temperature detection accuracy, shortening the calibration process and reducing system error.
[0006] To achieve the aforementioned objectives, the application itself provides a temperature detection circuit, including:
[0007] The microcontroller is connected to the analog-to-digital converter via its serial peripheral interface and to the analog switching circuit via its control output.
[0008] The calibration circuit includes at least two precision resistors, which are connected to the analog-to-digital converter via the analog switching circuit.
[0009] The temperature measuring circuit is connected to the analog-to-digital converter via the analog switching circuit;
[0010] The analog switch circuit is used to connect to the temperature measuring circuit or the calibration circuit, and switches the connection when it receives a control signal sent by the control output terminal.
[0011] As a further improvement of this application, at least two precision resistors in the calibration circuit have different resistance values, and different resistance values correspond to different temperature points;
[0012] Specifically, two precision resistors are used for temperature calibration at two temperature calibration points, wherein the first temperature calibration point is below 30% of the maximum temperature measurement range, and the second temperature calibration point is above 70% of the maximum temperature measurement range.
[0013] As a further improvement to this application, the calibration circuit includes a first precision resistor, a second precision resistor, and a third precision resistor;
[0014] The first precision resistor and the third precision resistor are used for temperature calibration. The temperature corresponding to the first precision resistor is lower than the first temperature calibration point, and the temperature corresponding to the third precision resistor is higher than the second temperature calibration point.
[0015] The second precision resistor is used for accuracy verification. The temperature of the second precision resistor is higher than the first temperature calibration point and lower than the second temperature calibration point.
[0016] As a further improvement of this application, the temperature measuring circuit includes a four-wire platinum resistance temperature sensor, which is connected to different switches in the analog switch circuit via four leads.
[0017] As a further improvement of this application, the analog switching circuit includes four single-pole multi-throw switches, and the common terminal of each single-pole multi-throw switch is respectively connected to the excitation positive pin, excitation negative pin, detection signal positive pin and detection signal negative pin of the analog-to-digital converter.
[0018] At least one selector terminal of the single-pole multi-throw switch is connected to the calibration circuit, and at least one other selector terminal is connected to the temperature measurement circuit.
[0019] As a further improvement of this application, the temperature measurement circuit includes a four-wire platinum resistance temperature sensor. The four-wire platinum resistance temperature sensor is connected to the first selection terminals of the four single-pole multi-throw switches through four leads, and is connected to the excitation positive pin, the excitation negative pin, the detection signal positive pin, and the detection signal negative pin of the analog-to-digital converter through the single-pole multi-throw switches.
[0020] As a further improvement of this application, the calibration circuit has three precision resistors, and the excitation positive pins of the first precision resistor, the second precision resistor and the third precision resistor are connected in sequence to the second selection terminal, the third selection terminal and the fourth selection terminal of the first single-pole four-throw switch;
[0021] The positive pins of the detection signals of the first precision resistor, the second precision resistor, and the third precision resistor are sequentially connected to the second selection terminal, the third selection terminal, and the fourth selection terminal of the second single-pole four-throw switch;
[0022] The detection signal negative pins of the first precision resistor, the second precision resistor, and the third precision resistor are sequentially connected to the second selection terminal, the third selection terminal, and the fourth selection terminal of the third single-pole four-throw switch;
[0023] The excitation negative pins of the first precision resistor, the second precision resistor, and the third precision resistor are sequentially connected to the second selection terminal, the third selection terminal, and the fourth selection terminal of the fourth single-pole four-throw switch.
[0024] As a further improvement of this application, the analog switch circuit includes a digital decoder, one end of which is connected to the control output terminal in the microcontroller, and the other end is connected to four single-pole multi-throw switches respectively.
[0025] Specifically, when the single-pole multi-throw switch receives the control signal sent by the digital decoder, it switches the selection terminal connected to the common terminal.
[0026] As a further improvement of this application, it also includes: a gain resistor, one end of which is connected to the bias pin of the analog-to-digital converter, and the other end of which is connected to the current detection pin of the analog-to-digital converter.
[0027] As a further improvement of this application, the microcontroller, the calibration circuit, and the analog switch are respectively connected to the power supply via their power pins and to the reference level via their ground pins.
[0028] On the other hand, this application provides a temperature detection device, characterized in that it includes a temperature detection circuit as described in any of the above aspects.
[0029] Compared with the prior art, the beneficial effects of this utility model are as follows:
[0030] In this embodiment, a temperature sensing circuit is formed by setting up a temperature sensing circuit and connecting it to a high-precision analog-to-digital converter and a microcontroller, enabling accurate temperature detection. The temperature sensing circuit, combined with the microcontroller and the high-precision analog-to-digital converter, achieves high-precision temperature measurement. Furthermore, an analog switch circuit is connected to a calibration circuit, allowing for flexible switching between the temperature sensing circuit and the calibration circuit. This enables error calibration of the temperature sensing circuit, reducing hardware complexity, improving system calibration efficiency, and ultimately enhancing the accuracy and stability of temperature measurement and the temperature detection system. Attached Figure Description
[0031] Figure 1 A schematic diagram of a temperature detection circuit provided in an illustrative embodiment of this application is shown;
[0032] Figure 2A structural diagram of a temperature detection circuit provided in another illustrative embodiment of this application is shown. Detailed Implementation
[0033] The present application will now be described in detail with reference to the specific embodiments shown in the accompanying drawings. However, these embodiments do not limit the present application, and any structural, methodological, or functional modifications made by those skilled in the art based on these embodiments are included within the scope of protection of this application.
[0034] It should be noted that the term "comprising" or any other variation thereof is intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Furthermore, the terms "first," "second," "third," "fourth," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance.
[0035] Please refer to Figure 1 The diagram illustrates a temperature detection circuit provided in an illustrative embodiment of this application, including a microcontroller 110, an analog-to-digital converter 120, an analog switch circuit 130, a calibration circuit 140, and a temperature measurement circuit 150.
[0036] The microcontroller 110 is connected to the analog-to-digital converter 120 via its serial peripheral interface (SPI) and to the analog switch circuit 130 via its control output. The SPI is a full-duplex, synchronous communication bus primarily used for communication between the microcontroller 110 and various peripheral devices. In this embodiment, the SPI interface is mainly used for communication between the microcontroller 110 and the analog-to-digital converter 120. The microcontroller 110 is also connected to the analog switch circuit 130 via its control output. Optionally, the microcontroller 110 can be connected to the analog switch circuit 130 via a general-purpose input / output (GPIO) interface. The GPIO interface is configured in output mode, and the microcontroller 110 sends control signals to the analog switch circuit 130 through this interface.
[0037] The analog-to-digital converter 120 (ADC) 120 is connected to the microcontroller 110 via SPI on one end and to the calibration circuit 140 or the temperature measurement circuit 150 via the analog switch circuit 130. The ADC 120 is used to convert the received analog signal into a digital signal so that the microcontroller 110 can process it.
[0038] Optionally, a high-resolution (15-bit, with a resolution of 0.03125°C), self-compensated, and fault-detecting ADC chip can be used.
[0039] Optionally, the temperature detection circuit also includes a gain resistor, with one end connected to the bias pin of the analog-to-digital converter 120 and the other end connected to the current detection pin of the analog-to-digital converter 120. This gain resistor, in conjunction with the high-precision analog-to-digital converter 120, stabilizes the system gain or measurement range, enabling the microcontroller 110 to maintain consistent bias and current monitoring in temperature measurement or calibration modes. By selecting a high-precision resistor material with low temperature drift characteristics, the impact of temperature drift and component mismatch on the system measurement accuracy can be further reduced, thereby providing a more reliable sampling reference for temperature detection throughout the loop and improving the consistency and accuracy of measurement results.
[0040] The analog switch circuit 130 is used to switch the input signal source connected to the ADC according to the control signal sent by the microcontroller 110. It can be selected to be connected to the calibration circuit 140 or the temperature measurement circuit 150. The analog switch circuit 130 receives the control signal sent by the control output terminal of the microcontroller 110 and switches the connection according to the different states of the signal.
[0041] The calibration circuit 140 includes at least two precision resistors connected to the analog-to-digital converter 120 via an analog switching circuit 130. The calibration circuit 140 is used to eliminate errors introduced by the temperature detection circuit, which may include errors in the temperature sensing circuit 150, contact errors in the temperature sensing circuit 150, errors caused by other impedances in the loop, etc.
[0042] Precision resistors are resistive elements with high precision and stability. Their resistance changes very little with environmental factors such as temperature, humidity, and time, and they typically have a low temperature coefficient (TCR), ensuring that the resistance change is less than a certain standard under different temperature conditions. For example, a precision resistor with a temperature coefficient of 10 ppm / °C will only change its resistance by 0.01% when the temperature changes by 10°C.
[0043] Temperature sensing circuit 150 is connected to analog-to-digital converter 120 via analog switching circuit 130 for measuring temperature. Optionally, temperature sensing circuit 150 includes a temperature sensor, such as a thermistor or temperature sensor chip.
[0044] Indicative, such as Figure 1As shown, after the temperature detection circuit is connected, the microcontroller 110 initializes the SPI interface and configures the GPIO pins as control outputs. The analog switch circuit 130 is initialized, ensuring that it is initially connected to either the calibration circuit 140 or the temperature measurement circuit 150. Subsequently, the temperature detection circuit is calibrated. The microcontroller 110 sends a control signal through its control output to connect the analog switch circuit 130 to the calibration circuit 140. At least two precision resistors in the calibration circuit provide known voltage or current signals, which are input to the ADC through the analog switch circuit 130. The microcontroller 110 reads the ADC output data via SPI and calibrates the temperature measurement accuracy of the temperature detection circuit from at least two calibration points based on the known precision resistor values. After calibration, the controller sends a control signal through its control output to connect the analog switch circuit 130 to the temperature measurement circuit 150. The temperature measurement circuit 150 provides an analog signal, which is input to the ADC through the analog switch circuit 130. The microcontroller 110 reads the ADC output data via SPI, converts it into a temperature value, and performs further processing and display.
[0045] In summary, in this embodiment, by setting up a temperature measuring circuit and connecting it to a high-precision analog-to-digital converter and a microcontroller to form a temperature detection circuit, accurate temperature detection can be achieved. The combination of the temperature measuring circuit with the microcontroller and the high-precision analog-to-digital converter enables high-precision temperature measurement. Furthermore, by connecting to a calibration circuit via an analog switch circuit, the temperature measuring circuit and calibration circuit can be flexibly switched flexibly, allowing for error calibration of the temperature detection circuit. This reduces hardware complexity, improves system calibration efficiency, and ultimately enhances the accuracy of temperature measurement and the stability of the temperature detection system.
[0046] In one embodiment of this application, at least two precision resistors in the calibration circuit 140 have different resistance values, and different resistance values correspond to different temperature points. Since the loop error in the temperature detection loop is basically linear, two precision resistors can be selected for error calibration. Optionally, two precision resistors are used in the calibration circuit for temperature calibration at two temperature calibration points, wherein the first temperature calibration point is below 30% of the maximum temperature measurement range, and the second temperature calibration point is above 70% of the maximum temperature measurement range.
[0047] Using two precision resistors to calibrate the low-temperature and high-temperature regions can cover a large temperature difference within the measurement range, significantly reducing the overall system error. For example, if the measurement range is -200℃ to 850℃, different precision resistors can be selected for the intervals less than or equal to 30% and greater than or equal to 70% of the measurement range to correct deviations in the temperature sensing circuit 150 and the overall temperature detection circuit, thus ensuring high consistency in temperature measurement accuracy across a wide temperature range. By selecting a low-temperature point and a high-temperature point within the measurement range and choosing precision resistors with corresponding resistance values, the temperature measurement accuracy across the entire measurement range can be ensured. This selection method effectively covers both ends of the temperature measurement range, thereby improving the accuracy of the entire measurement system.
[0048] Linear calibration using two calibration points can effectively correct measurement results at both extremely low and extremely high temperatures without significantly increasing hardware costs, thereby improving accuracy and stability in environments with a wide temperature range.
[0049] In one possible implementation, the calibration circuit 140 includes a first precision resistor R1, a second precision resistor R2, and a third precision resistor R3. If the first and third precision resistors are used for temperature calibration, the temperature corresponding to the first precision resistor should be lower than the first temperature calibration point, and the temperature corresponding to the third precision resistor should be higher than the second temperature calibration point. The additional second precision resistor is used for accuracy verification, and its temperature is higher than the first temperature calibration point but lower than the second temperature calibration point.
[0050] Using a second precision resistor to verify accuracy is beneficial for confirming whether the temperature detection error is within the allowable range after calibration.
[0051] For example, if the measurement range is 0-300 degrees, and the first, second, and third precision resistors correspond to temperatures of 15 degrees, 150 degrees, and 285 degrees respectively, then the first and third precision resistors at 15 degrees and 285 degrees are used for linear calibration, and the second precision resistor at 150 degrees is used for accuracy verification.
[0052] In practical implementation, the MCU (Microcontroller Unit) can control the analog switching circuit to switch different precision resistors into the measurement channel, calculate and save the corresponding compensation or error correction data, so that the temperature detection circuit can be fully calibrated within the measurement temperature range, thereby further improving the reliability and stability of temperature detection.
[0053] In one possible implementation, the temperature measuring circuit 150 includes a positive temperature coefficient thermistor (PTC), and further employs a four-wire platinum resistance temperature sensor (PT100), which is connected to different switches in the analog switch circuit 130 via four leads.
[0054] Furthermore, a single-pole multi-throw switch includes a common terminal and N selection terminals, namely the first selection terminal to the Nth selection terminal. The four-wire platinum resistance temperature sensor is connected to the first selection terminals of the four single-pole multi-throw switches through four leads, and the four leads are respectively connected to the excitation positive pin, excitation negative pin, detection signal positive pin and detection signal negative pin of the analog-to-digital converter through the single-pole multi-throw switch.
[0055] The excitation positive pin of the analog-to-digital converter (ADC), also known as the drive positive pin, provides a positive excitation signal to an external load or sensor. This excitation signal is typically a stable current or voltage signal, used to drive a connected single-pole multi-throw switch into operation or to provide the necessary excitation conditions for measurement. The excitation negative pin, also known as the drive negative pin, provides a return path for the excitation signal. The detection signal positive pin connects to one end of the RTD sensor, receiving the signal from the RTD. This signal is typically the positive portion of a voltage or current signal converted from temperature-related resistance changes. Correspondingly, the detection signal negative pin receives the negative portion of the signal, together with the detection signal positive pin, transmitting the complete RTD sensor signal so that the ADC can convert it into a digital signal for processing and analysis. The PT100 exhibits good linearity and high accuracy; its resistance changes with temperature, reaching 100 ohms at 0°C. Four-wire platinum resistance thermometers (such as the PTC100) effectively eliminate additional errors caused by lead resistance and connection points during temperature measurement, making them suitable for accurate temperature measurement over long distances and in environments with high interference. By utilizing the multi-channel characteristics of the analog switch circuit 130, the channels connected to each lead can be flexibly switched under the control of the MCU, thereby achieving stable and accurate resistance signal acquisition. Combined with the high-precision analog-to-digital converter 120 and calibration resistor, nonlinear errors are further corrected to maintain high precision.
[0056] Optionally, the four-wire platinum resistance temperature sensor has a maximum temperature measurement range of 850℃ and a minimum temperature measurement range of -200℃. Employing a wide-range four-wire PTC (such as PT100) can cover a measurement range from extremely low to high temperatures, maintaining good linearity and stability within this range. The four-wire structure effectively reduces additional errors introduced by the leads and enhances anti-interference capabilities, making it suitable for accurate measurements in environments with a wide temperature range.
[0057] To enable the switching between the calibration circuit 140 and the temperature measurement circuit 150, a single-pole multi-throw switch is required in the analog switch. The common terminal of the single-pole multi-throw switch is connected to the analog-to-digital converter 120, and the selection terminal is connected to the temperature measurement circuit 150 and the calibration circuit 140 respectively. Thus, when the control signal of the microcontroller 110 is received, the selection terminal connected to the common terminal is selected, thereby enabling the switching between the temperature measurement circuit 150 and the calibration circuit 140.
[0058] When using a four-wire PT100, the analog switch needs to include four single-pole multi-throw (SPMD) switches. Each of the four SPMD switches has at least one selector terminal that is connected to one of the four leads of the four-wire PT100. Specifically, the analog switch circuit 130 includes four SPMD switches. The common terminals of the different SPMD switches are respectively connected to the positive excitation pin, negative excitation pin, positive detection signal pin, and negative detection signal pin of the analog-to-digital converter 120. At least one selector terminal of each SPMD switch is connected to the calibration circuit 140, and at least one other selector terminal is connected to the temperature measurement circuit 150.
[0059] The analog switch consists of multiple channels, with the common terminal of each single-pole multi-throw switch corresponding to different pins of the analog-to-digital converter 120, enabling the calibration circuit 140 or the temperature measurement circuit 150 to transmit analog data to the ADC. Different calibration resistors can be connected to the measurement channel by connecting at least one selection terminal to a precision resistor (R1, R2, R3). Real-time temperature measurement can be performed by connecting another selection terminal to a four-wire platinum resistance temperature sensor (PTC100).
[0060] In another possible implementation, the calibration circuit 140 has three precision resistors. In order for each single-pole multi-throw switch to be connected to the three precision resistors and PT100, the analog switch includes four single-pole four-throw switches. The second selection terminal of the single-pole four-throw switch is connected to the first precision resistor, the third selection terminal is connected to the second precision resistor, the fourth selection terminal is connected to the third precision resistor, and the first selection terminal is connected to the temperature measurement circuit 150.
[0061] The calibration circuit contains three precision resistors. The positive excitation pins of the first, second, and third precision resistors are connected sequentially to the second, third, and fourth selection terminals of the first single-pole four-throw switch. The positive detection signal pins of the first, second, and third precision resistors are connected sequentially to the second, third, and fourth selection terminals of the second single-pole four-throw switch. The negative detection signal pins of the first, second, and third precision resistors are connected sequentially to the second, third, and fourth selection terminals of the third single-pole four-throw switch. The negative excitation pins of the first, second, and third precision resistors are connected sequentially to the second, third, and fourth selection terminals of the fourth single-pole four-throw switch.
[0062] Four single-pole four-throw switches allow for the selection of any one of three precision resistors or a four-wire platinum resistance temperature sensor for measurement within the same hardware platform. When the MCU issues a switching command, the analog switch circuit 130 can quickly connect the corresponding resistance value to the input terminal of the analog-to-digital converter 120, enabling flexible switching between linear calibration (first precision resistor, third precision resistor), accuracy verification (second precision resistor), and temperature measurement (four-wire PTC).
[0063] In one embodiment, the analog switch circuit 130 includes a digital decoder, one end of which is connected to the control output of the microcontroller 110, and the other end is connected to four single-pole multi-throw switches.
[0064] Specifically, when the single-pole multi-throw switch receives a control signal from the digital decoder, it switches to the selection terminal connected to the common terminal. After the microcontroller 110 sends a selection command to the digital decoder, the digital decoder can decode and drive the corresponding single-pole multi-throw switch to quickly switch to the target channel, enabling flexible access to the calibration circuit 140 and the temperature measurement circuit 150.
[0065] The digital decoder converts the digital control signals sent by the microcontroller 110 into selection signals for the analog switches, thereby controlling the switching of the analog switches. Specifically, the microcontroller 110 sends digital signals (0 or 1) to the digital decoder via the GPIO interface. The digital decoder converts these digital signals into selection signals that the analog switches can recognize. Furthermore, the digital decoder can combine multiple digital signals to generate multiple selection signals, thereby controlling the selection terminals of multiple analog switches. The output terminal of the digital decoder is connected to the selection terminal of the analog switches. By controlling the output signal, a specific selection terminal of the analog switch can be connected to the common terminal. The digital decoder enables simultaneous control of multiple analog switches, switching between different signal sources (such as calibration circuit 140 or temperature measurement circuit 150) connected to analog-to-digital converter 120 (ADC).
[0066] Setting up a digital decoder in the analog switch circuit 130 can reduce the number of GPIO pins required by the microcontroller 110, because multiple selection signals can be generated by combining fewer digital signals, and reduce wiring complexity, thereby improving the reliability and maintainability of the temperature detection circuit.
[0067] For example, the microcontroller 110 sends digital control signals through two GPIO pins (A, B). The digital decoder converts these signals into four selection signals (S0, S1, S2, S3) to control the selection terminals of four single-pole four-throw switches. The possible combinations of digital signals sent by the two GPIO pins are 00, 01, 10, 11. The corresponding controller signals are 00: select S0, 01: select S1, 10: select S2, 11: select S3.
[0068] In this embodiment, driven by the control signal of the microcontroller 110, the analog switch can quickly switch between calibration mode and temperature measurement mode, simplifying hardware wiring and reducing the use of multiple analog devices. This improves circuit integration and reliability while ensuring high-precision measurement. Furthermore, using multiple single-pole multi-throw switches saves hardware resources and significantly simplifies the circuit structure compared to traditional solutions using multiple analog switches or multi-channel ADCs, while also enhancing the system's efficiency and reliability during calibration and temperature measurement.
[0069] It should be noted that, in one embodiment of this application, the microcontroller 110, the calibration circuit 140, and the analog switch circuit 130 are respectively connected to the power supply via their power pins, and respectively connected to the reference level via their ground pins.
[0070] By providing regulated power supplies to each functional module and grounding them uniformly, noise coupling across modules can be effectively reduced, and the consistency of the circuit reference level can be ensured. During temperature measurement and calibration, the analog-to-digital converter 120, analog switches, and calibration resistors are all based on the same stable power supply and grounding reference, which helps to reduce measurement errors caused by power supply fluctuations or ground potential shifts, and further improves the accuracy and reliability of the entire temperature detection system.
[0071] This is illustrative; please refer to it. Figure 2 The diagram illustrates the structure of a temperature detection circuit according to another illustrative embodiment of this application. It includes an MCU 110 (microcontroller 110), an ADC 120 (analog-to-digital converter 120), an analog switch circuit 130, a first precision resistor 141, a second precision resistor 142, a third precision resistor 143, a fourth precision resistor 121, and a PTC 151.
[0072] The power supply pins (pin 1) of MCU110, the power supply pins (DVDD and VDD) of ADC120, and the power supply pin (VCC) of analog switch circuit 130 are connected to the power supply, which is PP3V3. The ground pins (pins 9 and 10) of MCU110, the ground pins (GND2 and EPAD) of ADC120, and the enable pins (1OE and 2OE) and ground pin (GND) of analog switch circuit 130 are connected to the reference level D GND.
[0073] The analog switch circuit 130 includes a first single-pole four-throw switch 131, a second single-pole four-throw switch 132, a third single-pole four-throw switch 133, and a fourth single-pole four-throw switch 134, and also includes a digital decoder 135. The excitation positive pin (Force+ pin), excitation negative pin (Force- pin), detection signal positive pin (Sense+ pin), and detection signal negative pin (Sense- pin) of the PTC151 are respectively connected to the first selection terminal B1 of the different single-pole four-throw switches. The four leads (Force+, Force-, Sense+, Sense-) of the first precision resistor 141, the second precision resistor 142, and the third precision resistor 143 are respectively connected to the second selection terminal B2, the third selection terminal B3, and the fourth selection terminal B4 of the different single-pole four-throw switches. Specifically, the excitation positive pins (Force+ pins) of the first precision resistor 141, the second precision resistor 142, and the third precision resistor 143, and the excitation positive pin (Force+ pin) of the PTC151 are sequentially connected to terminals B1, B2, B3, and B4 of the first single-pole four-throw switch 131; the detection signal positive pins (Sense+ pins) of the first precision resistor 141, the second precision resistor 142, and the third precision resistor 143, and the detection signal positive pin (Sense+ pin) of the PTC151 are sequentially connected to terminals B1, B2, B3, and B4 of the second single-pole four-throw switch 132. The detection signal negative pins (Sense pins) of the first precision resistor 141, the second precision resistor 142, and the third precision resistor 143, and the detection signal negative pin (Sense pin) of the PTC151 are connected sequentially to the B1, B2, B3, and B4 terminals of the third single-pole four-throw switch 133; the excitation negative pins (Force pins) of the first precision resistor 141, the second precision resistor 142, and the third precision resistor 143, and the excitation negative pin (Force pin) of the PTC151 are connected sequentially to the B1, B2, B3, and B4 terminals of the fourth single-pole four-throw switch 134.
[0074] In the temperature detection stage, MCU110 sends a control signal to digital decoder 135 through control terminals (pins 9 and 10, pins S0 and S1 in analog switch circuit 130 are connected to it). After receiving the control signal, digital decoder 135 converts the digital signal into an analog signal, thereby controlling the fourth selection terminal B4 of the single-pole four-throw switch to connect to the common terminal, so that PTC151 is connected to the circuit to realize temperature detection. ADC120 converts analog data into digital data and sends it to MCU110 for processing.
[0075] During linear calibration or accuracy verification, the MCU110 sends a control signal to the digital decoder 135 via its control terminal. Upon receiving the control signal, the digital decoder 135 converts the digital signal into an analog signal, thereby controlling the single-pole four-throw switch to connect the first precision resistor 141 and the third precision resistor 143 to the temperature detection circuit. By fitting the calibration curve based on the deviation between the set value and the measured value, linear calibration is achieved. After calibration, based on the control signal from the MCU110, the second precision resistor 142 is then connected to the temperature detection circuit to achieve accuracy verification.
[0076] In addition, a fourth precision resistor 121 is connected between the BIAS and ISENSOR pins of the ADC120, and also between the REFIN+ and REFIN- pins. The ADC120 is connected to the MCU110 via four SPI pins (SDI, CS, SCLK, and SDO) and the DRDY signal pin. Furthermore, the ADC120 is connected to the first single-pole four-throw switch 131 via the positive excitation pin (FORCE+), to the second single-pole four-throw switch 132 via the negative excitation pin (FORCE-), to the third single-pole four-throw switch 133 via the positive detection signal pin (PTDIN+), and to the fourth single-pole four-throw switch 134 via the negative detection signal pin (PTDIN-).
[0077] In one embodiment of this utility model, a temperature detection device is provided, which includes the temperature detection circuit in any of the above-described technical solutions.
[0078] This temperature detection device can integrate the aforementioned temperature detection circuit into industrial, medical, or consumer electronics products. Through a microcontroller, a high-precision analog-to-digital converter, a four-wire temperature sensor, and a switchable calibration circuit, it can achieve accurate measurement and on-site or remote calibration of a wide range of temperatures. Due to the combination design of four-wire platinum resistance, precision resistors, and analog switches, it can effectively eliminate additional errors caused by wires and interfaces, ensuring stable and reliable operation in long-distance or high-interference environments.
[0079] Furthermore, by simplifying hardware wiring and implementing automatic calibration switching, the temperature detection device significantly shortens the temperature measurement deployment cycle, while providing high-precision and wide-range temperature detection capabilities in various application scenarios. Those skilled in the art will readily understand that, for the sake of convenience and brevity, the device described above and its specific operating process can be referred to the corresponding processes in the aforementioned circuit implementation, and will not be repeated here.
[0080] It should be understood that although this specification describes embodiments, not every embodiment contains only one independent technical solution. This way of describing the specification is only for clarity. Those skilled in the art should regard the specification as a whole. The technical solutions in each embodiment can also be appropriately combined to form other embodiments that can be understood by those skilled in the art.
[0081] The detailed descriptions listed above are merely specific descriptions of feasible implementation methods of this application and are not intended to limit the scope of protection of this application. All equivalent implementation methods or modifications made without departing from the spirit of the art of this application should be included within the scope of protection of this application.
Claims
1. A temperature detection circuit, characterized in that, include: The microcontroller is connected to the analog-to-digital converter via its serial peripheral interface and to the analog switching circuit via its control output. The calibration circuit includes at least two precision resistors, which are connected to the analog-to-digital converter via the analog switching circuit. The temperature measuring circuit is connected to the analog-to-digital converter via the analog switching circuit; The analog switch circuit is used to connect to the temperature measuring circuit or the calibration circuit, and switches the connection when it receives a control signal sent by the control output terminal.
2. The temperature detection circuit according to claim 1, characterized in that, In the calibration circuit, at least two precision resistors have different resistance values, and different resistance values correspond to different temperature points; Specifically, two precision resistors are used for temperature calibration at two temperature calibration points, wherein the first temperature calibration point is below 30% of the maximum temperature measurement range, and the second temperature calibration point is above 70% of the maximum temperature measurement range.
3. The temperature detection circuit according to claim 2, characterized in that, The calibration circuit includes a first precision resistor, a second precision resistor, and a third precision resistor; The first precision resistor and the third precision resistor are used for temperature calibration. The temperature corresponding to the first precision resistor is lower than the first temperature calibration point, and the temperature corresponding to the third precision resistor is higher than the second temperature calibration point. The second precision resistor is used for accuracy verification. The temperature of the second precision resistor is higher than the first temperature calibration point and lower than the second temperature calibration point.
4. The temperature detection circuit according to claim 3, characterized in that, The analog switching circuit includes four single-pole multi-throw switches, and the common terminal of each single-pole multi-throw switch is connected to the excitation positive pin, excitation negative pin, detection signal positive pin, and detection signal negative pin of the analog-to-digital converter, respectively. At least one selector terminal of the single-pole multi-throw switch is connected to the calibration circuit, and at least one other selector terminal is connected to the temperature measurement circuit.
5. The temperature detection circuit according to claim 4, characterized in that, The temperature measurement circuit includes a four-wire platinum resistance temperature sensor. The four-wire platinum resistance temperature sensor is connected to the first selection terminals of four single-pole multi-throw switches via four leads, and is connected to the excitation positive pin, the excitation negative pin, the detection signal positive pin, and the detection signal negative pin of the analog-to-digital converter via the single-pole multi-throw switches.
6. The temperature detection circuit according to claim 5, characterized in that, The calibration circuit has three precision resistors. The excitation positive pins of the first precision resistor, the second precision resistor, and the third precision resistor are connected in sequence to the second selection terminal, the third selection terminal, and the fourth selection terminal of the first single-pole four-throw switch. The positive pins of the detection signals of the first precision resistor, the second precision resistor, and the third precision resistor are sequentially connected to the second selection terminal, the third selection terminal, and the fourth selection terminal of the second single-pole four-throw switch; The detection signal negative pins of the first precision resistor, the second precision resistor, and the third precision resistor are sequentially connected to the second selection terminal, the third selection terminal, and the fourth selection terminal of the third single-pole four-throw switch; The excitation negative pins of the first precision resistor, the second precision resistor, and the third precision resistor are sequentially connected to the second selection terminal, the third selection terminal, and the fourth selection terminal of the fourth single-pole four-throw switch.
7. The temperature detection circuit according to claim 5, characterized in that, The analog switch circuit includes a digital decoder, one end of which is connected to the control output terminal of the microcontroller, and the other end is connected to four single-pole multi-throw switches respectively. Specifically, when the single-pole multi-throw switch receives the control signal sent by the digital decoder, it switches the selection terminal connected to the common terminal.
8. The temperature detection circuit according to claim 1, characterized in that, Also includes: A gain resistor, with one end connected to the bias pin of the analog-to-digital converter and the other end connected to the current sensing pin of the analog-to-digital converter.
9. The temperature detection circuit according to claim 1, characterized in that, The microcontroller, the calibration circuit, and the analog switch are each connected to the power supply via their power pins and to the reference level via their ground pins.
10. A temperature detection device, characterized in that, Includes the temperature detection circuit as described in any one of claims 1-9.