Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

In this paper, the embedded control technology and network control technology are combined to realize the design of the temperature control system based on the control of the single-chip computer through the Internet. The MSP430F1 49 single-chip microcomputer is used as the control core, and the MSP430F149 microcontroller controls the Ethernet controller CS8900A. Realize the function of the local area network, provide connection with the Internet through the TCP protocol, and realize real-time and effective control of the temperature of the incubator. The system is small in size, with temperature acquisition and remote control and good scalability.

Network Control Systems (NCSs) have become one of the major research centers in the academic and industrial fields. With the increasing research trends and research needs, it is particularly important to be able to successfully apply the latest knowledge and information. With the needs of social development, people have more and more applications and needs for thermostats. In industrial production and daily life or scientific experiments, we can see the application of thermostats everywhere. This paper combines embedded technology and network control technology to realize the design of embedded thermostat control system based on network control system. The network control system exchanges information (standard input and output, control input, etc.) using a shared network by controlling system components (sensors, controllers, actuators, etc.). The temperature information collected by the embedded system is sent to the networked control and coordination system and the network monitoring system through the TCP protocol, and the behavior of the single chip microcomputer is controlled and coordinated after calculation and judgment. The networked detection system releases the control signal to the single-chip microcomputer through Ethernet to realize the temperature control of the temperature box. The system can be applied to fields such as remote operation and control.

1 System working principle

Based on the design idea of ​​network control system, the remote oven control system is developed. The whole system adopts B/S structure, namely Browser/Server, browser/server structure, which only installs and maintains one server (Server), while the client uses browsing. (Browse) runs the software. The system is mainly composed of a client module, an Internet Internet module, a single chip controller and a controlled object module. The client located on the client uses the browser to access the MCU controller and the controlled object module. After successfully logging in the browser, the data is automatically encapsulated into TCP or UDP through the HTTP protocol and then transmitted on the network, and then all the slaves are connected through the network interface CS8900A. The information transmitted by the client is automatically unpacked and transmitted to the single-chip controller and the controlled object temperature box module for temperature control, and the temperature condition of the same temperature box can also be transmitted to the client module, thereby realizing the client and the single chip microcomputer. Communication between the Internet and the Internet module is the core of the entire control system, enabling the information exchange between the remote client and the thermostat. The one-chip computer mainly receives the command of the remote client, completes the control of the temperature box, and feeds back the temperature information of the temperature box to the remote client.

2 system hardware design

The main chip of this temperature control system is the MCU MSP430F149 chip MCU. The main components are: digital-to-analog converter DAC5571, platinum resistance chip, compressor, heating wire, Ethernet controller CS8900A network interface chip RTL8019AS and so on.

The hardware system MSP430F149 is the control center of the system. It monitors the startup and operation of each functional module, as shown in the temperature measurement part, controls the data transmission, and realizes the Ethernet communication with the PC through the connection with the network interface chip RTL8019AS.

The system is mainly composed of remote control terminal, Internet, CS8900A, MSP430F149 microcontroller. The user at the remote control terminal controls the field device through the communication between the CS8900A Ethernet controller and the single-chip computer through the standard IE browser connected to the INTERNER on the client to achieve temperature control. The system architecture is shown in Figure 1:

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer


2.1 Power circuit design This system needs to use +5 V and +3.3 V DC regulated power supply, of which MSP430F149 and some peripherals need +3.3 V power supply, and other parts need +5 V power supply, in this system in. With a +5 V DC voltage as the input voltage, +3.3 V is directly linearly stepped down by +5 V. The principle of the power circuit is shown in Figure 2.

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

2.2 Temperature Sensor Acquisition Circuit The DS18B20 is a compact temperature sensor that communicates with the MCU via a single bus protocol. The hardware connection relationship between the MCU and the DS18B20 is shown in the figure. It can be seen that the P2.4 port of the MCU is connected to the DQ terminal of the DS18B20, and the DS18B20 can be read and written by simulating the timing of the 1-Wire protocol on the IO port of the MCU. The temperature sensor acquisition circuit is shown in Figure 3.

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

3 system software design

The software part of this design mainly includes the realization of temperature acquisition and control module, the realization of data transmission, and the remote control of the client.

3.1 Temperature acquisition and control module

The main function of this module is to control the hardware equipment and complete the temperature collection, display and control functions of the thermostat. The temperature acquisition and control module flow chart is shown in Figure 4.

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

