Network analyzer port multiplexing system and method, and storage medium
The network analyzer port multiplexing system addresses the high cost, complexity, and maintenance issues of existing systems by using a port switch and control program on a carrier computer with secondary screens, enhancing test efficiency and flexibility without user PCs.
Patent Information
- Application Number
- CN202410330308.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2023-08-28
- Filing Date
- 2024-03-22
- Publication Date
- 2024-12-13
AI Technical Summary
Existing network analyzer port multiplexing systems are costly, complex to operate, and difficult to maintain due to the need for multiple user PCs, which increase costs, operational complexity, and maintenance difficulties.
A network analyzer port multiplexing system that utilizes a port switch, a control program running on a carrier computer, and secondary screens for data display, eliminating the need for user PCs by enabling remote or manual control of port switching and data processing through a control program clone displayed on secondary screens.
Reduces the need for multiple PCs, simplifies operations, and enhances test efficiency and flexibility by allowing simultaneous processing of multiple devices under test, while reducing costs and maintenance complexity.
Smart Images

Figure CN119135581A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of network analyzer application, and in particular to a network analyzer port multiplexing system, method and storage medium. Background Art
[0002] Network analyzer port multiplexing refers to the use of technical means to enable the ports of a network analyzer to act as more ports, thereby reducing the number of network analyzers required and thus reducing the cost of use. Network analyzer port multiplexing can test the same device with multiple test ports (such as array antennas), and can also be used to test different devices with dual test ports (such as filters).
[0003] The invention patent application with application number 201010173329X discloses a time-division multiplexing measurement system and a measurement method based on a vector network analyzer, wherein the time-division multiplexing measurement system includes the following steps:
[0004] (1) The output ends of the RF multiplexer are divided into N (2 < N < 10) groups, and the first output ports of the first RF multiplexer and the second RF multiplexer form the first group of measurement ports. Similarly, the nth (n ≤ N)th output ports of the first RF multiplexer and the second RF multiplexer form the nth group of measurement ports, respectively providing measurement for N users;
[0005] (2) calibrating the N groups of measurement ports one by one, and saving their calibration files in the order of the measurement ports for subsequent measurement calls;
[0006] (3) The host computer allocates a thread to each user PC through a multithreading method, and the user PC communicates with the host computer through the thread;
[0007] (4) Each user connects the DUT to their respective measurement ports and performs the following measurements:
[0008] (4a) When a user clicks on a measurement instruction, the user's PC sends the measurement instruction to the main control computer through the network. The main control computer puts the measurement instruction in the instruction pool and executes the measurement according to the instruction sequence in the instruction pool;
[0009] (4b) The main control computer sends the first measurement instruction to the vector network analyzer, which calls the calibration file of the corresponding channel to complete the calibration of the instrument, and then performs measurement and transmits the measurement data to the main control computer through the network. The main control computer transmits the measurement data to the user PC that sent the instruction, deletes the current measurement instruction, and advances other measurement instructions in sequence;
[0010] (4c) After receiving the measurement data, the user PC that sent the instruction processes and displays the data on the computer, completing one measurement;
[0011] (5) When other users send measurement instructions to the main control computer, the measurement instructions are also saved in the instruction pool in sequence and sorted in order, waiting for the main control computer to respond, and repeating steps (4a)-(4c) until all measurement instructions in the instruction pool are completed.
[0012] The specific implementation method of the invention patent application
[0027] describes the system composition as follows: "The time-division multiplexing measurement system of the present invention includes a main control computer 1, a router 2, a vector network analyzer 5, two radio frequency multiplexers 6 and multiple user PCs 3."
[0013] The specific implementation scheme
[0028] further defines the user PC as follows: "The user PC 3 is provided with a connection module, a control module and a data processing module. The connection module is used to establish a connection with the main control computer; the control module is used to send calibration instructions and measurement instructions to the main control computer 1; the data processing module is used to process the measurement data fed back by the user PC 3 to the main control computer 3."
[0014] In the above description, paragraph
[0027] directly and unambiguously indicates that the time-division multiplexing measurement system based on the vector network analyzer disclosed in 201010173329X requires multiple user PCs, while paragraph
[0028] directly and unambiguously indicates that what is required is a computer with full functions.
[0015] There is no doubt that the existing time-division multiplexing measurement system has the following technical problems:
[0016] 1. High cost: The multiple complete computers required will significantly increase costs. Each computer needs to purchase independent hardware devices, such as CPU, memory, hard disk, etc., as well as related software licenses, such as operating system, network management software, etc. These costs include not only the purchase cost, but also the cost of system configuration, installation, maintenance and update;
[0017] 2. Complex operation: Using multiple computers requires separate settings and operations, which increases the complexity of user operations. Moreover, different computers may have different configurations and settings, and users need to manage and maintain multiple systems separately, which not only increases the cost of use, but may also lead to operational errors. In addition, for users who are not familiar with computer operations (currently, a large proportion of filter commissioning personnel are not familiar with computer operations), using multiple computers may require additional training and learning costs, making the operation more complicated and difficult.
[0018] 3. Difficulty in maintenance: The use of multiple computers will also increase the difficulty of system maintenance. Each computer needs to be independently maintained and updated, including software updates, security patches, system configuration, etc. For administrators of network analyzer port reuse systems, it takes more time and energy to manage and maintain these computers, which increases the workload and complexity. At the same time, the use of multiple computers also increases the risk of system failure, because the failure of any computer may affect the stability and reliability of the entire system.
[0019] It can be seen that the existing technology still needs to be improved and developed. Summary of the invention
[0020] In view of the above-mentioned deficiencies in the prior art, the object of the present invention is to provide a network analyzer port multiplexing system, method and storage medium that eliminates the need for a user PC in a time-division multiplexing measurement system based on a vector network analyzer, aiming to solve the problems of the existing network analyzer port multiplexing system being high in cost, complex in operation and difficult in maintenance.
[0021] The technical solution of the present invention is as follows:
[0022] A network analyzer port multiplexing system, comprising:
[0023] A port switch, the port switch is used to connect the network analyzer and at least two devices under test, and realize the connection and disconnection between the network analyzer and the devices under test by switching ports;
[0024] A control program, the control program is used to run on a computer and communicate with the network analyzer and the port switch through a carrier computer, and is also used to control the port switch to perform port switching according to a single scan time of the device under test by the network analyzer;
[0025] At least one secondary screen, which shares a host with the primary screen on the carrier computer and is connected to the carrier computer via a wired screen expansion technology or a wireless screen expansion technology, and is used to display data of the corresponding device under test;
[0026] A control program clone runs on the carrier computer and is displayed on the secondary screen, and is used to receive manipulations from the secondary screen control user. In manual mode, the secondary screen control user remotely and manually controls the port switch to perform port switching.
[0027] The effect of the above scheme is that the control program in the present invention directly runs on the computer and is connected to the network analyzer and the port switch through the carrier computer. That is to say, the present invention only needs the control program to realize the port switching and data processing functions, and does not need to use an additional computer to install the data processing module for data processing as in 201010173329X, nor does it need to install the connection module and the control module on the main control computer and the user PC to realize the port switching, thereby reducing the demand for multiple PCs; the present invention includes at least one secondary screen, on which the control program clone is displayed, and the two cooperate to display the The data of the test piece can be obtained, and it has a remote control function. According to user needs, it can be remotely connected to the carrier computer through the network to realize remote control through wireless split-screen technology, and it can also realize short-range control through wired split-screen technology. In manual mode, whether it is multi-user short-range manual control port switching or multi-user long-range manual control port switching, or multi-user short-range and long-range combined manual control port switching, it can be realized, avoiding the use of multiple PCs; the present invention eliminates the user PC of the existing network analyzer port multiplexing system, and naturally solves the problems of high cost, complex operation and difficult maintenance caused by the use of user PCs.
[0028] In addition, the network analyzer port multiplexing system provided by the present invention can quickly switch to the next device under test for measurement by automatically controlling the port switcher through the control program after scanning one of the devices under test once, and complete the scanning of other devices under test by using the time difference that the single scanning time of the network analyzer for the device under test is usually much smaller than the human body's reaction time, and repeatedly switch in this way, thereby realizing the simultaneous processing of multiple devices under test, and truly realizing the port multiplexing of the network analyzer; and, because the control program can automatically control the port switcher to switch ports according to the single scanning time of the network analyzer for the device under test, whether the single scanning time of the device under test is the same has no effect on the implementation of the present invention, that is, whether the model and type of the device under test are the same has no effect on the network analyzer port multiplexing system (for example, while the antenna tester is testing the antenna performance, the filter debugger can use the same network analyzer to debug the filter at the same time). Therefore, the present invention greatly improves the test efficiency and use flexibility of the dual-port device under test, and also greatly reduces the test cost.
[0029] In a further preferred embodiment, the network analyzer port multiplexing system includes: an auxiliary debugging program, the control program clone is replaced by an auxiliary debugging program clone, the auxiliary debugging program clone is used to receive manipulation by the secondary screen control user, and in manual mode, the secondary screen control user remotely and manually controls the port switch to perform port switching.
[0030] The effect of the above scheme is that the auxiliary debugging program, as the name implies, can assist in the debugging of the device under test. The auxiliary debugging program clone is displayed on the secondary screen, and it can be controlled by the secondary screen control user. In manual mode, the secondary screen control user can remotely and manually control the port switch to switch ports. The operation is more convenient, and there is no need to switch programs back and forth. Auxiliary debugging and port switching and other operations can be completed through the same interface.
[0031] The network analyzer port multiplexing system also includes: an auxiliary debugging program, which is connected to the network analyzer through the control program, and is used to receive data collected by the network analyzer, generate actual measurement values according to the received data, and draw the difference between the actual measurement values and the marked values.
[0032] The effect of the above scheme is that by drawing the difference between the actual measured value and the standard value, the auxiliary debugging program can provide a more intuitive visual display (such as drawing an error curve, a scatter plot or other visual chart, or a numerical comparison, etc.), so that the debugging personnel can quickly understand the deviation between the performance of the device under test and the expected situation (such as the shape, amplitude, phase, etc. of the frequency response curve, which varies according to the different devices under test), so as to help the debugging personnel better understand the actual performance of the device under test and help locate the problem. In addition, since the auxiliary debugging program can generate actual measured values based on the data collected by the network analyzer, the network analyzer will no longer need to process the collected data, and only needs to collect data, which greatly reduces the time required for a single scan of a single device under test, widens the time difference between the network analyzer's response to a single scan of a single device under test and the human body's response, increases the upper limit of the port multiplexing that the network analyzer can perform, further improves the test efficiency of the dual-port device under test, and also further reduces the test cost.
[0033] In a further preferred embodiment, the control program is also used to control the network analyzer to scan the device under test according to a preset scanning condition;
[0034] Alternatively, the network analyzer port multiplexing system further includes: an auxiliary debugging program, and the control program is further used to control the network analyzer to scan the device under test according to a scanning instruction issued by the auxiliary debugging program.
[0035] The effect of the above scheme is that: according to the control instructions of the control program or the scanning instructions indirectly from the auxiliary debugging program, the network analyzer can automatically scan the device under test without human intervention, which greatly improves the test efficiency, especially when multiple devices under test need to be scanned continuously, saving a lot of time and human resources; at the same time, due to the automatic scanning and flexible scanning condition setting, the system can support batch testing of multiple devices under test, thereby further improving the test efficiency and reducing the test cost; moreover, the control program can flexibly set the scanning conditions (including scanning frequency range, power level, scanning step and other parameters) to meet the test requirements of different devices under test (different models or even different types), so that the system is suitable for testing a variety of devices under test, whether it is the test of frequency response curves or other performance parameters.
[0036] In a further preferred embodiment, the control program is also used to provide a manual mode, and in the manual mode, the port switch is controlled to switch to a designated port according to a port switching instruction issued by a user.
[0037] The effect of the above scheme is that: the present invention provides a manual mode through a control program, so that the user can issue a port switching instruction in the manual mode, thereby controlling the port switch to switch to the specified port, providing the user with a flexible manual control method, so that the user can select a specific port for scanning as needed; in special circumstances (such as the need to perform high-frequency continuous scanning on a specific device under test, the need to perform a separate test on a specific test frequency, the need to temporarily test multiple devices under test in a specific order, etc.), the user can operate the specific device under test or specific test requirements through the manual mode, without being restricted by the automatic scanning conditions, thereby improving the applicability and flexibility of the system, and also enabling the network analyzer port multiplexing system to effectively meet the needs of users in different test scenarios, and further improving the overall test efficiency and test flexibility of the system. This is obviously different from the prior art, and the existing RF switch module cannot achieve the purpose of customizing the test sequence or other test targets at any time for temporary needs.
[0038] In a further preferred embodiment, the control program is used to interact with the network analyzer and the port switch in an asynchronous concurrent mode;
[0039] Alternatively, the network analyzer port multiplexing system further includes: an auxiliary debugging program, and when the auxiliary debugging program issues an active control SCPI instruction to the network analyzer, the control program is used to interact with the network analyzer and the port switch in a synchronous sequential mode.
[0040] The effect of the above scheme is that: the present invention provides two hardware compositions, one does not include the auxiliary debugging program, and the other includes the auxiliary debugging program. In the case of not including the auxiliary debugging program, the control program will always interact with the network analyzer and the port switch in the asynchronous concurrent mode respectively, and in the asynchronous concurrent mode, the control program will operate independently, and can seamlessly connect to realize the testing of multiple devices under test, and realize efficient concurrent testing; in the case of including the auxiliary debugging program, the control program is still defaulted to work in the asynchronous concurrent mode (the technical effect is the same as above), but when the auxiliary debugging program sends an active control SCPI instruction, it indicates that the device under test needs to be performed (proposed by the user according to the specific situation, or sent by the auxiliary debugging program according to the specific situation, or the test of the device under test) In the event of abnormal special test requirements (or other situations) (the test meets the preset conditions), the system responds and enters the synchronous sequential mode to flexibly perform customized control and measurement, or automatically selects to enter the asynchronous concurrent mode or the synchronous sequential mode according to the instruction categories predetermined for different tasks in advance; through this setting, the system can achieve more detailed and personalized operations to meet the test requirements of the DUT in specific scenarios, so that the network analyzer port multiplexing system can adapt to various types and characteristics of DUTs, provide highly customized test solutions, and ensure the accuracy and flexibility of the test, which is obviously impossible for existing RF switch modules (RF switch modules can only switch switches in a specific order).
[0041] In a further preferred embodiment, the port switch switches to the designated port and responds to the control program after receiving the port switching instruction, and the control program controls the network analyzer to scan the corresponding device under test after receiving the response sent by the port switch.
[0042] The effect of the above scheme is that the present invention ensures the efficiency and accuracy of port switching by setting the timing of port switching. Through the response of the port switch, the control program can timely know the status of port switching, thereby ensuring the smooth progress of the test. At the same time, it also enables the network analyzer to quickly switch to different devices under test for testing, thereby realizing rapid testing and scanning of multiple devices under test, and improving the efficiency and accuracy of the test. Compared with the existing RF switch module, it is more flexible and improves the test accuracy.
[0043] In a further preferred solution, the port switch only accepts control instructions from the control program.
[0044] The effect of the above scheme is: limiting the port switch to only accept instructions from specific control programs can prevent unauthorized access and manipulation, that is, only authorized control programs can operate the port switch, which can prevent other irrelevant instructions from interfering with system operation and avoid system errors or failures caused by instructions that do not meet expectations, thereby improving the stability and reliability of the system; moreover, only allowing instructions from specific control programs to enter the port switch can simplify the design of the communication protocol, so that the port switch does not need to process instructions from other sources and can focus on communication with the control program, simplifying the complexity of the system.
[0045] In a further preferred embodiment, the control program is further used to generate a vector network message queue, and the vector network message queue is used to store instructions for controlling the network analyzer;
[0046] Alternatively, the network analyzer port multiplexing system also includes: an auxiliary debugging program; the control program is also used to generate a vector network message queue and a task message queue, the vector network message queue is used to store instructions for controlling the network analyzer, and the task message queue is used to store SCPI instructions sent by the auxiliary debugging program.
[0047] The effect of the above scheme is that: after the control program generates and puts the control instructions into the vector network message queue, these instructions are effectively cached and do not need to be executed immediately. The system can continue to process other tasks without waiting for the network analyzer to execute the current instruction before sending the next instruction, thereby saving waiting time and resources; with the setting of the asynchronous concurrent mode, the processing efficiency of the instructions is improved, and the responsiveness of the system is enhanced, so that the system can respond to new instruction requests in time without being blocked because the previous instructions have not been executed; and the existence of the vector network message queue enables the system to insert instructions into the vector network message queue in the order of the instructions. The vector network message queue will take out the instructions one by one according to the first-in-first-out principle of the queue and send them to the network analyzer for execution. This ensures the orderly execution of the instructions, avoids the confusion and disorder of the instructions, and ensures the accurate control of the network analyzer by the system. When the system includes an auxiliary debugging program, through the task message queue, the auxiliary debugging program can encapsulate multiple SCPI instructions into task messages and store them in the queue according to the priority and order of the tasks. In conjunction with the orderly execution of instructions by the vector network message queue, the working timing of the entire system is accurately guaranteed, and instructions from different sources can be processed at the same time, saving hardware resources and avoiding the waste of opening a separate port for each task. At the same time, through unified message management and control, the maintainability and scalability of the system are improved; and the control program can dynamically adjust the priority and processing order of the message queue according to actual needs, thereby achieving flexible control of the entire system.
[0048] A network analyzer port multiplexing method implemented by the network analyzer port multiplexing system as described above comprises the steps of:
[0049] The port switch is connected to the network analyzer through the radio frequency input port, connected to at least two devices under test through the radio frequency output port, and connected to the carrier computer of the control program through the communication port; the carrier computer of the control program is connected to the network analyzer through the communication port;
[0050] The control program communicates with the network analyzer and the port switch respectively and performs initialization settings;
[0051] The control program automatically obtains the single scan time of the network analyzer for each device under test set by the receiving user, controls the port switcher to cyclically switch ports according to the single scan time to realize the conduction and disconnection between the network analyzer and different devices under test, and controls the network analyzer to scan the corresponding device under test as the network analyzer and different devices under test are conducted.
[0052] The network analyzer port multiplexing method includes all the technical features of the above-mentioned network analyzer port multiplexing system, and therefore also has all the technical effects of the above-mentioned network analyzer port multiplexing system, which will not be repeated here.
[0053] A storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the steps of the network analyzer port multiplexing method described above are implemented. The storage medium includes all the technical features of the network analyzer port multiplexing method described above, and therefore also has all the technical effects of the network analyzer port multiplexing method described above, which will not be repeated here.
[0054] Compared with the prior art, the network analyzer port multiplexing system provided by the present invention uses a control program to run directly on a computer, and communicates with the network analyzer and the port switch through a carrier computer, thereby realizing port switching and data processing functions, without the need for additional computers or connection modules, greatly reducing the demand for multiple PCs, reducing costs and operational complexity; the present invention provides at least one secondary screen, which cooperates with the control program to display the data of the device under test, and has a remote control function. Through wireless or wired split-screen technology, remote or short-range control of port switching is realized, making user operation more flexible and convenient, without the need to use multiple PCs; the control program can automatically control the port switch to quickly switch to the next device under test for measurement, and utilizes the advantage that the single scan time of the network analyzer is much shorter than the reaction time of the human body to realize the simultaneous processing of multiple devices under test, thereby improving test efficiency and flexibility of use, and reducing test costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] Figure 1It is the principle block diagram of the time-division multiplexing measurement system published in 201010173329X.
[0056] Figure 2 It is a principle block diagram of a preferred embodiment of a network analyzer port multiplexing system provided by the present invention.
[0057] Figure 3 It is a flow chart of the overall control loop thread in the control program used in the present invention when performing port switching.
[0058] Figure 4 This is a flow chart of the SweepTime Timer thread in the control program used in the present invention when the port is switched.
[0059] Figure 5 It is a flow chart of the control program used in the present invention controlling the network analyzer through the main control loop thread.
[0060] Figure 6 It is a working process diagram of the VNA thread when the control program in the present invention controls the network analyzer.
[0061] Figure 7 It is a working process diagram of the SweepTimeTimer thread when the control program in the present invention controls the network analyzer.
[0062] Figure 8 It is a flow chart of task processing performed by the main control loop thread in the control program used in the present invention. DETAILED DESCRIPTION
[0063] The present invention provides a network analyzer port multiplexing system, method and storage medium. In order to make the purpose, technical solution and effect of the present invention clearer and more specific, the present invention is further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0064] The present invention provides a network analyzer port multiplexing system, such as Figure 2As shown, it includes: a port switch, a control program, a secondary screen and a control program clone; when in use, the port switch is connected to a network analyzer, at least two devices under test and a carrier computer of the control program, and the control program is connected to the network analyzer through the carrier computer; the secondary screen is a secondary screen display, which is connected to the carrier computer through a wired split screen technology (such as a DisplayPort / HDMI connection cable directly connecting the secondary screen display to the carrier computer) or a wireless split screen technology (a secondary screen display with a WiFi connection function can be connected to the carrier computer through WiFi, and a secondary screen display with a Bluetooth connection function can be connected to the carrier computer through the Bluetooth connection function). This content belongs to the prior art and is not the innovation of the present invention, and will not be described in detail here) ; The control program clone refers to a program that has the same function as the control program but is displayed on the secondary screen. This technical point is not original to the present invention. The existing technology provides a variety of mature implementation methods, such as multi-threaded implementation (creating multiple threads, each thread can achieve the same function, but process different data, such as in this application will correspond to different secondary screens, processing the test device data corresponding to the secondary screen), virtualization implementation (using virtualization technology to create an independent virtual environment to run the control program clone), containerization implementation (using containerization technology to create an isolated container to run another instance of the control program, namely the control program clone) and replication implementation and other technologies can all be implemented. The present invention does not make specific limitations on this, and can be adaptively selected and improved by those skilled in the art. It should be noted that the control program clone and the secondary screen display are bound together in a one-to-one correspondence. Even if the carrier computer is restarted, the control program clone is always displayed on its corresponding secondary screen display, unless the secondary screen display is replaced. In this case, the user (both the control user of the carrier computer and the control user of the secondary screen) needs to drag the control program clone.
[0065] The time-division multiplexing measurement system based on a vector network analyzer disclosed in 201010173329X has the following functional statistics:
[0066] 1. Multi-user sharing of vector network analyzer: This system allows multiple users to share a vector network analyzer for measurement. It includes a main control computer, a router, a radio frequency multi-way switch and a vector network analyzer. It connects multiple users' PCs through a local area network, thus realizing multi-user sharing of the vector network analyzer.
[0067] 2. Scheduling and execution of measurement instructions: The system schedules and executes measurement instructions through the main control computer. The user sends measurement instructions to the main control computer through the PC. The main control computer executes the measurement instructions in the order in the instruction pool and controls the vector network analyzer to perform corresponding measurement operations.
[0068] 3. Calibration function: The system calibrates the measurement port one by one and saves the calibration file for subsequent measurement calls to ensure the accuracy and reliability of the measurement data;
[0069] 4. Real-time data feedback: The main control computer transmits the measured data to the user PC that sends the measurement command in real time. After receiving the data, the user PC processes and displays it, completing a measurement;
[0070] 5. Different users can send remote commands to control port switching: Different users can manually control the RF multi-way switch to switch ports through different user PCs.
[0071] The network analyzer port multiplexing system provided by the present invention realizes all functions of the time-division multiplexing measurement system based on the vector network analyzer disclosed in 201010173329X on the basis of eliminating the user PC, as follows:
[0072] 1. Multi-user sharing of vector network analyzer. The present invention uses a port switcher, a carrier computer, a control program, a secondary screen display and a control program clone, so that multiple users can use the same vector network analyzer together and independently complete their respective debugging tasks. If four users need to use the same vector network analyzer to debug their respective products, user A can use the main display screen of the carrier computer to operate the control program, and use the interaction of the control program with the port switcher and the vector network analyzer to view data and send instructions to perform the required operations including manual port switching, etc. User B can use secondary screen 1, user C can use secondary screen 2, and user D can use secondary screen 3. Whether it is an external mouse and keyboard or a direct control device with a touch screen, the user A can use the secondary screen 1, user C can use secondary screen 2, and user D can use the secondary screen 3. that is, the present invention only needs a carrier computer and N-1 sub-screens (N is the number of debugging personnel, i.e., the number of users) to complete the operation of a multi-user shared vector network analyzer, and the sub-screen and the carrier computer can be connected by wire or by wireless. The wireless connection preferably uses a router as the medium of WiFi connection, and the wireless connection can be remotely controlled; while 201010173329X requires a carrier computer (i.e., the main control computer generated by the invention patent application), a router, and N user PCs; by comparison, it can be seen that the present invention saves a display and N-1 computer hosts, saves costs, and reduces the difficulty of operation and maintenance.
[0073] 2. Scheduling and execution of measurement instructions: 201010173329X schedules and executes measurement instructions through a main control computer. Users send measurement instructions to the main control computer through a PC. The main control computer executes the measurement instructions in the order in the instruction pool and controls the vector network analyzer to perform corresponding measurement operations; while the present invention schedules and executes measurement instructions through a carrier computer. Users of both the main display screen and the secondary display screen send instructions to the carrier computer through the control program or the control program clone on their respective interfaces. The carrier computer executes the measurement instructions in order and controls the vector network analyzer to perform corresponding measurement operations (this belongs to the prior art, and those skilled in the art can make adaptive selections and improvements in the prior art, which will not be described or limited in detail herein);
[0074] 3. Calibration function: Calibration is a prerequisite for the normal use of the vector network analyzer. Its purpose is to reduce the negative factors such as impedance of the cables, connectors and other accessories used for connection as much as possible. As described in 201010173329X, "the main control computer sends the first measurement instruction to the vector network analyzer, and the vector network analyzer calls the calibration file of the corresponding port to complete the calibration of the instrument", which belongs to the mature prior art. The present invention naturally has this function, which has nothing to do with the hardware used and is also irrelevant to the main invention of the present invention. It will not be described in detail here, and no specific limitation is made;
[0075] 4. Real-time data feedback: The following is a detailed description of the specific implementation method. The present invention is provided with a task processing thread, which can process the data returned by the device, such as Figure 2 As shown, the main display screen of the carrier computer displays the control program, and the task processing thread in the control program can process the data returned by the vector network analyzer and display it on the main display screen; the secondary screen display displays the control program clone, and the task processing thread in the control program clone can process the data returned by the vector network analyzer and display it on the secondary screen display. Moreover, the control program and each control program clone are preferably independently operated, and can independently complete the processing and display of their own data, and do not need to transfer and distribute data like 201010173329X, so the data processing and display speed is faster, and the debugging efficiency of the tested device is also higher; however, it should be noted that the setting of the task processing thread is not the only solution for realizing the function, and those skilled in the art can make adaptive adjustments and improvements based on the technical solution disclosed in the present invention. The present invention is only used as an example here, and is not specifically limited;
[0076] 5. Remotely send instructions by different users to control port switching: It has been clearly explained above that when the secondary screen display is connected to the carrier computer through the wireless split-screen technology, instructions can be sent remotely, and each secondary screen display is controlled by one user. Then, of course, the present invention can realize the function of "remotely send instructions by different users to control port switching".
[0077] In summary, the present invention can realize all the functions of the time-division multiplexing measurement system based on the vector network analyzer disclosed in 201010173329X without the need for a user's PC host, and belongs to an invention patent with omitted elements. Moreover, through the use of a port switch and a control program, the present invention also realizes a technical effect that 201010173329X does not have: the control program can automatically control the port switch to quickly switch to the next device under test for measurement, and by taking advantage that the single scan time of the network analyzer is much shorter than the reaction time of the human body, the simultaneous processing of multiple devices under test is realized, thereby improving the test efficiency and flexibility of use, and reducing the test cost.
[0078] As another preferred embodiment of the present invention, the present invention does not display the control program clone on the secondary screen display, but displays the auxiliary debugging program clone. The auxiliary debugging program is used to assist the debugging personnel in product debugging. By comparing the pre-stored target data with the current data of the device under test, the difference between the two is directly displayed, so that the debugging personnel can know the debugging direction more clearly, thereby reducing the debugging difficulty and improving the debugging efficiency. It should be noted that the vector network analyzer in normal use can only display the current data of the device under test, and the debugging reference basis of the debugger is the printed target data. The data of multiple rows and columns need to be manually compared one by one. The debugging difficulty and efficiency are greatly affected by the operating experience of the debugger. However, in the present invention, when the auxiliary debugging program is set, the debugger can know at a glance which data needs to be corrected and the correction direction (for example, which tuning screw of the cavity filter should be rotated and in which direction), and which data has met the requirements. Although 201010173329X realizes port multiplexing, it cannot realize the auxiliary debugging function of the device under test. That is to say, the solution of displaying the auxiliary debugging program clone on the secondary screen of the present invention not only realizes all the functions of 201010173329X while saving the user's PC host (the auxiliary debugging program clone is connected to the control program, and related instructions are sent through the control program to complete manual remote switching of ports and other operations), but also reduces the debugging difficulty of the device under test, improves the debugging efficiency of the device under test, and achieves a technical effect that is far better than 201010173329X.
[0079] Preferably, the port switch is connected to the network analyzer through the RF input port, connected to the device under test through the RF output port, and connected to the carrier computer of the control program through a communication interface (such as Ethernet interface, USB interface, GPIB interface, RS-232 interface, RS485 interface, PCI interface and PCIE interface, etc.).
[0080] The port controller is used to achieve conduction between the network analyzer and different devices under test by switching ports under the control of the control program; and the control program is used to control the port switch to switch ports according to the single scan time of the network analyzer on each device under test.
[0081] The control program is the core of the network analyzer port multiplexing system provided by the present invention. It is preferred that it can control the working timing of the hardware, control the scheduling of all tasks in the system, and provide a unique communication interface (agent) with the network analyzer; all communications related to the network analyzer in the system must be processed and forwarded by the control program.
[0082] In a further preferred embodiment of the present invention, the network analyzer port multiplexing system further includes: an auxiliary debugging program, the auxiliary debugging program is connected to the network analyzer through the control program, and is used to receive the data collected by the network analyzer, generate actual measurement values according to the received data, and draw the difference between the actual measurement values and the marked values. The auxiliary debugging program, as the name implies, is used to assist the debugging personnel in debugging the device under test. Its specific functions and implementation methods vary according to the type of the device under test. Its interaction with other parts of the system will be described in detail below and will not be described here.
[0083] In specific implementation, the control program contains the following threads:
[0084] Overall control loop thread: the main thread of the entire control program, responsible for coordinating and managing the operation of other threads, monitoring the system status and events, starting and stopping other threads as needed, and processing the core logic and tasks of the system;
[0085] VNA thread: The thread that communicates with the network analyzer is responsible for establishing a connection with the network analyzer, sending commands and receiving responses. It will continuously poll the message queue of the network analyzer to obtain scan results and process the returned data.
[0086] Port switching thread: a thread used to control the port switch, responsible for sending switching instructions to the port switch to achieve switching connections between the network analyzer and different devices under test;
[0087] TCP service thread: a thread used to establish and monitor network connections. It waits for connection requests from the auxiliary debugging program and creates a corresponding TCP connection thread to handle communication services.
[0088] TCP connection thread: a thread created for each auxiliary debugger connection, responsible for communicating with the auxiliary debugger, receiving and processing instructions and data sent by the auxiliary debugger;
[0089] Task processing thread: responsible for processing the task messages received by the control program, including distributing the task messages to the corresponding device control threads, processing the data returned by the device, updating the task status, etc.
[0090] SweepTime Timer thread: It is a timer thread responsible for periodically checking the sweep time of the network analyzer, updating the sweep time information, and triggering the corresponding task processing.
[0091] In the network analyzer port multiplexing system, each thread needs to interact and data flow to achieve coordinated work and data transmission. The following example illustrates the interaction mode and data flow between threads:
[0092] Interaction between the main control loop thread and other threads:
[0093] As the main thread, the main control loop thread is responsible for monitoring system status and events, and starting and stopping other threads as needed. Its interaction with other threads is mainly achieved through semaphores, events, or shared memory. For example, the main control loop thread may send signals to other threads to notify them to start executing specific tasks or stop running; in addition, the main control loop thread may also periodically check the status of other threads to ensure the normal operation of the system.
[0094] Interaction between VNA thread and port switching thread:
[0095] The VNA thread is responsible for communicating with the network analyzer, while the port switching thread is responsible for controlling the port switch to perform port switching. The two need to coordinate to ensure that the switching action is performed at the correct time. In automatic mode, the VNA thread will trigger the port switching thread to send a switching instruction after each scan is completed. After receiving the instruction, the port switching thread will accurately control the switching time point according to the switching frequency and the scanning time of the VNA.
[0096] Interaction between TCP service thread and TCP connection thread:
[0097] The TCP service thread is responsible for establishing and monitoring network connections, while the TCP connection thread is responsible for providing communication services for each auxiliary debugging program connection. After receiving a connection request from the auxiliary debugging program, the TCP service thread will create an independent TCP connection thread for each connection. The TCP connection thread and the TCP service thread communicate through message queues or semaphores to receive and process instructions and data sent by the auxiliary debugging program.
[0098] Interaction between the task processing thread, VNA thread, and port switching thread:
[0099] The task processing thread is responsible for processing the task messages received by the control program, which may contain instructions that need to be sent to the VNA thread and the port switching thread. The task processing thread will distribute the task messages to the corresponding device control thread (VNA thread or port switching thread) and wait for the result data returned. Once the result data is received, the task processing thread will update the task status and continue to process the next task.
[0100] Interaction between SweepTime Timer thread and task processing thread:
[0101] The SweepTime Timer thread acts as a timer thread, periodically checking the scan time of the network analyzer and triggering the corresponding task processing. Once the SweepTime Timer thread detects that the scan time has arrived, it triggers the task processing thread to perform the corresponding task, including sending switching instructions and receiving scan results. The task processing thread accurately controls the timing of port switching according to the scan time and switching frequency of the VNA to ensure that the switching action is completely synchronized with the VNA scan.
[0102] The variables in the control program of the present invention are explained as follows:
[0103] g_bARunning: Boolean variable, used to indicate whether the network analyzer is in operation. If g_bARunning is true, it means the network analyzer is in operation; if it is false, it means the network analyzer is not in operation.
[0104] SwitchFlag: Status flag, used for asynchronous interaction between threads, can have the following four states:
[0105] Idle: idle state, default state;
[0106] SendCmd: Send command status, indicating that the control program is ready to send a switching command to the port switch;
[0107] OK: The last operation was successful, indicating that the last port switching operation was completed successfully;
[0108] Fail: The last operation failed, indicating that the last port switching operation failed.
[0109] The functions in the control program of the present invention are explained as follows:
[0110] IsCurrentSweepFinish(): used to check whether the current scan is completed. If the current scan is not completed, the function returns false; if the current scan is completed, the function returns true;
[0111] Sleep(0): used to make the thread sleep for a short period of time (usually a few milliseconds). In the present invention, Sleep(0) is used to reduce the CPU occupancy rate to allow other threads to have a chance to execute.
[0112] The steps performed by the main control loop thread when switching ports are as follows (such as Figure 3 shown):
[0113] Start, then check the Switcher (i.e. port switch) connection status, if disconnected then end, if connected then check g_bARunning, if false then end and exit the thread; if true then check SwitchFlag, the status may be one of the following four: Idle - idle (default), SendCmd - send command, OK - last operation successful and Fail - last operation failed;
[0114] If the status is Idle, the function IsCurrentSweepFinish() is used to determine whether the scan is completed. If not, the process ends (entering the network control step). If yes, the process determines whether the current working mode is synchronous or asynchronous. If yes, the channel to be operated is obtained from the currently processed SCPI instruction. If yes, the next channel is obtained from the channel switching list. Then, the value of NextChannel is set, and SwitchFlag is changed to SendCmd. Then, the process determines whether the working mode is synchronous or asynchronous. If yes, the function Sleep(0) is used to reduce the CPU usage, and the Switcher connection status is rechecked. If yes, the process ends (entering the network control step).
[0115] If the status is Fail, an error is reported and the process ends (entering the network control step);
[0116] If the status is OK, then update g_currentChannel = NextChannel, and then add the SCPI command in the current task g_currentTask to the end of the network analyzer message queue; then determine whether the working mode is asynchronous mode or synchronous mode, if it is asynchronous mode, add a single scan trigger command of the current channel to the head of the network analyzer message queue, if it is synchronous mode, add a single scan trigger command of the current channel to the end of the network analyzer message queue; then set the new value of SwitchFlag to Idle, and then end (enter the network control step);
[0117] If the status is SendCmd, determine whether the current working mode is asynchronous mode or synchronous mode. If it is asynchronous mode, end (enter the network control step). If it is synchronous mode, reduce the CPU usage through the function Sleep(0) and recheck the Switcher connection status.
[0118] The present invention realizes the automated interaction between the port switch and the network analyzer through the master control loop thread, achieving the purpose of port multiplexing and automated testing; the master control loop thread dynamically switches ports according to different working modes (synchronous or asynchronous) and scanning states, connects the network analyzer to different devices under test, and realizes the automation of port switching; at the same time, the network analyzer is controlled to scan the device under test according to the preset scanning conditions; when the system supports asynchronous concurrent mode, the concurrent performance and resource utilization of the system are improved by reducing the CPU occupancy rate and reasonable message queue processing. In addition, the system can also judge whether the operation is successful based on the response result of the port switch to ensure the accuracy and stability of the switching; on the whole, the present invention realizes efficient and stable automated testing, and provides good technical support for the reliability and availability of the port multiplexing function of the network analyzer.
[0119] Channel single scan trigger command: It is a command used to trigger the network analyzer to perform a single scan. It is preferred to use only SCPI trigger commands that return immediately without waiting for the scan to complete. This means that after the control program sends the trigger command, it will immediately proceed to the next step without waiting for the scan result to be returned.
[0120] The above content describes the interaction process between the main control loop thread and the port switch, which realizes the switching of ports through control instructions, realizes the dynamic connection between the network analyzer and different devices under test, and thus realizes port multiplexing and automated testing functions.
[0121] The SweepTime Timer thread will execute steps (such as Figure 4 shown):
[0122] Check the connection status between the control program and the port switch to determine if the communication link is successfully established:
[0123] If the connection is successful, proceed to the next step;
[0124] If the connection fails, check g_bRunning to determine whether it is true or false. If it is false, end the process. If it is true, use the Sleep(0) function to reduce CPU usage and recheck whether the connection is successful.
[0125] Check SwitchFlag to determine whether it is SendCmd:
[0126] If SwitchFlag is SendCmd, it means that the main thread requests port switching, and needs to read the next channel port and generate corresponding instructions to send to the port switch;
[0127] If SwitchFlag is not SendCmd, check g_bRunning to determine whether it is true or false. If it is false, end the process. If it is true, use the Sleep(0) function to reduce CPU usage, recheck SwitchFlag, and re-determine whether it is SendCmd.
[0128] The SW thread uses a blocking method to wait for the response from the port switch and sets a reasonable timeout to prevent the waste of resources caused by long-term waiting of the thread. Once the response from the port switch is received, the SW thread will analyze and process the response;
[0129] Based on the response from the port switch, determine whether the port switching operation is successful or a timeout occurs:
[0130] If the operation is successful, then change SwitchFlag to OK, then check g_bRunning to determine whether it is true or false. If it is false, end the process. If it is true, use the Sleep(0) function to reduce CPU usage, recheck SwitchFlag, and re-determine whether it is SendCmd.
[0131] If it times out or fails, the SwitchFlag is changed to Fail.
[0132] The execution steps of the SweepTime Timer thread during port switching realize the inspection and establishment of the communication connection between the port switcher and the control program, ensuring that the port switching operation is performed after the communication is normal; by judging the SwitchFlag status, the response to the main thread request for port switching is realized, the next channel port is read and the corresponding instructions are generated and sent to the port switcher. The SW thread uses a blocking method to wait for the response of the port switcher and sets a reasonable timeout time to effectively prevent the waste of thread resources; once the response of the port switcher is received, the SW thread analyzes and processes the response to determine whether the port switching operation is successful or timed out. If the operation is successful, SwitchFlag is changed to OK, and whether to continue processing the port switching request is determined according to the status of g_bRunning. If g_bRunning is false, the process is terminated. If it is true, the SwitchFlag is rechecked to see if it is SendCmd; if the port switching operation times out or fails, SwitchFlag is changed to Fail, prompting the control program to perform corresponding processing. Overall, this process realizes an efficient and stable port switching process, can respond to and process port switching requests in a timely manner, and effectively avoids resource waste and operation failures, thereby improving the availability and stability of the system. The main function of the SW thread is to control the operation of the port switch according to the instructions sent by the main thread, and interact with the network analyzer to achieve port switching and scanning of the device under test.
[0133] Assume that the port switch is connected to the DUT 1 through the RF output ports P1P2, and to the DUT 2 through the RF output port, and is connected to the port Port1 of the network analyzer through the RF input port IN1, and is connected to the port Port2 of the network analyzer through the RF input port IN2, and is connected and controlled through LAN (Local Area Network, local area network) or USB (Universal Serial Bus, universal serial bus); and the control program is initialized, and all preparations for the DUT test and port switching have been completed. Then in the automatic mode, the port switching process of the network analyzer port multiplexing system can be (the single scan time of the network analyzer for the DUT 1 and the DUT 2 has been automatically acquired or set by the user, set to 60ms and 70ms respectively, and the port switching frequency is manually set to 100ms):
[0134] Initial state: At the beginning, the RF output port P1P2 of the port switch is connected to the device under test 1, completing the initial connection (i.e., the network analyzer and the device under test 1 are connected);
[0135] DUT 1 test: The network analyzer scans DUT 1 and sends the scan and processing results to the control program;
[0136] Switch connection: When 100ms is reached, the control program sends a switching command to the port switch to close the RF output ports P1 and P2, and open the RF output ports P3 and P4 (disconnecting the connection between the device under test 1 and the network analyzer, and connecting the connection between the device under test 2 and the network analyzer), thus realizing the switching of the port connection;
[0137] DUT 2 test: After the switching is completed, the network analyzer scans DUT 2 and sends the scan and processing results to the control program;
[0138] Cyclic switching: Subsequently, the control program will continue to cycle the port switching process according to the switching frequency, that is, automatically switch the port connection every 100ms.
[0139] It should be noted that the above data and related settings are only used to illustrate a specific implementation process of the present invention and are not intended to limit the specific usage of the present invention.
[0140] It can be seen from the description of the above steps that the port switch in the present invention is completely different from the traditional RF switch. The traditional RF switch does not have the ability to communicate directly with the control program, and the signal is turned on and off by physical electrical signals or manual control, which means that it cannot accept instructions or commands from the control program.
[0141] In a further preferred embodiment, the control program is also used to control the network analyzer to scan the device under test according to a preset scanning condition;
[0142] Alternatively, the network analyzer port multiplexing system further includes: an auxiliary debugging program, and the control program is further used to control the network analyzer to scan the device under test according to a scanning instruction issued by the auxiliary debugging program.
[0143] In specific implementation, the control program can perform the following operations through the overall control loop to control the network analyzer (such as Figure 5 shown):
[0144] Start execution and check the connection status with the network analyzer. If the connection fails, it ends directly (enters the task processing step). If the connection is successful, it proceeds to the next step.
[0145] Next, check whether the SweepTime Timer has been created. If the SweepTime Timer has not been created, create a SweepTime Timer. If the SweepTime Timer has been created, proceed to the next step.
[0146] Then, check whether there is a message in the network analyzer message queue. If there is no message, process the result of the SweepTime message, update g_sweepTime, and clear g_sweepTimeMsg, then end and enter the task processing step;
[0147] If there is a message in the network analyzer message queue, the CPU usage is reduced through the Sleep(0) function, and the value of the variable g_bRunning is checked. If g_bRunning is false, the thread is terminated and exited. If g_bRunning is true, the network analyzer message queue is rechecked to see if there is a message, thereby continuing the loop.
[0148] The above process implements the main steps of controlling the network analyzer in the main control loop thread: first, it starts to execute and check the connection status with the network analyzer. If the connection fails, it ends directly and enters the task processing step to ensure the normal communication with the network analyzer; if the connection is successful, it then checks whether the SweepTime Timer has been created. If not, it creates a SweepTime Timer, if it has been created, it continues to the next step to ensure the preparation of SweepTimeTimer; then, it checks whether there is a message in the network analyzer message queue. If there is no message, it processes the result of the SweepTime message, updates g_sweepTime and clears g_sweepTimeMsg, then ends and enters the task processing step, realizing the processing of the sweep time and data update; if there is a message in the network analyzer message queue, the CPU occupancy rate is reduced through the function Sleep(0), and the value of the variable g_bRunning is checked. If g_bRunning is false, the thread is ended and exited to ensure the timely termination of the thread in the non-running state; if g_bRunning is true, it rechecks whether there is a message in the network analyzer message queue, so as to continue the execution loop and keep the thread working continuously. Overall, this process effectively manages the connection status and message queue of the network analyzer, ensures effective communication with the network analyzer, and optimizes resources when necessary, improving the stability and performance of the system. At the same time, it can process the data related to the sweep time in a timely manner, ensure the accuracy and consistency of the data, and provide a basis for subsequent task processing. The above content describes the main steps of controlling the vector network analyzer in the master control loop, including connection status check, creation of SweepTime Timer and processing of message queue. During the execution process, it will decide whether to proceed to the next step based on the condition judgment, and reduce the CPU usage when necessary to optimize the system performance.
[0149] When controlling the network analyzer, the operations performed by the VNA thread are (such as Figure 6 shown):
[0150] First, the connection status with the network analyzer is checked. If the connection fails, the value of g_bARunning is checked. If g_bARunning is true, the function Sleep(0) is used to reduce the CPU usage, and the connection status with the network analyzer is checked again (to ensure that the connection is continuously attempted when the network analyzer is running). If g_bARunning is false, the thread is terminated (to ensure that the thread is terminated in time when it is not running).
[0151] If the connection is successful, the network analyzer message queue will continue to be checked for messages. If there are no messages, the value of g_bARunning will also be checked. If g_bARunning is true, the CPU usage will be reduced by Sleep(0), and the network analyzer message queue will be checked again for messages (to keep the thread working continuously). If g_bARunning is false, the thread will be terminated (to ensure timely termination of the thread in the non-running state).
[0152] If there is a message in the network analyzer message queue, a message will be taken out and all SCPI commands in the message will be sent to the network analyzer; then it will be determined whether the sent SCPI command contains a query command. If not, the result part in the message data structure will be kept empty and the message status will be changed to processed; then the value of g_bRunning will be checked. If g_bRunning is false, the thread will be terminated (to ensure timely termination of the thread in the non-running state); if g_bRunning is true, the network analyzer message queue will be rechecked to see if there is a message, so as to continue the loop (to keep the thread working continuously);
[0153] If the SCPI command sent contains a query command, the query result will be read from the network analyzer and all returned data will be written into the result part of the message data structure. Then the message status will be changed to processed and the value of g_bRunning will be checked. If g_bRunning is false, the thread will be terminated. If g_bRunning is true, the network analyzer message queue will be rechecked to see if there is any message, thus continuing the loop.
[0154] The above process effectively manages the connection status and message queue with the network analyzer, and realizes the interactive process of sending instructions to the network analyzer and processing query results; at the same time, through reasonable CPU occupancy optimization and checking the g_bRunning variable, it ensures the timely response and termination of threads in different situations, improving the stability and resource utilization of the system. Overall, this process realizes efficient communication and data interaction with the network analyzer, providing a basis for subsequent task processing.
[0155] When controlling the network analyzer, the SweepTime Timer thread executes the following steps: Figure 7 shown):
[0156] After the execution starts, the connection status with the network analyzer will be checked first. If the connection fails, the process ends directly (ensuring that the thread is terminated in time if the connection with the network analyzer cannot be established); if the connection is successful, the process continues to check whether g_sweepTimeMsg is empty. If g_sweepTimeMsg is not empty, it means that the SweepTime message has been generated and does not need to be generated again, so the process ends directly (ensuring that the same SweepTime message will not be repeatedly generated and sent if the sweep time does not need to be adjusted);
[0157] If g_sweepTimeMsg is empty, a new SweepTime message is generated and assigned to g_sweepTimeMsg; then, the pointer of g_sweepTimeMsg is added to the end of the network analyzer message queue so that the network analyzer can receive the message, and then the process ends (ensuring that when the sweep time needs to be adjusted, a new SweepTime message can be generated and sent to the network analyzer in time to control its sweep time).
[0158] The above process realizes the control of the network analyzer's sweep time. By generating and sending SweepTime messages, the network analyzer can scan the device under test according to the preset sweep time. At the same time, by checking the connection status and the value of g_sweepTimeMsg, the accurate generation and sending of messages is ensured, avoiding repeated sending of the same message or wasting resources when the connection cannot be established. Overall, the role of SweepTime Timer is to optimize the sweep control of the network analyzer and realize flexible adjustment of the sweep time, thereby improving the test efficiency and stability of the system.
[0159] Preferably, the control program is also used to provide a manual mode, and in the manual mode, the port switch is controlled to switch to a specified port according to a port switching instruction issued by a user. Specifically, in the manual mode, the control program provides a command line test function, displays a port quick switch button on the carrier computer, and puts the overall control loop in an idle state.
[0160] Furthermore, the control program is used to interact with the network analyzer and the port switch in an asynchronous concurrent mode; or, the network analyzer port multiplexing system also includes: an auxiliary debugging program, when the auxiliary debugging program issues an active control SCPI instruction to the network analyzer, the control program is used to interact with the network analyzer and the port switch in a synchronous sequential mode.
[0161] Preferably, the port switch switches to the designated port and responds to the control program after receiving the port switching instruction, and the control program controls the network analyzer to scan the corresponding device under test after receiving the response sent by the port switch; and the port switch only accepts control instructions from the control program.
[0162] The port switch communication protocol is used to communicate with the control program, open and close the port by sending commands, and confirm whether the operation is successful by responding to the command. It is particularly important to note that in the response to the port switching command, you must wait for the switching operation to be completely completed and ensure that the RF circuit is fully connected and available before responding to ensure accurate port switching.
[0163] Furthermore, the control program is also used to generate a vector network message queue, and the vector network message queue is used to store instructions for controlling the network analyzer;
[0164] Alternatively, the network analyzer port multiplexing system also includes: an auxiliary debugging program; the control program is also used to generate a vector network message queue and a task message queue, the vector network message queue is used to store instructions for controlling the network analyzer, and the task message queue is used to store SCPI instructions sent by the auxiliary debugging program.
[0165] When the master control loop is processing tasks (process as follows Figure 8As shown), the completed task message will be taken out from the task message queue, and the message will be passed to the corresponding TCP connection thread according to the source ID to send the result data to the client (ensuring that the task result can be delivered to the client in time, achieving timely response and high efficiency of data transmission). Then check whether the task message queue is empty. If not, continue to process the next task message (ensuring the continuous execution of tasks and the real-time response of the task queue, thereby improving the processing efficiency of tasks and the real-time performance of the system). When processing task messages, all SCPI instructions contained in the task message will be split, and it will be determined whether control messages are included according to the instruction type. If control instructions are included, switch to synchronous mode and check whether g_bRunning is true. If true, continue to process the task. If false, end task processing and wait for new tasks. If no control instructions are included, switch to asynchronous mode and perform the same g_bRunning check (this process design allows different processing modes to be selected under different instruction types, and flexible control of task processing is performed according to the status of g_bRunning). If g_bRunning is true, continue to process the task, otherwise end task processing and exit the thread. The whole process will continue to loop, waiting for new tasks to arrive and process them.
[0166] The loop processing mechanism of the master control loop enables the system to continuously process new tasks and optimize and adjust according to different instruction types and execution states, ensuring the efficiency of task execution and the stability of the system. Overall, the setting of this process realizes efficient task processing and flexible control of task execution status, thereby improving the system's task processing capability and performance.
[0167] The present invention also provides a network analyzer port multiplexing method implemented by the network analyzer port multiplexing system as described above, which comprises the steps of:
[0168] The port switch is connected to the network analyzer through the radio frequency input port, connected to at least two devices under test through the radio frequency output port, and connected to the carrier computer of the control program through the communication port; the carrier computer of the control program is connected to the network analyzer through the communication port;
[0169] The control program communicates with the network analyzer and the port switch respectively and performs initialization settings;
[0170] The control program automatically obtains the single scan time of the network analyzer for each device under test set by the receiving user, controls the port switcher to cyclically switch ports according to the single scan time to realize the conduction and disconnection between the network analyzer and different devices under test, and controls the network analyzer to scan the corresponding device under test as the network analyzer and different devices under test are conducted.
[0171] The network analyzer port multiplexing method includes all the technical features of the above-mentioned network analyzer port multiplexing system, and therefore also has all the technical effects of the above-mentioned network analyzer port multiplexing system, which will not be repeated here.
[0172] The present invention also provides a storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the steps of the network analyzer port multiplexing method described above are implemented. The storage medium includes all the technical features of the network analyzer port multiplexing method described above, and therefore also has all the technical effects of the network analyzer port multiplexing method described above, which will not be described in detail.
[0173] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing related hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided by the present invention may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (SyNchliNk) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0174] The algorithm or display provided herein is not inherently related to any particular computer, virtual system or other equipment. Various general purpose systems can also be used together with the teachings based on this. According to the above description, it is obvious to construct the structure required for this type of system. In addition, the embodiment of the present invention is not directed to any specific programming language yet. It should be understood that various programming languages can be utilized to realize the content of the present invention described herein, and the description made to specific languages above is for disclosing the best mode of the present invention.
[0175] In the description provided herein, a large number of specific details are described. However, it is understood that embodiments of the present invention can be practiced without these specific details. In some instances, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this description.
[0176] Similarly, it should be understood that in order to streamline the present invention and aid in understanding one or more of the various inventive aspects, in the above description of exemplary embodiments of the present invention, the various features of the embodiments of the present invention are sometimes grouped together into a single embodiment, figure, or description thereof. However, this disclosed method should not be interpreted as reflecting the following intention: that the claimed invention requires more features than the features explicitly recited in each claim. More specifically, as reflected in the claims below, inventive aspects lie in less than all the features of the individual embodiments disclosed above. Therefore, the claims that follow the specific embodiment are hereby expressly incorporated into the specific embodiment, with each claim itself serving as a separate embodiment of the present invention.
[0177] Those skilled in the art will appreciate that the modules in the devices in the embodiments may be adaptively changed and arranged in one or more devices different from the embodiments. The modules or units or components in the embodiments may be combined into one module or unit or component, and in addition they may be divided into a plurality of submodules or subunits or subcomponents. Except that at least some of such features and / or processes or units are mutually exclusive, all features disclosed in this specification (including the accompanying claims, abstracts and drawings) and all processes or units of any method or device disclosed in this manner may be combined in any combination. Unless otherwise expressly stated, each feature disclosed in this specification (including the accompanying claims, abstracts and drawings) may be replaced by an alternative feature providing the same, equivalent or similar purpose.
[0178] In addition, those skilled in the art will appreciate that, although some embodiments herein include certain features included in other embodiments but not other features, the combination of features of different embodiments is meant to be within the scope of the present invention and form different embodiments. For example, any one of the claimed embodiments may be used in any combination.
[0179] It should be noted that the above embodiments illustrate the present invention rather than limit it, and that those skilled in the art may devise alternative embodiments without departing from the scope of the appended claims. In the claims, any reference symbol between brackets shall not be construed as a limitation on the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" preceding an element does not exclude the presence of a plurality of such elements. The present invention may be implemented by means of hardware comprising a number of different elements and by means of a suitably programmed computer. In a unit claim enumerating a number of devices, several of these devices may be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names. The steps in the above embodiments, unless otherwise specified, should not be understood as limitations on the order of execution.
Claims
1. A network analyzer port multiplexing system, characterized in that: include: A port switch, the port switch is used to connect the network analyzer and at least two devices under test, and realize the connection and disconnection between the network analyzer and the devices under test by switching ports; A control program, the control program is used to run on a computer and communicate with the network analyzer and the port switch through a carrier computer, and is also used to control the port switch to perform port switching according to a single scan time of the device under test by the network analyzer; At least one secondary screen, which shares a host with the primary screen on the carrier computer and is connected to the carrier computer via a wired screen expansion technology or a wireless screen expansion technology, and is used to display data of the corresponding device under test; A control program clone runs on the carrier computer and is displayed on the secondary screen, and is used to receive manipulations from the secondary screen control user. In manual mode, the secondary screen control user remotely and manually controls the port switch to perform port switching.
2. The network analyzer port multiplexing system according to claim 1, characterized in that: The network analyzer port multiplexing system includes: an auxiliary debugging program, the control program clone is replaced by the auxiliary debugging program clone, the auxiliary debugging program clone is used to receive the control of the secondary screen control user, and in manual mode, the secondary screen control user remotely and manually controls the port switch to switch ports.
3. The network analyzer port multiplexing system according to claim 1 or 2, characterized in that: The network analyzer port multiplexing system also includes: an auxiliary debugging program, which is connected to the network analyzer through the control program, and is used to receive data collected by the network analyzer, generate actual measurement values according to the received data, and draw the difference between the actual measurement values and the marked values.
4. The network analyzer port multiplexing system according to claim 1 or 2, characterized in that: The control program is also used to control the network analyzer to scan the device under test according to the preset scanning conditions; Alternatively, the network analyzer port multiplexing system further includes: an auxiliary debugging program, and the control program is further used to control the network analyzer to scan the device under test according to a scanning instruction issued by the auxiliary debugging program.
5. The network analyzer port multiplexing system according to claim 1 or 2, characterized in that: The control program is also used to provide a manual mode, and in the manual mode, control the port switch to switch to a designated port according to a port switching instruction issued by a user.
6. The network analyzer port multiplexing system according to claim 1 or 2, characterized in that: The control program is used to interact with the network analyzer and the port switch in an asynchronous concurrent mode; Alternatively, the network analyzer port multiplexing system further includes: an auxiliary debugging program, and when the auxiliary debugging program issues an active control SCPI instruction to the network analyzer, the control program is used to interact with the network analyzer and the port switch in a synchronous sequential mode.
7. The network analyzer port multiplexing system according to claim 1 or 2, characterized in that: The port switch switches to the designated port and responds to the control program after receiving the port switching instruction. The control program controls the network analyzer to scan the corresponding device under test after receiving the response sent by the port switch.
8. The network analyzer port multiplexing system according to claim 1 or 2, characterized in that: The control program is also used to generate a vector network message queue, and the vector network message queue is used to store instructions for controlling the network analyzer; alternatively, the network analyzer port multiplexing system also includes: an auxiliary debugging program; the control program is also used to generate a vector network message queue and a task message queue, and the vector network message queue is used to store instructions for controlling the network analyzer, and the task message queue is used to store SCPI instructions sent by the auxiliary debugging program.
9. A network analyzer port multiplexing method implemented by the network analyzer port multiplexing system according to any one of claims 1 to 8, characterized in that: Includes steps: The port switch is connected to the network analyzer through the radio frequency input port, connected to at least two devices under test through the radio frequency output port, and connected to the carrier computer of the control program through the communication port; the carrier computer of the control program is connected to the network analyzer through the communication port; The control program communicates with the network analyzer and the port switch respectively and performs initialization settings; The control program automatically obtains the single scan time of the network analyzer for each device under test set by the receiving user, controls the port switcher to cyclically switch ports according to the single scan time to realize the conduction and disconnection between the network analyzer and different devices under test, and controls the network analyzer to scan the corresponding device under test as the network analyzer and different devices under test are conducted.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the network analyzer port multiplexing method according to claim 9 are implemented.
