A practical distributed data acquisition and control system
2026-04-06 07:22:28··#1
I. Introduction Liquid level measurement is very common in industrial production and has a wide range of applications, such as the measurement and control of tap water levels, and the measurement of oil levels in oil pipelines and storage tanks. High-precision sensors can be used in these testing systems to sense and transmit signals such as pressure, flow rate, and temperature. These signals are converted into electrical signals, amplified, converted to digital (A/D), processed by a microcontroller, and finally sent to a remote PC. This enables real-time monitoring of the liquid level on-site, allowing commands to be sent to the controlled unit to take corresponding actions. The block diagram of the entire system is as follows: [align=left] II. Specific Implementation Process 1. Amplification Section: Application of TLC4502 – Dual-channel self-calibrating low-noise high-speed operational amplifier. There are many types of integrated operational amplifiers. In various instruments and control circuits, operational amplifiers must have high precision, high common-mode rejection ratio, and low temperature drift. Currently used precision operational amplifiers all have an external zero-adjustment potentiometer input terminal, and the offset must be zeroed first during application. Due to the complexity of the circuit, debugging becomes inconvenient. The TLC4502 precision dual operational amplifier, manufactured by Texas Instruments (TI), employs automatic calibration technology. Upon power-up, it automatically adjusts the input offset voltage to zero, making it very convenient to use and saving on PCB boards and external discrete components. The pin arrangement of this device is shown in the figure below. The TLC4502 automatic calibration operational amplifier utilizes on-chip processing of digital and analog signals to automatically calibrate the input offset voltage to zero upon power-up. Automatic calibration typically takes 300ms, and continuous calibration can be performed repeatedly within a range of ±3μV. Once calibration is complete, most of the calibration circuitry is disconnected from the signal channel and shut down, thus having almost no impact on the signal channel. This allows the TLC4502 to be used like any other precision operational amplifier after the calibration cycle. The TLC4502 features high precision, high gain, good power supply rejection ratio, and strong drive capability, making it widely applicable in data acquisition, digital audio, and industrial control. In this system, the weak signal from the sensor is amplified. The specific circuit is shown in Figure 1: [/align][align=center] Figure 1 [/align][b][align=left] [/b]2. A/D Conversion Section: Application of TLC1549 - 10-bit Analog-to-Digital Converter with Serial Control. The voltage signal from the amplifier enters the A/D converter to form a digital signal that is easy for the microcontroller to process. In this design, the 10-bit analog-to-digital converter TLC1549 manufactured by TI (Texas Instruments) is used. It adopts CMOS technology, has built-in sampling and holding, uses a differential reference voltage high-impedance input, is anti-interference, can be calibrated according to the proportional range, has a total unadjustable error of (±) 1LSBMax (4.8mV), and has a small footprint. [/align][align=left]3. Working Section Its working principle is as follows: When the chip select (/CS) is invalid, I/OCLOCK is initially disabled and DATAOUT is in a high-impedance state. When the serial interface pulls /CS to be valid, the conversion timing begins to allow I/OCLOCK to work and removes DATAOUT from the high-impedance state. The serial interface then provides the I/OCLOCK sequence to the I/OCLOCK and receives the previous conversion result from DATAOUT. The I/OCLOCK receives an input sequence of length between 10 and 16 clock cycles from the host serial interface. The first 10 I/O clock cycles provide control timing for sampling the analog input. On the falling edge of /CS, the MSB of the previous conversion has been present for 10 clock cycles. On the falling edge of the 10th clock cycle, the internal logic pulls DATAOUT low to ensure that the remaining bits are zero. During a normal conversion cycle, a high-to-low transition at /CS within a specified time can terminate the cycle, and the device returns to its initial state (the output data register retains the previous conversion result). Care should be taken to prevent /CS from being pulled low near the end of the conversion, as this may corrupt the output data. The timing diagram is shown in Figure 2. In this circuit, three TLP521 optocouplers are used for isolation, completely eliminating electrical connection between the PC and the SN75LBC184, thus improving reliability. The working principle is as follows: When the RTS pin of the RS232 is at logic level 1 (-12V), the LED of the optocoupler does not emit light, the phototransistor is not conducting, and the output level is TTL logic level 1 (+5V). This selects the DE pin of the RS485 interface chip, allowing RS485 reception. Thus, the TXD pin of the RS232 can send data (the working logic is similar to the RTS pin). When the RTS pin of the RS232 is at logic level 0 (+12V), the LED of the optocoupler emits light, the phototransistor conducts, and the output is TTL logic level 0 (0V). This selects the RE pin of the RS485 interface chip, allowing RS485 transmission. When the RS485's R terminal is working, and its output is logic level 1, the optocoupler's LED does not light up, and the phototransistor is not conducting. When the RS232 output stops, its TXD level is -12V, and the capacitor is charged to -12V, causing its output to also be -12V, i.e., logic level 1. When its output is logic level 0, the optocoupler's LED lights up, and the phototransistor conducts, causing its output to be +5V, which is also within the RS232 logic level 0 range, i.e., logic level 0. Thus, according to the protocol between the PC and the microcontroller, interactive communication between the two can be achieved. 4. Power Supply Section: The stability of the power supply is fundamental to the normal operation of the entire system. In this design, all components use the commonly used +5V voltage. To improve voltage stability, a fixed positive output, low dropout voltage regulator TL750L05 from TI is used. The TL750L05 requires an output capacitor. Without it, the output voltage will be a sawtooth wave, with the rising edge varying with the input voltage. Adding an output capacitor can suppress this phenomenon. The output capacitor range is 0.1uF to 1uF. The circuit is shown in Figure 6. [align=left] III. Conclusion A distributed data acquisition and control system, composed of TI's analog products TLC4502, TLC1549, SN75LBC184, TL750L05, and Atmel's microcontroller AT89C2051, has been used to monitor parameters such as pressure, flow, and temperature in oil pipelines, with good performance. The system's features include: small size (5cm x 6.5cm); good performance, stable operation, simultaneous processing of several physical parameters for real-time monitoring; and simple and convenient operation. Appendix: A physical diagram of the system is shown below.[/align]