Computer-controlled experimental system based on virtual instruments
2026-04-06 05:57:46··#1
Abstract: This paper introduces the development and research of a computer-controlled experimental system. The system's hardware configuration includes a heating furnace as the controlled object, experimental instruments, circuit boards, data acquisition cards, and a PC, thus realizing the hardware environment configuration for a practical teaching system of computer control technology. The experimental system software utilizes Virtual Instruments (VI) technology, and the development environment is LabVIEW 7.0, a virtual instrument application software development platform from National Instruments (NI). The system has achieved good teaching results after being put into use. Keywords: Virtual instrument; PCL-818; LabVIEW Abstract: This paper introduces the experimental system for the course of computer control. The experimental system consists of a control object, test instrument, connection board, data gather card, and computer. The experimental system software, based on LabVIEW 7.0 and PCL-818L, is devised. A new modular system based on the virtual instrument platform is established. A good teaching effect has been achieved after the experimental system for the course of computer control was applied. Keywords: virtual instrument; PCL-818; LabVIEW 1 Introduction "Computer Control Technology" is a core professional course for various automation, electronic and electrical engineering, computer application, and mechatronics majors in Chinese universities. To complement the theoretical teaching of this course, enhance students' perceptual understanding of the course, and improve their innovative practical abilities, our school began researching and developing a corresponding experimental system in 2003, assembled and debugged it for trial use in 2004, and officially put it into experimental teaching in 2005. 2. Introduction to the Functions of the Experimental Device Considering that students lack a practical understanding of the hardware system structure of computer control in the theoretical teaching of "Computer Control Technology," and lack practical opportunities to select control algorithms and related parameters for controllers, we conducted a detailed and in-depth study of the textbook and syllabus during system development. We determined that this experimental device should have the following functions: It can conduct experiments on computer input/output technology; it can conduct experiments to determine the mathematical model of the controlled object using experimental methods; it can conduct data processing experiments; it can conduct control algorithm experiments; and it can conduct comprehensive control experiments. 3. Main Hardware Components of the Experimental Device System The experimental system consists of a signal generator, a temperature control furnace, a test wiring circuit board, a data acquisition card, and a computer, as shown in Figure 1. 3.1 Power Supply Required by the System The DC power required for the temperature control furnace and the test wiring circuit board is supplied by the signal generator. The required DC power range for the experimental system is ±12 V, ±10 V, and ±5 V. ±12 V and ±5 V are the power required for the temperature control furnace's measurement conversion circuit; ±10 V is provided to the data acquisition card for A/D conversion experiments; and the 220 V power required for heating the temperature control furnace is directly supplied by the test bench. 3.2 Temperature Control Furnace Control Principle and Circuit Implementation The main control circuit of the temperature control furnace is shown in Figure 2. Before heating, the temperature setpoint is input via a computer keyboard or mouse through a virtual instrument. After power-on, the detection element inside the temperature control furnace detects the real-time temperature and performs D/A conversion via the test board and data acquisition card, then sends the data to the computer for processing. After processing, the processed control signal is sent to the printed circuit board via the data acquisition card, and then sent from the printed circuit board to the CONTROL INPUT terminal on the control circuit board of the temperature control furnace. This signal changes the power of the heating element to achieve temperature control. The temperature signal detection and conversion circuit is shown in Figure 3. The temperature signal detection uses a thermistor as the measuring element. The real-time temperature is converted into a -10V to +10V voltage signal by the conversion and amplification circuit shown in Figure 2. After A/D conversion via the test board, the signal is sent to the computer for data processing. In Figure 2, W1 is the zero-adjustment potentiometer. 3.2 PCL-818 Data Acquisition Card This system uses Advantech's PCL-818-B data acquisition card. The PCL-818 is a series of high-performance, multi-functional DAS cards that provide five of the most commonly used measurement and control functions: 100kHz 12-bit A/D conversion, D/A conversion, digital input, digital output, and programmable counter/timer. It features strong data acquisition, A/D conversion, D/A conversion, digital input/output, automatic channel detection, and timing/counting functions. It also includes DMA automatic channel/gain scanning and offers high cost-effectiveness. It supports 16 digital inputs and 16 digital outputs in single-ended mode, and 8 digital inputs and 8 digital outputs in differential mode. Software support includes VisiDAQ 3.1™, ActiveDAQ, LabVIEW™, and high-speed DLL drivers for Windows 3.1/95/NT. 4. System Software Design The system software design adopts Virtual Instruments (VI) technology. A VI is a variety of instrument systems composed of basic hardware and software programming techniques, and its functions are user-defined. With the support of VI technology, users can design their own instrument systems according to their own wishes. It integrates functions such as measuring instruments, recording, signal analysis, and control, and is implemented by configuring different software on the same basic hardware. The development environment for this system is LabVIEW 7.0, a virtual instrument application software development platform from National Instruments (NI). LabVIEW is a virtual instrument development environment based on a graphical programming language (G language). It provides a completely new programming method. Using LabVIEW, control systems can be designed through an interactive graphical front panel. For example, it can acquire data from thousands of hardware devices (GPIB, VXI, PXI, RS-232, RS-485, PLC, plug-in data acquisition cards, etc.); it can connect to other data sources through networks, interactive application communication, and Structured Query Language (SQL); and it can use its powerful data analysis programs to analyze raw data, obtain meaningful results, and display the output. 4.1 Instrument Driver The instrument driver is mainly used to initialize the virtual instrument and set specific parameters and operating modes to keep the virtual instrument in normal working condition. Advantech's PCL-818 series data acquisition card provides LabVIEW software support, so the driver installation can be completed by following the prompts. The main options are selected as follows: Board Type: PCL-818L A/D Channels Configuration: 8 Differential 4.2 Application The application mainly analyzes and processes the data input to the computer, defining the functions of the virtual instrument. The application includes data acquisition and storage, waveform display and playback, and data processing. The data acquisition module uses nodes in the Function template/All Functions sub-template/Data Acquisition sub-template to control the data acquisition card for data acquisition. The design requires the system to continuously acquire data from multiple channels, so channel selection control is necessary. The Measurement & Automation Explorer software in LabVIEW is used as a browser to configure the acquisition device and its channels. When using related functions, the virtual channels of the device can be configured. In LabVIEW programming, the names of these virtual channels can be directly specified to control these channels to complete data acquisition. The data acquisition program mainly controls various parameters such as the data acquisition channels, the number of sampling points, and the scanning frequency. The number of sampling points and the scanning frequency of the system signal can be manually set by the user on the front panel according to the requirements of different signals. In the development of the experimental system, it is required to display, process, and save the acquired data to achieve offline data analysis. This system uses spreadsheet text files to store signal waveforms. It can also back up any type of experimental data to a specified location. Given the directory of the backup file, previous data can be retrieved for research and analysis through data simulation and reproduction. To facilitate teaching, the system design also utilizes the LabVIEW environment for analyzing signals and systems. This includes functions such as PID algorithms from classical control theory, curve fitting for signal analysis, Fourier transform, and digital filtering; curve fitting for the nonlinear temperature characteristics of thermistors, etc. Furthermore, its signal generator can be used to generate typical test signals, such as pulses, steps, and sine waves, for simulation analysis of system performance. Its G language block diagram program is shown in Figure 4. [align=center] Figure 4 Block diagram program for constant temperature control[/align] 4.3 Front Panel Program The front panel program is similar to the panel of a real physical instrument, providing an interface between the virtual instrument and the user. Users can perform various operations on the switches, buttons, etc., on the virtual instrument panel using the keyboard and mouse. The front panel of the heating furnace constant temperature control system in this system is shown in Figure 5. [align=center]Figure 5 Front Panel of the Constant Temperature Control System[/align] On the front panel, analog channels and data output channels can be set; control parameters such as setpoints, P, I, and D parameter values can be set; the system can be started and stopped using buttons; and real-time temperature curves and historical temperature curves can be displayed. 5 Conclusion The computer-controlled experimental system developed using virtual instrument technology has the advantages of ease of operation, flexible function definition, and strong scalability. This experimental system has been in use for nearly a year. In teaching, the adoption of this system has greatly improved students' interest in learning this course, provided a practical environment for students to learn abstract theories, strengthened students' perception and understanding of theories, and also stimulated students' interest in innovation, achieving good teaching results. [References] [1] Li Zhen, et al. Testing audio power amplifiers based on LabVIEW, Microcomputer Information, Vol. 22, No. 4-2, 2006. [2] Zhang Yi, et al. Analysis and application of virtual instrument technology, Beijing: Machinery Industry Press, 2004. [3] Rober H. Bishop LabVIEW 6i Practical Tutorial. Beijing: Electronic Industry Press, 2003. [4] Li Ganglin, et al. Modern measurement and control circuits. Beijing: Higher Education Press, 2004.