In the process of urban construction, more and more attention is paid to the concept of green environmental protection. However, the use of solid bricks will cause a huge waste of resources, so the use of hollow bricks has increased rapidly. The production of hollow bricks requires a large amount of eco-ceramic materials, but the corresponding performance testing tools for ceramic materials are still far from perfect. It is of great practical significance to develop a high-performance eco-ceramic performance detector. This paper takes the comprehensive properties of ceramic materials as the research object and develops a ceramic air permeability performance detector.
In order to realize intelligence and visualization, the ATmega128 microcontroller with a high data throughput rate is used as the main control chip of the system, and the high visualization configuration software is used as the monitoring system for the whole ceramic performance detection process. Combining the advantages of the two, a ceramic detection system with easy operation and high detection accuracy are designed.
The detection principle is as follows: at room temperature, detect the cubic number of gas passing through a porous ceramic product with a thickness of 1 cm and an area of 1 m2 in a laminar flow state within 1 h when the pressure difference is 1 mm of the water column.
1 System structure and composition
The ceramic detection system based on AVR ATmega128 microcontroller and configuration software is mainly composed of upper control system and a lower node control unit. The structure diagram is shown in Figure 1. The upper control system is composed of upper computer control software and a communication bus interface. The lower control unit is composed of pressure acquisition and transmission board, control CPU, bus interface, pressure sensor, pressure feedback communication interface, liquid level sensor, and other parts. The system adopts the design method of bus structure and modularization, and each part is flexible and has good expansibility. The control system can also connect an external communication module to communicate with the host computer and upload the data information. The AVR embedded controller issues control commands to the actuator to control the rotational speed of the motor, so as to detect and control the pressure.
Host computer control part: It is mainly composed of bus interface and host computer. One end of the bus interface is connected with the bus to complete the communication with the bus; the other end is connected with the host computer to complete the communication with the host computer. Its main function is to transmit the operation signal and control parameters of the upper computer to the designated lower computer node. At the same time, the data of the node is transmitted to the upper computer for further processing. The communication between it and the upper computer is to exchange data with the upper computer through the RS 232 serial port.
On-site control part: The on-site control layer is the bottom layer of the system, which is firstly communicated with the host computer by the signal acquisition and conditioning module through the RS 232 bus. Then the transmitter and the actuator with the bus interface are used to realize the specific operation, and they communicate through the RS 485 bus to complete all the control work.
2 System hardware design
In terms of function, the whole system is divided into five parts: liquid level detection module, PWM control motor module, constant pressure control module, signal acquisition, and conditioning module, and human-machine interface.
The main control module adopts an 8-bit AVR microprocessor with high performance and low power. Due to its advanced instruction set and single clock cycle instruction execution time, the data throughput rate of ATmega128 is as high as 128 MIPS/MHz, which can slow down the contradiction between power consumption and processing speed of the system. The JTAG interface realizes the programming of Flash, E2PROM, fuse bits, and lock bits through the JTAG interface. The analog and digital peripherals and other functional components commonly used in data acquisition and control systems are integrated on-chip: built-in FLASH program memory, internal RAM, and RAM located in the external data memory space in most devices. High-speed, pipeline structure core, real 10-bit, 100KSPS 8-channel ADC, 512 KB E2PROM, erasing and writing life of 100,000 times. The SPI serial interface that can work in master/slave mode has a programmable watchdog timer with an independent on-chip oscillator.
2.1 Pressure sensor conditioning circuit design
The pressure sensor part of the signal acquisition and conditioning module adopts DG universal series pressure transmitter with a standard all-stainless-steel welded structure, with an accuracy of up to 0.1% FS, with small size, high performance, high cost performance, high stability, and high sensitivity. The voltage signal of the differential pressure sensor is filtered and followed in the forward direction, and then connected to a voltage divider resistor. The internal A/D of ATmega128 obtains the 10-bit A/D value by sampling directly from the voltage dividing resistor. The designed pressure sensor signal processing circuit is shown in Figure 2.
2.2 Infrared liquid level detection circuit design
In order to automatically detect the flow rate of the detection liquid per unit volume, an infrared detection system is installed at the input and output ports of the glass container. The infrared light source driver circuit designed here is shown in Figure 3. Among them, the +12 V voltage is applied to the two ends of the amplifier through two 100 kΩ resistors to form the same phase ratio. The amplification factor of the amplifier circuit is Vi0=(1+RF/R1)V to drive the turn-on and turn-off of the triode and drive the light-emitting diode.
3 System software design
3.1 Design of Control Algorithm
In order to achieve the performance index requirements of high precision, fast response speed, and a wide measurement range of ceramic testing equipment. The designed ceramic detection control software adopts the method of combining PID control algorithm and membership function of fuzzy neural network control to complete the control of each module and realize the functions of parameter calibration, setting, air permeability measurement, constant voltage signal (PWM signal) output, etc. After the software completes the initialization settings, it performs pressure signal data acquisition and processing, constant pressure control output, etc. According to the actual working conditions, when the pressure signal variation range is too large, the system will be in a waiting state until the pressure is adjusted to the range of 9 500 ~ 10 050 Pa. At the same time, when the error range is relatively large, the PWM signal will be roughly adjusted according to the fuzzy neural network algorithm, and when the distance from 10 000 Pa is small, the PID will be used for precise adjustment to ensure that the output PWM signal is within the design range.
Ordinary PID control is the combined control of proportional, integral, and differential taking deviation in the feedback control system. Fixed parameter PID control belongs to linear control. However, the process of liquid level rise has the characteristics of nonlinearity, time-varying, and uncertainty. For this kind of system, it is difficult to achieve the ideal control effect by using fixed-parameter PID control, so the method of variable parameter control is adopted.
Here, the characteristics of easy expression of fuzzy control knowledge and the advantage of strong self-learning ability of neural network are combined to improve the learning ability and expression ability of the whole system and realize the online intelligent speed regulation of the motor. Through the intelligent control system, the fuzzy control laws and membership functions are implicitly distributed in the whole network, the neural network is used to realize fuzzy reasoning, and the online self-learning ability of the neural network is used to adjust the membership functions and change the fuzzy control laws so that the control system The working state can be automatically adjusted according to the set speed and environmental state changes to realize the intelligent control of the speed.
The experimental results show that the algorithm can effectively control the stability of the PWM output, and can stabilize the pressure very well, ensuring that it is within the design value range, and further improving the detection accuracy of the system.
3.2 Data Communication Design
The communication of this system mainly adopts the signal acquisition and conditioning module to complete the data acquisition. This module is an important part of the ceramic inspection intelligent controller with an ATmega128 microcontroller as the core. The ATmega128 chip contains 128 KB ISP’s FLASH read-only program memory that can be repeatedly erased and written 10,000 times. The data of the pressure sensor is monitored and set and recorded to the database. The parameters in the main control interface are the parameters of the smart instrument transmitted through the data acquisition field bus RS 485.
Since the data format of the communication between Kingview and the microcontroller is ASCII code, the communication protocol between the control system and the host computer is defined in advance, such as baud rate, data bit, stop bit and parity check, etc. must be defined in the protocol. First, assign the address to the data variable to be communicated in Kingview. According to the design requirements, the data type is divided into two types: byte and unsigned integer, occupying 1 B and 2 B space respectively. Therefore, there should be no overlap during allocation, and continuous data areas are used here to improve communication speed.
3.3 Design and development of monitoring system
In the design, the visualization of Kingview components and its integrated visualization database tool was fully utilized, and the monitoring software was developed as shown in Figure 4. The man-machine interface is divided into the following pages: login screen, main screen, test square sample parameter screen, test round sample screen, alarm screen, data query screen, report printing screen, etc.
The following describes the main modules in detail:
3.3.1 Parameter module function
This system includes the shape of the sample, the size of the sample, the measurement data (input two pressure values), the system will automatically time the test during the test, continuously collect the pressure data information, and then quickly and steadily adjust the PWM output according to the fuzzy neural network PID controller, and then adjust the speed of the motor, and finally ensure that the pressure is constant within the design requirements.
3.3.2 Alarm module function
There are two main alarm items in this system: one is to send out an alarm signal when the pointer in the water storage tank is higher than the water level for a certain period of time; the other is to send out an alarm signal when the pressure sensor exceeds the set value.
3.3.3 Function of report printing module
The report printing module prints reports for some important parameters in the daily production process, so as to record the production situation. One report can select 16 parameters, which is a fixed report format. As shown in Figure 5.
The man-machine interface developed by the configuration software has two notable advantages: first, in the actual operation, first log in to the interface to set the initial parameters, and then follow the system prompts for the next step. The operator can complete the operation according to the prompt of the system, with a high degree of automation. For example, after entering the main interface, the system will prompt to install the sample, and then prompt to check the airtightness of the system. The second is the vivid image of the main interface. For example, when each step of the operation is carried out, the corresponding device in the figure will also run, which can simulate the working state of the actual scene.
(1) The data throughput rate and powerful I/O port of ATmega128 are fully utilized to ensure the requirements of fast data processing and timely communication. At the same time, the designed fuzzy neural network controller makes the test range widened to a large extent and the test Accuracy is also improved.
(2) Using the upper computer control software developed by Kingview, the design of the system and the man-machine interface can be controlled conveniently and quickly.
(3) The actual operation shows that the ceramic measurement and control system performs well in both stability and real-time performance.
This system has been well received by users. It not only improves the degree of automatic testing but also improves testing accuracy and saves staff. During long-term use, the user’s needs are met.