This paper develops a wireless temperature measurement system. The system uses K-type thermocouples as temperature sensing elements, with a wide temperature measurement range, and is suitable for high-temperature fields such as wave soldering and reflow soldering. In addition, the system has an independent temperature compensation circuit, which solves the problem of slow temperature acquisition speed of some integrated temperature compensation chips and improves the sensitivity of temperature measurement. Since the system is wirelessly transceived and uses CCl000 as a wireless communication chip, the host computer can receive data and monitor in real time at a certain distance. In addition, the system also has the function of real-time data recording, and can save the data when there is an obstacle in wireless communication, and then read it out by the host computer software after the temperature acquisition is completed.
1 System Hardware Design
This system uses the SOC chip C8051F020 as the main control chip. This single-chip microcomputer uses a 25MIPS 8051 CPU pipeline instruction structure, with 64 KB Flash program memory on the chip, 256 KB+4 KB on-chip RAM and two external RAM expansion interfaces, 5 16-bit timers and JTAG non-intrusive in-system debugging. As a system on a chip, C8051F020 has rich and powerful peripherals. Its AD converter has 12 bits, which can effectively improve the input acquisition accuracy of thermocouples. Welcome to reprint, this article comes from Electronics Fans Network ( http://www.elecfans.com )
In addition, the purpose of using Atmegal6 is to improve the acquisition speed of the system, thereby improving the sensitivity of temperature measurement. Short-distance wireless communication is completed through CCl000. The FLASH chip can store temperature data for reading when wireless communication fails. After conversion by CP2102, C8051F020 can communicate with the host computer through the USB port. The hardware structure block diagram of this system is shown in Figure 1.
1.1 System control module centered on C8051F020
This module includes C805lF020 control module, FLASH storage module, and CP2102 communication module. When the system is in the sending state, C805lF020 is used to collect the input analog signal of the thermocouple, and convert the collected signal into a digital signal through a 12-bit AD converter. Then C805lF020 looks up the data in a table, converts it into temperature data, processes and packages the data. Finally, the data is written into the FLASH chip and sent to Atmegal6 through the serial port.
When the system is in the waiting state, it will communicate with the host computer through the IJSB interface. CP2102 can complete the conversion between the serial port and the USB interface. If the system receives a command from the host computer to read data, C805lF020 will read the data from the FLASH chip, then send it out through the serial port, and then enter the host computer through the USB interface through CP2102.
1.2 Wireless transmission module centered on CCl000
The wireless transmission module includes CCl000, Atmegal6 and antenna. CCl000 is an ideal ultra-high frequency single-chip transceiver communication chip manufactured under 0.35μm CMOS process based on Chipcon's SmartRF technology. The operating frequency band of CCl000 is 315, 433, 868 and 915 MHz. And it is easy to program it to work in the range of 300~1000 MHz. AVR microcontroller Atmegal6 can be used to complete the initialization of CCl000 and communicate with CCl000, and also maintain communication with the main control chip C805lF020. When the system is in the sending state, Atmegal6 receives the data packet sent by C8051F020 and sends it out through CC1000.
1.3 Temperature acquisition module based on thermocouple
This module includes a voltage temperature sensor TMP35 and a K-type thermocouple. The working principle of the thermocouple is to generate a potential difference based on the temperature difference between the hot end and the cold end. Since the temperature of the cold end is often not 0°C during actual measurement, the thermocouple must be temperature compensated. The thermocouple temperature compensation formula is as follows:
E(t, 0) = E(t, t0) + E(t0, 0)
Among them, E(t0,0) is the actual measured electromotive force, t represents the hot end temperature, t0 represents the cold end temperature, and 0 represents 0°C. In the field temperature measurement, since the cold end temperature of the thermocouple is generally not 0°C, but varies within a certain range, the measured thermoelectric potential is E(t, t0). If you want to measure the thermoelectric potential E(t, 0) corresponding to the actual measured temperature, you must compensate for the compensation potential E(t0, 0) required for the cold end not being 0°C. Moreover, the characteristics of the compensation potential changing with the cold end temperature must be consistent with the thermoelectric characteristics of the thermocouple, so as to obtain the best compensation effect.
Figure 2 shows a schematic diagram of a temperature compensation circuit. In the figure, the temperature sensor TMP35 performs the temperature compensation work very well. The voltage output by TMP35 is first divided by resistors and then amplified by an amplifier, which is E(t0, O) corresponding to the K-type thermocouple.
2 System Software Design
The software design of the transmitter board mainly includes the main control module program based on C8051F020 and the wireless transmitter module program centered on Atmegal6. The main control program module mainly completes temperature acquisition, data processing, sending data to the wireless transmitter module, saving test temperature data, and communicating with the host computer. The wireless transmitter program module is mainly responsible for initializing CC1000, receiving data packets from C805lF020 in the waiting state, and sending them through CC1000.
2.1 Main control module program design
The main function of the main control module program is to sample the input analog signal of the thermocouple, and then look up the table to convert the table data into temperature data and package it. When the sending flag is allowed, it is written into FLASH for storage and sent to Atmegal6 through the serial port. The system software module flow chart is shown in Figure 3.
After power-on reset, the system should first initialize the functional modules of C8051F020, including serial port 0, serial port 1, AD converter, counters TO, T1, T2 and interrupt program. The system samples the input signal once every 50 ms through a 12-bit AD converter, and converts the sampled signal into temperature data by looking up the table. Then add the frame header, frame footer and check bit to the data. Finally, several frames of data are packed into a data packet.
When the send flag is enabled, C805lF020 writes the data packet into the FLASH chip AT45DB041D every 50 ms and sends the data packet to Atmegal6 through the serial port.
2.2 Wireless Transmitter Module Program Design
The main function of the wireless transmission program is to initialize CCl000 through Atmegal6, receive data from C805lF020, and send it out by CCl000. The flow of the wireless transmission program is shown in Figure 3 (b).
When designing the program of the wireless transmitter module, the port initialization, TO and T1 initialization, serial port initialization and interrupt program should be completed through Atmegal6 first, and CC1000 initialization programming should be performed. Then, Atmegal6 enters the loop waiting. When it is confirmed that the data is received, it is confirmed that the data is valid, and then CC1000 is woken up and the data packet is sent out.
3 System Performance Analysis
The characteristic of this temperature measurement system is that it uses dual CPUs and independent temperature compensation circuits, which effectively improves the speed of temperature acquisition and thus improves the sensitivity of measuring temperature changes. Actual tests show that the measurement accuracy of this system is 0.5% and the temperature acquisition speed is 50 ms.
The independent temperature compensation circuit used in this system uses the voltage temperature sensor TMP35 as the temperature compensation element. After the input electromotive force of the thermocouple is temperature compensated, it is further amplified by the precision rail-to-rail operational amplifier OP747 and then input to the AD converter of C8051F020. This can avoid the speed limitation problem caused by the use of some integrated thermocouple temperature compensation chips.
This system uses C8051F020 as a new generation of SOC chip, which has rich and powerful peripherals. It has 2 AD converters, of which ADO has 12-bit accuracy, so it can effectively ensure the accurate collection of temperature signals.
The dual CPU structure C805lF020 and Atmega16 can ensure the system acquisition time of 50 ms. Because wireless transmission and FLASH writing often take up most of the time, the dual CPU can separate the two, which effectively ensures the speed and stability of the system.
The FLASH chip AT45DB041D can write data into FLASH in real time during temperature acquisition, so that data can be effectively saved when wireless transmission is blocked. The data saved by the test system can be read by the host computer through the USB interface.
4 Conclusion
Compared with the current mainstream wireless temperature measurement systems at home and abroad, this system has achieved a higher level of temperature measurement accuracy. In terms of temperature acquisition speed, due to the use of an independent temperature compensation circuit and a dual CPU system structure, the sensitivity of temperature measurement and system stability are effectively improved. In addition, due to the use of FLASH chips, real-time data can be saved, which also improves the reliability and practicality of the system.
Previous article:LED digital tube display circuit based on AT89C2051 serial port
Next article:The principle of XXTEA encryption algorithm and its implementation in C language
Recommended ReadingLatest update time:2024-11-16 22:29
- Popular Resources
- Popular amplifiers
- Mechatronic system design
- Practice of Serial Communication between Single Chip Microcomputer and Computer (Zhang Xiuguan)
- Design of SD card main controller based on c8051f020
- C8051F020 implements ADC sampling of analog voltage outside the chip, displays it on the LCD, and sends it to the PC through the serial port
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- How to make a simple calculator using STM8L151K4
- [Evaluation of the popular N32G45XVL model of the National Technology M4 core] Part 6 Preparation for motor application development
- AR1021X uses hostapd to configure AP hotspots.
- Design method of adding soft start to DCDC chip
- The stm32 board runs normally online, but does not function normally when it is powered on again
- Four points of detailed description of field effect tube application
- High-frequency equivalent circuits and characteristic curves of resistors, capacitors and inductors
- The tree topology network structure of ZigBee module communication protocol
- EEWORLD University Hall----Switching power supply design technology and application examples
- Altium Designer 19 DRC check, it is clearly connected but it still shows Un-Routed Net, and NetAntennae via