Design of Virtual Instrument Testing System for Engine Performance
2026-04-06 07:37:16··#1
Abstract: This engine performance virtual instrument testing system adopts the LabVIEW and LabVIEW RT virtual instrument software platform from National Instruments (NI), along with supporting NI PCI data acquisition boards, NI SCXI signal conditioning devices, and NI compact FieldPoint (cFP) distributed I/O real-time system hardware. It achieves parallel testing of multiple performance streams; and can automatically complete real-time monitoring of load, torque, speed, power, pressure, and temperature according to user settings; finally, it realizes remote sharing of test data and remote control of the testing system by the user through the TCP/IP protocol. This system features a short development cycle, high efficiency, and low cost, while also possessing strong system scalability and reusability, making it highly valuable for application. Keywords: Engine performance virtual instrument testing system 1 Introduction With the development of engine electronic control technology, higher requirements have been placed on engine testing. Automation of engine testing has become an important method to improve engine testing efficiency and quality. Virtual instruments combine computers with standardized virtual instrument hardware using software, thereby achieving modularization of traditional instrument functions to achieve the purpose of automatic testing and analysis. Using virtual instrument technology, users can easily complete functions such as signal conditioning, process control, data acquisition, data analysis, waveform display, data storage, fault diagnosis, and network communication of the test object through a graphical programming environment and operation interface, which greatly shortens the system development cycle. At the same time, due to the adoption of standardized virtual instrument hardware and software, the compatibility and scalability of the test system are greatly enhanced. In addition, the virtual instrument technology is highly flexible and reusable, which can minimize the scale of the user's test system and is easy to upgrade and maintain. Users can even use existing hardware to form another test system, thereby reducing unnecessary repeated investment and lowering the system development cost. 2. System Composition and Working Principle (1) System Composition The engine performance virtual instrument test system mainly consists of four parts: the main control module, the CFP real-time monitoring module, the dynamometer module, and the engine under test module, as shown in Figure 1. The main control module is a DELL workstation, which is used to provide a graphical user interface, complete the configuration of the system hardware and the setting of the user interface and control parameters, and update the waveform display of each index parameter against time in real time. After curve fitting, the engine characteristic curve is obtained, and finally the test data is recorded. Meanwhile, the main controller also performs measurements of non-control parameters, such as pressure and fuel consumption, via an embedded NI PCI data acquisition card. The cFP real-time monitoring module consists of two NI cFP distributed I/O systems, communicating with the main controller via TCP/IP protocol. It receives control parameter commands from the main controller to control the dynamometer and returns data signals acquired from the dynamometer module for processing by the main controller. Module A is used to perform real-time automatic loading and measurement of control parameters, and provides emergency measures such as overload protection, emergency shutdown, and system reconstruction after illegal shutdown. Module B is used to perform real-time monitoring of various temperature points of the engine under test. The dynamometer module provides a certain load to the engine under test, and its internal sensors convert the torque, speed, and output power of the engine under test under this load into voltage signals acceptable to the cFP real-time monitoring module A. [align=center] Figure 1 Virtual Instrument Testing System for Engine Performance[/align] (2) Working Principle The virtual instrument testing system for engine performance can operate in two modes: automatic and manual. The main test items are: 1) Engine pressure curve (inlet and outlet of oil, water, and gas). 2) Engine temperature curve (inlet and outlet of oil, water, and gas and the environment). 3) Engine speed curve. 4) Engine torque curve. 5) Engine power curve. 6) Engine fuel consumption curve. In automatic mode, the main controller first waits for the user to complete the hardware and software settings and configuration. Then it prompts the user to select load test or parameter setting test. Under load test, the user needs to set the load curve, load time, cycle time, and test time and other test parameters; under parameter setting test, the user can select the specified torque, speed, or power, and set the corresponding calibration parameters, control parameters, and test time. After completing the above steps, the test program can be started. The test system will automatically load according to the load specified by the user and complete the performance test of the engine under test; or it will maintain the stability of the calibration parameters through a certain control algorithm and automatically test the engine under test in this state. While the system is running, the user can observe the waveform display of each index parameter with respect to time in the real-time monitoring chart. After curve fitting, the engine characteristic curve can be obtained, and the chart of interest can be exported and saved. When the test time is completed, the system will automatically terminate the test. In manual working mode, the working principle of the system is basically similar to that in automatic working mode, except that the system does not perform cyclic testing, but provides an interactive test environment. After completing the specified test items, it waits for further operation by the user. 3. Hardware structure The hardware composition block diagram of the engine performance virtual instrument test system is shown in Figure 2. [align=center] Figure 2 Hardware composition block diagram of engine performance virtual instrument test system[/align] (1) Main control machine The main control machine is a DELL workstation, which is embedded with an Intel Pentium 4 2.6G CPU, a multi-functional data acquisition card, a real-time temperature measurement module, and a real-time monitoring module. (2) Real-time monitoring module The real-time monitoring module uses the NI cFP distributed I/O real-time system. As an industrial-grade control system, the cFP has FIFO data queue, power failure data buffer, watchdog status monitoring, and high impact resistance and anti-interference capability. It is the core part used to complete the real-time acquisition and control of the system. (3) Real-time temperature measurement module The real-time temperature measurement module uses the NI cFP distributed I/O real-time system. It adopts the cFP-2020 controller and is equipped with 4 cFP TC-120 8-channel thermocouple modules. It can be directly used to measure standard J, K, T, N, R, S, E and B type thermocouples, and provides corresponding signal conditioning, double insulation isolation, input noise filtering, cold junction compensation and various thermocouple temperature algorithms for data sampling of each temperature point to be measured in the engine. It also uses the distributed I/O network sharing function based on TCP/IP protocol to realize remote data sharing, which is conducive to remote real-time monitoring of the industrial site. (4) Dynamometer The dynamometer is designed based on the principle of action and reaction force balance. When the torque on the stator of the engine dynamometer is equal to the torque of the engine under test, the torque value of the engine under test is directly and accurately read by the microcontroller data acquisition system. When the engine under test rotates, causing the rotor of the dynamometer to rotate, if a DC excitation voltage is applied to the dynamometer, a magnetic field exists in the dynamometer. At this time, the rotor of the dynamometer rotates and cuts the magnetic lines of force, generating armature current. The interaction between the armature current and the magnetic flux generates braking torque. At the same time, the stator of the dynamometer is subjected to a torque in the opposite direction, which generates compressive stress on the sensor shaft of the dynamometer. Within the normal operating range, the compressive stress is proportional to the torque borne by the sensor shaft. If a resistance strain gauge is attached in the direction of the maximum compressive stress on the sensor shaft, the resistance value at the strain point will change with the magnitude of the compressive stress. By connecting the strain gauge to a certain bridge circuit, the change in compressive stress can be converted into a voltage signal, thereby measuring the magnitude of the torque. The measurement of engine speed uses a photoelectric speed sensor, which has high speed resolution, low inertia, and wide application. By using a microcontroller and a photoelectric sensor in combination, the measurement of engine speed is simple and has strong anti-interference ability. The photoelectric sensor has a disk with N evenly distributed serrations on the edge mounted on the engine shaft. Light is projected onto the phototube. When the engine rotates once, N pulse signals are obtained. The engine speed can be obtained by measuring the frequency or period of the pulse signals. (5) Control cabinet The control cabinet is mainly composed of control switches, switching power supplies, filters and connecting lines. It provides corresponding multi-channel interfaces for each sensing module to connect to the engine under test, and provides auxiliary functions such as safe system power supply, signal isolation, amplitude adjustment and air cooling control. It provides strong power support and system emergency measures for the entire engine test system. 4. Software structure and algorithm (1) Software structure The engine performance virtual instrument test system adopts a client/server (CS) structure based on TCP/IP protocol. The server architecture is based on the NI cFP distributed I/O system, utilizing its embedded standalone real-time system to sample target parameters and perform real-time monitoring and control of these parameters. The client machine adopts a general-purpose PC architecture, running a Windows multi-threaded operating system and using the LabVIEW virtual instrument platform. Communication between the client and server for control parameters and detection data is achieved via TCP/IP protocol. A GUI graphical user interface is provided to enable human-computer interaction, allowing for the input of control parameters, as well as the analysis, calculation, and graphical display of detection data. The system operation process is as follows: after powering on, the server automatically starts the built-in LabVIEW RT real-time program in the memory and listens for the client's "start test" command in real time; the client starts up and runs the engine performance virtual instrument test main program, completes user login, hardware configuration, selects test items, sets test parameters, and starts the test program; after the server hears the client's "start test" command, it starts real-time control and data acquisition according to the hardware configuration, test items and test parameters specified by the client, and sends the experimental data to the client through the TCP/IP protocol; the client issues PID control command and analyzes and processes the experimental data sent by the server. After completing PID control, it performs tests according to the test items, analyzes and processes the test data, and displays the experimental results in a chart; after completing the test, the client issues the end test command, and after the server receives and confirms, the test ends. (2) PID control algorithm This system tested three PID control algorithms: position PID control algorithm, incremental PID control algorithm and integral separation PID control algorithm [1]. 1) Positional PID Control Algorithm The positional PID control algorithm is described as follows: Where k = 0, 1, 2... are the sampling sequence numbers; u(k) is the computer output value at the i-th sampling time; e(k) is the input deviation value at the i-th sampling time; e(k-1) is the input deviation value at the (k-1)-th sampling time; KI is the integral coefficient, KI = KPT/TI; KD is the derivative coefficient, KD = KPTD/T; KP is the proportional coefficient; TI is the integral time constant; TD is the derivative time constant; T is the sampling period. The advantages of this algorithm are its simple principle, which is simply a discretization of the classic PID algorithm theory applied to computer-aided measurement, and its simple structure makes it easy to implement. The disadvantages are that each output is related to the past state, requiring the accumulation of e(k) during calculation, resulting in a large workload for the computer. Furthermore, because the computer output u(k) corresponds to the actual position of the actuator, a large change in u(k) due to computer failure will cause a large change in the actuator position. 2) Incremental PID Control Algorithm The incremental PID control algorithm is described as: [Equation omitted]. The advantages of this algorithm are that, due to the incremental output from the computer, the impact of erroneous actions is small, and logical judgment can be used to remove it if necessary; the impact during manual/automatic switching is small, facilitating smooth switching; furthermore, when the computer fails, the output channel or actuator has a signal latching function, thus maintaining the original value; and no accumulation is required in the formula. The determination of the control increment Δu(k) is only related to the most recent k sampled values, so it is relatively easy to obtain a good control effect through weighted processing. Incremental control also has disadvantages: a large integral truncation effect, resulting in static error; and a large overflow effect. 3) Integral Separation PID Control Algorithm The integral separation PID control algorithm is described as follows: Where: When the deviation value is relatively large, PD control is used to avoid excessive overshoot and to ensure a faster system response. When the deviation value is relatively small, PID control is used to ensure the control accuracy of the system. 5. Conclusion This virtual instrument testing system for engine performance realizes real-time monitoring of multiple pressure, torque, speed, power, and temperature of the engine, and uses the TCP/IP protocol to realize remote control of multiple signals by the main controller and network sharing of test data; the system has high measurement accuracy and strong operational stability, and is suitable for comprehensive performance testing of various types of engines. Innovations of this paper: 1. Application of virtual instruments in engine performance testing. 2. Remote control of multiple signals by the main controller and network sharing of test data. References 1. Tao Yonghua. New PID Control and Its Application, Second Edition. Beijing: Machinery Industry Press, 2000. 2. Xue Chaogai, Cao Haiwang, Gu Wentao. Microcomputer Information, 2006, No. 7-1, pp. 96-98.