Full text

1. Introduction

Many places in life are necessary to detect temperature. Most of the factory workshop, production volume, single point temperature measurement instrument have been unable to meet the demand of the factory. The manufacturers need to multi-channel temperature measurement system model to improve the economic efficiency of the factory. But the temperature sensing system is now widely used. Mostly of it can only achieve cable temperature measurement the temperature measuring points, far away from the wiring trouble. So in some special situations, the wireless temperature requirements are also increasing. Considering the temperature measurement system can achieve multi-point temperature measurement cable, can realize the wireless temperature measurement requirements, the main control device of the system using STC89C52 microcontroller, measurement selection the temperature of the DS18B20. DS18B20 can be used to achieve the characteristics of single bus multi-point temperature effect, also can through the nRF905 to achieve a wireless temperature. The temperature measurement system to detect multi-point temperature. It breaks the singleness of temperature monitoring point, and also can realize wireless temperature measurement.

2. Overall design of system

This system chooses STC89C52 as the main control device, collected by DS18B20 at different temperature, through the a/d conversion, the data through the i/o port to the CPU, the CPU sends a command to the data displayed by the 12864 LCD screen. The system in the way of DS18B20 wireless transmission function by nRF905 to realize the data. In addition, two keys the design of the user according to the actual need to set the alarm temperature. When the temperature STC89C52 detected on the LCD screen is higher than the set temperature, we call the procedure to enter the alarm circuit (Figure 1).

Figure 1. Overall system design.

temperature sensor

CPU Testpoint push-button display circuit warning circuit a 5V Wireless Module

Figure 2. Wiring diagram between DS18B20 and 89C52.

3. Hardware design

3.1. Selection of temperature sensor

DS18B20 on the measurement accuracy of temperature is very high, can reach 9. The data can be measured at the temperature of -55 to 125 DEG C, the power supply for external power supply or parasitic power supply[1]. Its internal as well as the upper and lower temperature alarm settings, the user can according to the actual need to set the alarm temperature. DS18B20 can theoretically connect to STC89C52 any one of the i/o port on the system STC89C52 microcontroller P25 port connected to the local acquisition of two DS18B20, two local DS18B20 is connected by bus, a common i/o port.Stc89c52 port P20 is connected to the wireless acquisition way DS18B20.An DS18B20 need to connect the 4.7K pullup resistor (see Figure 2).

3.2. Design of display and key circuit

The display comes with Chinese font fm12864, powerful, a 27c020 application of strong.Fm12864 liquid crystal in completely including the 16*16 library and the 8*8 Chinese characters dot matrix character library[2]. This makes the character and Chinese characters display operation easier. Users need to display some of the images, letters or Chinese characters, can write LCD control procedures corresponding in position 12864 lit display, can display the results you want. The liquid crystal by the external 5V power supply (Figure 3).

Figure 3. Fm12864 pin diagram.

The design of key circuit for S2 by S1, the two buttons to set the alarm temperature value, the user can according to the actual needs of the situation to set the temperature value of DS18B20. When the measured temperature higher than the set value, the alarm circuit is started. When the single-chip P31 port into a "1", according to S1. Set the value to 1. P32 when I write "press S2 1", and the set value -1.

3.3. A better alarm circuit for

The alarm circuit selects a buzzer alarm function, use the PNP type triode buzzer buzzer 8550 to increase. The alarm circuit and STC89C52 P13 port connected by a base resistor connection 8550, resistance to play a limiting role, the buzzer is connected with one end of the 8550 emitter, the remaining end is connected to the collector of8550 5V power supply ground (Figure 4).

When STC89C52 P13 I write "0", the 8550 will be conducted, the buzzer will sound. When writing "on the P13 port 1, 8550 as the cut-off state, the buzzer will sound. The three LED lights to show the number of STC89C52 over temperature of P10, P11 and p12 even if the first DS18B20 road lights. The measured temperature is higher than the set value, the MCU P10 port will be pulled low. The P10 port LED lights will be lit, at the same time, the buzzer alarm (Figure 5).

Figure 4. Alarm circuit diagram.

Figure 5. Three way indicator circuit.

3.4. NRF905 wireless transceiver module

NRF905 is a wireless module of the Norway company, the transceiver mode switching time <650us, the voltage

is 1.9 ~ 3.6V environment to run, run the ISM band for 433/868/915mhz.nrf905 has very low power consumption, when the output power in fire condition is -10dbm, only the current 11ma, even in the receiving state the size of the current, required only for very low power 12.5ma in powerdown mode (Figure 6).

Figure 6. Pin diagram of nRF905 module.

4. The software design and test

4.1. Software design

The overall functions are realized in the call of the main program, the program written in the forebrain to the program flow chart of the whole. The first to enter the main program, the initialization of the system operation. The initialization operation including 12864 LCD and initialization of nRF905. At the same time to allocate storage resources, achieve better programming and call.

The design of the temperature acquisition can realize local multi-point acquisition, also can realize the wireless acquisition way. Wireless temperature acquisition temperature is sent by wireless module after induction and sends the data to the wireless receiving module, the temperature value is displayed in the 12864. At the same time, the local value of the measured temperature value and temperature alarm button in 12864 will display on the DS18B20. If the induction temperature exceeds the set value, the alarm will start the program at the same time the buzzer will alarm (Figure 7).

Figure 7. Overview flow chart.

4.2. System testing

At the completion of the real welding, the C language programming to debug. After completing the program, the first in the development board debugging, the debugging result shows a successful local temperature DS18B20 and a wireless temperature data. Because the development board is only one DS18B20 interface so, the local collection only shows a way. When the measured temperature is three DS18B20 does not exceed the set temperature, the alarm indicator light does not shine, the buzzer sound. If the local second DS18B20 the measured temperature exceeds the set temperature is Beyond the set temperature? begin system initialization Button setting temperature temperature sampling Local collection Wireless acquisition Wireless module sends data Receive data by wireless module display N Start alarm end Y

second indicating lamp lights, buzzer alarm. Third is DS18B20 wireless acquisition of temperature in the nRF905 module, if the temperature is over third road third road lamp lights, buzzer alarm. In the wireless acquisition temperature is 28 DEG C, the set value of 26 degrees (Figure 8).

Figure 8. Display of third channels wireless acquisition temperature over temperature.

5. Summary

The design of multi-channel temperature detection system, can be easily applied to the factory, workshop in various fields. The bus hanging multiple DS18B20 tomeasure the temperature, not only saves the use of i/o port, and the temperature acquisition wiring simple.

Especially using nRF905 to realize remote wireless temperature measurement, according to the different the occasion.

Figures

Article figure
Article figure
Article figure
Article figure
Article figure
Article figure