Share this

Research on Remote Network Measurement and Control Technology Based on Virtual Instruments

2026-04-06 05:59:01 · · #1
Abstract: This paper proposes a novel remote measurement and control technology scheme utilizing virtual instrument technology. The scheme adopts a C/S architecture, where the client-side virtual instrument application implements network communication with the server to meet monitoring and control requirements. DataSocket technology is primarily used to fulfill the requirements of networked measurement and control, offering advantages such as security and flexibility. Finally, the consistency problem in data transmission and reception is discussed in detail, proposing a solution that binds information such as time as data attributes to real-time data before data release, effectively solving this problem. Keywords: Virtual instrument; Remote network; Measurement and control technology; Consistency; DataSocket 1 Introduction With the introduction of network technology, virtual instrument technology has gradually developed towards networking, and many testing tasks have also proposed remote testing requirements. Therefore, networked virtual instruments have become a development direction for virtual instrument technology. The combination of virtual instrument technology and network technology and its application in the field of measurement and control represents a revolution in traditional measurement and control methods. Using LabVIEW as a virtual instrument software development platform greatly facilitates the development of high-performance computer measurement and control systems. The networking of measurement and control methods is an inevitable trend in the future development of measurement and control technology. By establishing a distributed network measurement and control system, we can make full use of existing resources and the various benefits brought by the network, and achieve the most efficient and reasonable allocation of various resources. Distributed network measurement and control allows for multi-point measurement and multi-point analysis and processing. This fully utilizes the interface capabilities of the server to control the test instruments, as well as the data processing capabilities of the client, and facilitates system expansion. 2. Implementation of Remote Measurement and Control 2.1 Composition of the Remote Measurement and Control System Based on the remote measurement and control data flow and different testing requirements, a remote testing system can be built using either a Client/Server (C/S) or Browser/Server (B/S) network model. This project adopts the C/S model, which is suitable for situations with large data transmission volumes and features high efficiency, reliable and complete data, and strong compatibility. The structure diagram of the remote measurement and control system is shown in Figure 4.9. The measurement and control server, as the measurement publishing node, mainly completes the functions of data acquisition, data publishing, and storing the acquired data in the database server. The web server mainly provides basic website functions; clients can access the website to obtain real-time job information and historical data from the database server. In addition, the client uses the virtual instrument application to establish network communication with the server, monitor and control the server's operations, receive operation data from the server, and perform data analysis and processing, storage and display of data processing results, generation of data reports, and printing of data or waveforms. [align=center] Figure 1: Remote Measurement and Control System Structure Diagram[/align] 2.2 DataSocket Technology Based on C/S Mode In computer-based remote measurement and control, although there are currently various technologies such as TCP/IP and DDE for sharing data between two applications, these technologies are not used for real-time data (Live Data) transmission. Only DataSocket (DS) is a technology used for sharing and publishing real-time data in measurement and automation applications. DataSocket technology is a simple and easy-to-use network data communication technology. It encapsulates TCP/IP programming details (such as selecting port numbers, defining protocols, creating connections, byte stream processing, error handling, etc.), allowing test engineers to easily build networked virtual instrument test systems without understanding the underlying network programming technology. After the LabVIEW development environment is installed, a National Instruments DataSocket entry will be added to the Windows program menu, including the two components of DS: DataSocket Server Manager and DataSocket Server. The DataSocket Server is a small, standalone program. To transmit data using DS technology, the DataSocket Server must be open on the machine publishing the data. Programs publishing data output data through it; programs receiving data must locate it to receive data. The DataSocket Server panel, as shown in Figure 4.10, displays the number of tasks currently connected to the DS server from the host zhangtianyi.workgroup and the number of data packets already sent. The main functions of the DataSocket Server Manager and DataSocket Server are setting the number of clients and data items that can be created on the DS Server, setting user permissions, and predefining data items. [align=center] Figure 2: DS Server Panel[/align] The DataSocket API provides a single interface for communication across various programming languages ​​and data types. In LabVIEW, this is manifested in two functions: DataSocket Read and DataSocket Write. When publishing data, the DataSocket Write function automatically converts user data into a byte stream for transmission over the network; when receiving data, the DataSocket Read function restores the byte stream to its original form. The three parts of DS data transmission—the data publishing program, the DS server, and the data receiving program—can be placed on the same machine. However, it is more common to place the data publishing program and the DS server on one machine, which serves as the measurement and control server, while the data receiving program runs on another machine, which serves as the client. This project adopts the latter approach to achieve remote measurement and control. The measurement and control server first collects data and then publishes the collected data to the DataSocketServer. The client can then synchronously receive data from the DataSocketServer, ensuring the consistency between the client data and the original experimental data. A flowchart example of real-time data transmission using DataSocket technology is shown in Figure 3. [align=center] Figure 3: Flowchart of DataSocket data publishing and data receiving program (left is publishing, right is receiving)[/align] Using DataSocket technology to implement networked measurement and control has many advantages. One prominent advantage is high security. Using DataSocket ServerManager, the number of client connections, the number of data items, user groups and users can be set, and user read/write and data item creation permissions can be set (users without set permissions cannot access the server). In addition, DataSocket uses port 3015 for data transmission. This port has been registered with IANA (Internet Assigned Addresses Authority) as a dedicated port for the DSTP protocol. Therefore, DataSocket servers can run on computers outside the firewall, while ensuring the secure operation of data publishing applications on computers inside the firewall. DataSocket transmits data with a small header file, resulting in fast data transmission speeds, making it suitable for transmitting large amounts of real-time data over a network. 3. Consistency Issues in Data Transmission and Reception During signal acquisition, the acquired data is closely related to time. Therefore, time information and other relevant information need to be transmitted along with the acquired real-time data. One approach is to send multiple data items at the publishing end, creating separate data items for real-time data, time, and other information. These are then published separately by the DataSocket Publisher on the acquisition server to the DataSocket Server, and finally received by the client. However, testing revealed the emergence of spurious data. To ensure consistency in client-received data, a data attribute method is adopted, binding time and other information as data attributes to the real-time data before data publication. This method transmits a unified set of real-time data, time, and other information between the server and client. All transmitted information arrives at the receiving end simultaneously, where it is then used to extract the relevant data using data attributes. Even if data loss occurs during transmission, only the bound data packets are lost, and the loss does not affect subsequent data transmissions. This prevents the generation of spurious experimental data and avoids mismatches or inaccurate matching due to missing data. The monitoring and control server requires the client to display test results correctly and synchronously in real time while collecting and analyzing data. Simply using DataSocket Write.vi and DataSocket Read.vi in ​​DataSocket often leads to the following problems: the sent and received data are not synchronized, and a lot of useless data is received, such as timeout prompts in DataSocket Read.vi, returning the last received data, or failing to read data, returning a value of "0," etc. These are all spurious data unrelated to the monitoring and control process, causing confusion at the receiving end. To address this issue and ensure the consistency of data received by the client, the data attribute method mentioned above can be used. This involves binding the identifier with the real-time data, packaging it, and then publishing the data. Specifically, each data packet is divided into two items: a data item and an attribute item. The data item stores the collected values ​​and the current transmission marker—sequence number Q—instead of the data attribute item. The packet is then sent to the DataSocket. The receiver also establishes a reception marker—sequence number P (initial value is the same as sequence number Q). Since each packet has a unique sequence number, each time the receiver reads a data packet, it only checks the consistency between sequence number P and sequence number Q to determine whether to accept the packet and stores it in the display array. Then, sequence number P is automatically incremented by 1 (i.e., preset to the sequence number of the next received packet) to prepare for the next transmission. If a data packet returned from DataSocket Read.vi has a sequence number Q of 0 or another value, it will be inconsistent with the value in the current sequence number P, indicating that this data packet is invalid. The client will not receive it and will loop and wait to read the next data packet. Figure 4 shows the program flow: [align=center] Figure 4: Data Sending and Receiving Flow[/align] 4. Summary of Innovations The innovation of this paper is the proposal of a remote network measurement and control system implementation scheme based on virtual instruments, and a detailed analysis of the overall framework and implementation technology of the remote measurement and control system. Furthermore, with the introduction of network technology, virtual instrument technology is gradually developing towards networking, and many testing tasks have also put forward the requirement of remote testing. Networked virtual instruments have become a development direction of virtual instrument technology. This project adopts DataSocket technology based on the C/S model, which solves the consistency problem of data transmission and reception, and realizes the remote measurement and control function of virtual instruments. References: 1 Wang Cheng, He Zhiwei. Architecture and Implementation of Networked Automatic Testing System Based on Virtual Instrument [J]. Electronic Technology Application, 2002. 2 Wu Anhe, Zhou Lili, eds. Windows Device Driver (VxD and WDM) Development Practice [M]. Electronic Industry Press, 2001. 3 Shi Fuqiang, Zhao Deyong, et al. Practical Tutorial on LabVIEW 6.1 Programming Technology [M]. China Railway Publishing House, 2000. 4 Gong Chongquan. Development of Virtual Instruments Based on Fieldbus Technology [J]. Microcomputer Information, 2006, 2-1: 177-178.
Read next

CATDOLL Yana Hybrid Silicone Head

The hybrid silicone head is crafted using a soft silicone base combined with a reinforced scalp section, allowing durab...

Articles 2026-02-22
CATDOLL Diana Soft Silicone Head

CATDOLL Diana Soft Silicone Head

Articles
2026-02-22
CATDOLL 115CM Momoko TPE

CATDOLL 115CM Momoko TPE

Articles
2026-02-22