“Aiming at the shortcomings of using thermistor temperature measurement and wired temperature measurement system, an intelligent wireless temperature monitoring system composed of single-bus digital temperature sensor DS18B20, single-chip microcomputer and wireless transceiver module is proposed. DS18B20 has the advantages of small size, high precision, using one-line bus, and can be networked. The short-distance wireless communication technology is applied to multi-point temperature measurement to realize wireless transmission of temperature data. The system is easy to expand and maintain, low cost, and high reliability. Features such as sex, have certain practicality.
“
Abstract: Aiming at the shortcomings of using thermistor to measure temperature and wired temperature measurement system, an intelligent wireless temperature monitoring system composed of single-bus digital temperature sensor DS18B20, single-chip microcomputer and wireless transceiver module is proposed. DS18B20 has the advantages of small size, high precision, using one-line bus, and can be networked. The short-distance wireless communication technology is applied to multi-point temperature measurement to realize wireless transmission of temperature data. The system is easy to expand and maintain, low cost, and high reliability. Features such as sex, have certain practicality.
As a convenient, safe and reliable DC power supply, batteries have been widely used in electric power, communications, military and other fields. Temperature is an important parameter of the battery, it can indirectly reflect the performance of the battery, and according to this temperature parameter, the battery can be managed intelligently to prolong the life of the battery. During the charging and discharging maintenance and work engineering of the battery pack, the heat generated inside the battery will cause the temperature of the battery to change. In particular, the overcharge of the battery and abnormal changes in the electrolyte inside the battery may cause the battery temperature to be too high and cause battery damage. .
The traditional method of manual timing measurement is labor-intensive, poor in measurement accuracy, and bad working environment, especially if abnormal single cells cannot be found in time, it is easy to cause damage to the single cells, and even lead to failure or damage of the entire battery group; based on the bus structure The wired multi-point temperature monitoring system can realize intelligent temperature measurement, but there are many shortcomings such as complicated wiring and difficult maintenance and expansion. In view of this, a battery temperature wireless monitoring system based on a single bus temperature sensor and a wireless transceiver module is designed, which can effectively overcome the shortcomings of the thermistor temperature measurement and bus structure control system, and is conducive to improving the intelligent level of battery performance monitoring. .
1 Single bus temperature sensor DS18B20
1.1 DS18B20 Chip Features
DS18B20 digital temperature sensor is a new generation of adaptive intelligent temperature sensor produced by DALLAS semiconductor, USA. It integrates temperature sensor, A/D converter, register and interface circuit in one chip, adopts 1-wire bus protocol, can directly Digital output, testing. Compared with other temperature sensors, it has the following main characteristics:
The unique single-wire interface technology is used to connect with the microprocessor to realize bidirectional communication with only one port line, which occupies less ports of the microprocessor and can receive a large number of leads and logic circuits; no peripheral circuits are required in use, all The sensing element and the conversion circuit are integrated in the shape of a triode; the temperature measurement range is – 55 ~ 125 ℃, the temperature can reach ?0. 5 ℃, the programmable 9~12 bit A/D conversion temperature, The resolution can reach 0.0625℃, which can realize high temperature temperature measurement; the measurement result can directly output digital temperature signal, and can transmit CRC check code at the same time, which has strong anti-interference and error correction ability; supports multi-point networking function , multiple DS18B20 can be hung on the bus to realize multi-point temperature measurement in networking. Wide applicable voltage range: 3.0~5.5 V, which can be powered by data line in parasitic power supply mode; the connection between DS18B20 and single-chip microcomputer is shown in Figure 1, the single-bus device has only one data line, the data exchange and control in the system All are done on this line, and a 4.7Ω pull-up resistor is externally connected to the single bus to ensure that the state is high when the bus is idle.
Figure 1 Hardware connection diagram of DS18B20 and microcontroller
1.2 Control sequence of DS18B20
Serial data transmission is used between DS18B20 and the microprocessor. When reading and writing programming, the read and write timing must be strictly guaranteed, otherwise the temperature measurement result will not be read. The DS18B20 control sequence mainly includes initialization sequence, read operation sequence and write operation sequence, as shown in Figure 2.
Figure 2 DS18B20 control sequence
(1) Initialization timing. The timing is shown in Figure 2 (a), the host bus sends a reset pulse at time t0 (a very short low level signal of 480 s), then releases the bus at time t1 and enters the receiving state, DS18B20 waits after detecting the rising edge of the bus 15 ~ 60 μs, then DS18B20 sends out a presence pulse at time t2 (the low level lasts for 60 ~ 240 s), as shown by the dotted line in the figure.
(2) Write operation timing. When the host bus is pulled from high to low at time t 0 , a write time gap occurs. The bit to be written should be sent to the bus within 15μs from the time of t0. DS18B20 samples the bus between 15 and 60μs after t0. If the bit written at low level is 0, if the bit written at high level is 0 If it is 1, the gap between consecutively writing 2 bits should be greater than 1μs, see Figure 2(b).
(3) Read operation timing. When the host bus is pulled from high to low at time t0, the bus only needs to keep the low level for 6~10 μs, and then pull the bus high at time t1 to generate a read time gap. The read time gap is after time t1 and before time t2 Effective, t2~t0 is 15μs, that is to say, the host must complete the read bit before t2, and release the bus within 60~120μs after t0, see Figure 2(c).
2 System hardware structure
The monitoring system is mainly composed of three parts: temperature monitoring node, main control unit and host computer. The system structure is shown in Figure 3. The temperature monitoring nodes are distributed on each single cell of the battery pack, collect the temperature information of each single cell, and transmit it to the main control unit through the wireless network; the main control unit communicates with all monitoring nodes, and receives commands from the host computer and from monitoring. The temperature information of the node is reported to the host computer; the host computer displays the temperature information of the battery in real time, analyzes and processes the data, and starts the alarm program according to the set alarm threshold to detect abnormal batteries in time.
Figure 3 Overall structure of the system
2.1 Design of temperature monitoring nodes
The function of the temperature monitoring node is to complete the collection, processing and wireless data transmission of the temperature information of the single battery. Using single-chip microcomputer to control wireless transceiver chip nRF2401 and single-bus digital temperature sensor DS18B20 to realize intelligent temperature measurement, it mainly includes single-chip microcomputer system, temperature acquisition circuit, wireless transceiver circuit, Display circuit, alarm circuit and power supply, etc. Its hardware structure is shown in Figure 4 shown.
Figure 4 Hardware structure of temperature monitoring node
The DS18B20 temperature measurement circuit is shown in Figure 1. When the DS18B20 is adhered to the battery with thermally conductive adhesive, the difference between the die temperature and the surface temperature is about 0.2 °C. Use nRf2401 wireless transceiver chip to achieve wireless transmission, nRF2401 is a single-chip integrated receiver, transmitter chip, the operating frequency range is the world’s open 2. 4 GHz frequency band. It has built-in FIFO stack area, address decoder, demodulation processor, GFSK filter, clock processor, frequency synthesizer, low noise amplifier, power amplifier and other functional modules. It requires few peripheral components and is very easy to use. Convenience. In this system, the nRf2401 communicates with the microcontroller through the P2 port, and the P2. 0 and P2. 1 ports of the AT89S51 are respectively connected with the CLK1 and DA TA of the nRF2401. The CS of nRf2401 is the chip selection terminal, CE is the sending or receiving control terminal, PWR_UP is the power control terminal, which are controlled by the P2.3, P2.4 and P2.5 pins of the microcontroller respectively. When DR1 of nRF2401 is high, it indicates that there is data in the receive buffer, connect to P2.2 of the microcontroller.
Since the power supply voltage range of nRF2401 is 1. 9~3. 6 V, and the power supply voltage of AT89S51 microcontroller is 5 V, in order to make the chip work normally, it needs to perform level conversion and voltage division processing. 5 V to 3. 3 V level translation as shown in Figure 5.
Figure 5 5 V to 3. 3 V conversion circuit
2.2 Design of the main control unit
The main control unit and the monitoring nodes form a wireless network, and the data communication between the host computer and the monitoring unit is realized through the main control unit. The basic structure of the main control unit is similar to that of the monitoring unit, which is mainly composed of a single-chip microcomputer system, a wireless transceiver module, a Display circuit, a serial communication circuit and a power supply.
The serial port is a very common protocol for device communication on the computer. Most computers contain two serial ports based on RS 232. The serial port of the PC is RS 232C level, and the serial port of the microcontroller is TTL level. When communicating through serial ports, level conversion must be carried out. The MAX232A chip is designed to complete the data transmission between the single-chip microcomputer and the PC. The hardware connection circuit is shown in Figure 6.
Figure 6 The hardware connection circuit between the microcontroller and the MAX232A
3 Control program design
The system control program is mainly composed of a single bus temperature measurement control program, a wireless transceiver control program, and a host computer monitoring program. The single bus temperature measurement program is responsible for the initialization of the single bus device, collects the battery temperature and transmits it to the nRF2401 module; the main function of the wireless transceiver control program is to be responsible for the formation of the wireless network and the wireless transmission of data information; the main function of the host computer monitoring program is to communicate through the serial port and The main control unit conducts data communication, displays and stores data information in real time. Taking the monitoring node as an example, Figure 7 is the program flow chart of the monitoring unit. The monitoring unit is initialized first, mainly including the communication, interruption and timing initialization of the single-chip system, and then the temperature information of the single battery is collected, saved and displayed with a digital tube. , monitor the data transmission command of the main control unit in real time, and send the temperature data of the battery through the wireless module if there is any.
Figure 7 Monitoring node program flow
4 Test results
The test prototype is designed, and the actual test circuit of the monitoring node is shown in Figure 8. The temperature test is carried out in the room, and four monitoring nodes are used to conduct the test at a distance of 4 m, 8 m and 12 m from the main control unit respectively. The data are shown in Table 1.
It can be seen from Table 1 that the temperature measurement degree can reach ? 0.3 ℃, and the accuracy of wireless transmission is high, which can meet the needs of wireless temperature monitoring.
Figure 8 Monitoring node test circuit
Table 1 Temperature measurement test data
5 Conclusion
Aiming at the temperature monitoring problem of single cells in the battery pack, this paper designs a remote wireless monitoring system based on DS18B20 digital temperature sensor and wireless transceiver chip. The system consists of a host computer, a main control unit and multiple monitoring single nodes. The main control unit communicates with the host computer through a serial port. Compared with the traditional wired multi-point temperature measurement system, it has the characteristics of convenient layout, expansion, maintenance and update, and has certain engineering practical application value.
The Links: SKM300GAL12E4 QM50TX-HB