When the temperature data is to be collected, the MSP430F149 will collect the temperature through the temperature sensor. The function used is: function name: ReadTemp, function: read the temperature conversion result from the DS18B20 Scratch Pad, return value: read temperature value. Function name: uint Do1Convert(void), Function: Controls the DS18B20 to complete a temperature conversion, return value: measured temperature value.

Then the A/D swapping will set the value of the register according to the collected temperature data, and the processor reads the temperature data to the transmission control register TXCMD (000 4H) in the network controller CS8900A. If the data is written, the network card chip is After all the data is written, the data is sent. The CPU sends the data through the transmit data register PORT0 (0000H) and finally sends it to the client through the network. The client sends a command to the transmit data length register TXLENG (0006H) in the network controller CS8900A through the network, first writes the length of the transmit data, and then writes the data to the chip through PORT0 for reception, and performs corresponding control operations.

3.2 Software implementation of data transmission

When the data is transmitted through the network, the main application is the TCP protocol to implement data transmission and reception, and the functions to be used in the data transmission and reception process are designed. Because the RTL8019 AS is cached, the CS8900A also needs to send and receive data through the operation of the buffer.

In the process of sending and receiving data packets, different tasks require different processing time. This time can be provided by the timer TImer_A of MSP430F149.

3.3 Client Remote Control Module

The user of the remote console in the system sends a control command to the MSP430F149 after logging in to the control page in the browser connected to the Internet after establishing the HTTP server. This process requires a series of operations. First, the controller will pass the Internet TCP/IP protocol. The conversion between the serial port protocol and the serial port protocol is extracted, and the device information is extracted, and compared with the standard temperature, if the measured temperature is higher than the standard temperature, the output device information is sent a signal indicating the cooling temperature, and the single chip computer accepts the signal through the CS8900A network card interface. The cooling indication sent by the Internet is then cooled by controlling the compressor. If the measured temperature is lower than the standard temperature, the output device information sends a heating indication signal, and the MCU receives the cooling sent by the Internet through the CS8900A network card interface. Instruct and then heat by controlling the heating wire. The HTML (Hypertext Markup Language) web page data can be saved in the on-chip FLASH memory of the MSP430F149. Web pages can receive data, send web page data, close connections, and wait for other applications to connect. The client's remote control module flow chart is shown in Figure 5.

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

4 Simulation results analysis

4.1 Experimental conditions The volume of the thermostat is set to 1 m3; the working environment has a dimension of 25 °C; the operating voltage is 220 V, 50 Hz.
4.2 Control accuracy analysis of the thermostat control system In order to accurately test the control accuracy of the system, a standard thermometer is placed in the thermostat to measure the actual temperature. By setting different target temperature values, the temperature of the incubator is controlled. When the temperature displayed by the system tends to be stable, check the temperature value of the actual temperature displayed by the standard thermometer, and compare the actual temperature with the display temperature of the digital tube. Check the temperature error. The specific experimental data records are shown in Table 1.

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

4.3 Analysis of control performance of the control system of the control system In order to test the control performance of the system, the control variable is tested in the paper to control the performance. There are three main conditions: cooling to preset temperature, heating to preset temperature, different initials. The temperature reaches the preset temperature. The temperature change curve obtained by simulation test is shown in Figures 6-8.

Design of Temperature Control System for Network Control System Based on MSP430F1 49 Single Chip Microcomputer

As can be seen from the above figures, the designed thermostat control system can realize real-time temperature control, reach the preset temperature value, and keep the temperature within a stable range, and the temperature stability error remains at 0. .5 ° C, achieved the expected control effect, has a certain application value.

5 Conclusion

The network control based on single-chip microcomputer realizes the temperature control system is the embedded system of software and hardware platform with single chip as the core. By using MSP430 microprocessor, temperature acquisition circuit, temperature control circuit to build hardware platform, and using network control platform, a remote network control temperature control system based on embedded technology was designed. The system is small in size, simple in circuit connection, and effectively utilizes the characteristics of the Internet, so that users can easily operate and increase the functions required by users. Thereby improving the intelligence of the device and having high engineering practical value.

Lithium Battery CR9V

Lithium Battery Cr9V,Lithium Battery 9V,9V Lithium Battery,9V Lithium Battery Pack

Jiangmen Hongli Energy Co.ltd , http://www.honglienergy.com