Method and apparatus for conformance testing of single pair wire communication
By automatically identifying the protocol type of a single-to-line communication device and generating a dynamic test flow, the inefficiency and misjudgment problems caused by manual configuration of protocols in the existing test methods are solved, and efficient and accurate device consistency testing is achieved.
Patent Information
- Application Number
- CN202510610578.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-13
- Publication Date
- 2025-08-01
- Estimated Expiration
- 2045-05-13
AI Technical Summary
The existing single-to-line communication equipment consistency testing methods rely on manual configuration of protocol types, resulting in long test cycles, high labor costs and prone to missed detection or misjudgment, especially in the hybrid protocol scenarios.
By receiving the communication signals of the device under test, extracting time domain, frequency domain and modulation features, generating protocol feature vectors, and automatically identifying protocol types using predefined mapping dictionary and machine learning models, dynamically generate a consistency test flow, including signal injection parameters, test timing configuration and adaptive judgment thresholds, to realize automated testing.
Improve testing efficiency, reduce human misoperation, ensure the accuracy and consistency of testing, and adapt to the complexity of different equipment and environments.
Smart Images

Figure CN120128515B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of equipment testing, and in particular to a method and apparatus for consistency testing of single-pair communication. Background Art
[0002] With the rapid development of technologies like industrial automation and the Internet of Things, demand for testing communication interfaces across various devices continues to grow. Testing equipment supporting single-pair connections is gaining widespread adoption in in-vehicle networks (such as the CAN / LIN bus), industrial control (such as RS-485), and smart sensors due to its simplified wiring, strong interference resistance, and cost advantages. These devices can simultaneously transmit data and provide power over a single pair of wires, significantly simplifying system architecture and becoming an indispensable component of modern communications systems.
[0003] However, existing conformance test equipment has significant limitations when testing devices that utilize single-pair communication. Current mainstream testing solutions typically rely on manually pre-setting the communication protocol type (such as Profibus) for the device under test and manually configuring test case parameters based on the pre-set protocol. This approach not only requires testers to possess multi-protocol expertise but also requires repeated debugging of test scripts to adapt to different devices. This results in long testing cycles, high labor costs, and the risk of missed detections or misjudgments due to human error. For example, in mixed-protocol scenarios, test equipment cannot automatically identify the protocol type, requiring protocol adaptation through physical jumpers or software switching, further reducing test efficiency.
[0004] In response to the above problems, how to achieve automated and intelligent testing of single-pair communication equipment has become a key issue that the industry urgently needs to solve. Summary of the Invention
[0005] To solve the existing technical problems, the present application provides a method and apparatus for consistency testing of single-pair communication.
[0006] In a first aspect, an embodiment of the present application provides a method for consistency testing of single-pair communication, comprising:
[0007] Receive the communication signal sent by the device under test, extract the time domain characteristics, frequency domain characteristics and modulation characteristics of the communication signal, generate protocol feature values, and perform dimensionality reduction processing on the time domain characteristics, frequency domain characteristics and modulation characteristics to generate a protocol feature vector;
[0008] Analyze the matching degree between the protocol feature vector and the predefined mapping dictionary to determine the target communication protocol type with the highest matching degree. The mapping dictionary is generated based on the protocol standard feature library and machine learning model training.
[0009] Based on a determined communication protocol, dynamically generate a conformance test stream through a pre-trained neural network model. The test stream includes signal injection parameters, test timing configuration, and adaptive decision thresholds.
[0010] Configure a signal generator to inject an excitation signal according to the test stream, and synchronously collect the physical layer response, link layer frame structure, and power layer parameters of the device under test.
[0011] Based on real-time feedback data, dynamically adjust the signal amplitude, frequency, and decision threshold through a pre-trained neural network model.
[0012] Summarize the feedback data from multiple rounds of tests to generate a test report containing conformance metrics for the physical layer, link layer, and power layer.
[0013] Optionally, the target communication protocol types include industrial fieldbus protocols, industrial Ethernet protocols, or a combination thereof. Among them, industrial fieldbus protocols include at least one of those using single-pair communication such as 4 - 20mA + HART, Profibus, CAN, and Foundation Fieldbus. Industrial Ethernet protocols include at least one of the protocols in the IEEE 802.3cg series that support single-pair.
[0014] Optionally, the dimensionality reduction processing includes:
[0015] Perform normalization processing on time-domain features to eliminate the differences in signal amplitude and time reference.
[0016] Perform band-pass filtering and power spectral density calibration on frequency-domain features.
[0017] Perform carrier frequency offset compensation and noise suppression on modulation features.
[0018] Optionally, the matching degree analysis includes:
[0019] Calculate the similarity between the standardized protocol feature vector and each protocol feature vector in the mapping dictionary based on the Euclidean distance.
[0020] Rank the candidate protocols with similarity higher than a preset threshold.
[0021] Combine the protocol application scenario context information to select the final target communication protocol type.
[0022] Optionally, the neural network model is trained through supervised learning. The training data includes historical protocol test data sets, device model libraries, and environmental noise samples. The output of the model is the test stream parameter optimization strategy and the decision threshold adaptation rule.
[0023] Optionally, dynamically adjusting the signal amplitude, frequency, and decision threshold through a pre-trained neural network model specifically includes:
[0024] Define a test objective function, which includes a weighted combination of test accuracy, time consumption, and energy consumption;
[0025] Iteratively update the signal injection parameters through the Q-learning algorithm to maximize the objective function.
[0026] Optionally, the conformance test includes physical layer protocol test, link layer protocol test, and power supply layer protocol test.
[0027] Optionally, the physical layer protocol test includes transmitter output voltage, transmitter output droop rate, transmitter timing jitter, transmitter power spectral density, transmit clock frequency, transmit signal distortion, and receive bit error rate stress test.
[0028] Optionally, the link layer protocol test includes packet format verification, automatic polarity detection and correction, ESD_ERR4 error handling, FCS error handling, auto-negotiation verification, management restart auto-negotiation, link state failure detection, and link establishment time.
[0029] Optionally, the power supply layer protocol test includes minimum current consumption, inrush current, in-band ripple noise, out-of-band ripple noise, current change rate, maximum / minimum load voltage event, under-voltage protection, shielding option, and polarity sensitivity.
[0030] Optionally, the time-domain characteristics include:
[0031] Peak-to-peak output voltage and voltage drift rate;
[0032] Linearity of the rising / falling edge of the signal waveform;
[0033] Standard deviation of time jitter within the transmission symbol period;
[0034] The frequency-domain characteristics include:
[0035] Fundamental frequency power spectral density and harmonic attenuation slope;
[0036] Spectrum mask compliance of out-of-band noise;
[0037] The modulation characteristics include:
[0038] Carrier clock frequency offset;<L
[0039] Distribution characteristics of the signal pre-emphasis coefficient.
[0040] In a second aspect, an embodiment of the present application provides a device for conformance testing of single-pair communication, including the following modules:
[0041] A feature extraction module, configured to be connected by a single pair of wires and receive the communication signals of the device under test, extract the time-domain features, frequency-domain features, and modulation features of the communication signals, and perform dimensionality reduction processing on the features to generate protocol feature vectors;
[0042] A protocol recognition module, configured to perform a matching degree analysis on the protocol feature vectors and a predefined mapping dictionary to determine the target communication protocol type with the highest matching degree, where the mapping dictionary is generated based on a protocol standard feature library and machine learning model training;
[0043] A test flow generation module, configured to dynamically generate a conformance test flow based on the determined communication protocol through a pre-trained neural network model, where the test flow includes signal injection parameters, test timing configuration, and an adaptive decision threshold;
[0044] A test execution module, configured to configure a signal generator to inject an excitation signal according to the test flow, synchronously collect the physical layer response, link layer frame structure, and power supply layer parameters of the device under test, and dynamically adjust the signal amplitude, frequency, and decision threshold based on real-time feedback data through a pre-trained neural network model;
[0045] A report generation module, configured to summarize the feedback data of multiple rounds of tests and generate a test report including physical layer, link layer, and power supply layer conformance metrics.
[0046] In the technical solution of this application, by extracting the features of the communication signals of the device under test and generating feature vectors, the protocol type of the device under test is identified, and a test flow for the device under test is dynamically generated in a targeted manner according to the protocol type, which can effectively realize the automatic identification and automatic testing of the device, and effectively improve the work efficiency of testers. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] In order to more clearly illustrate the technical solutions in the embodiments of this application or the background art, the following will describe the drawings required to be used in the embodiments of this application or the background art.
[0048] Figure 1 Shows a schematic structural diagram of a single pair of wires provided by an embodiment of this application.
[0049] Figure 2 Shows a flowchart of a method for conformance testing for single-pair wire communication provided by an embodiment of this application.
[0050] Figure 3 Shows a flowchart of a method for matching degree analysis of protocol feature vectors and a mapping dictionary provided by an embodiment of this application.
[0051] Figure 4 Shows a flowchart of a dimensionality reduction processing method provided by an embodiment of this application.
[0052] Figure 5 The flowchart of the matching degree analysis method provided by the embodiments of the present application is shown. [[ID=4]]
[0053] Figure 6 The structural schematic diagram of the device for consistency test for single pair wire communication provided by the embodiments of the present application is shown.
[0054] Figure 7 The signaling diagram of the specific process of the device for consistency test for single pair wire communication provided by the embodiments of the present application is shown. Specific embodiments
[0055] In the description of the embodiments of the present invention, those skilled in the art should know that the embodiments of the present invention can be implemented as a method or a device. Therefore, the embodiments of the present invention can be specifically implemented in the following forms: complete hardware, complete software (including firmware, resident software, microcode, etc.), and a combination of hardware and software.
[0056] The methods and devices provided by the embodiments of the present invention are described by flowcharts and / or block diagrams.
[0057] It should be understood that each block of the flowchart and / or block diagram, as well as the combination of blocks in the flowchart and / or block diagram, can be implemented by computer-readable program instructions. These computer-readable program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, or other programmable data processing devices, thereby producing a machine. These computer-readable program instructions are executed by a computer or other programmable data processing devices, resulting in a device that implements the functions / operations specified in the blocks of the flowchart and / or block diagram.
[0058] These computer-readable program instructions can also be stored in a computer-readable storage medium that can cause a computer or other programmable data processing device to work in a specific manner. In this way, the instructions stored in the computer-readable storage medium produce an instruction device product that includes the instructions for implementing the functions / operations specified in the blocks of the flowchart and / or block diagram.
[0059] The computer-readable program instructions can also be loaded onto a computer, other programmable data processing device, or other device, so that a series of operation steps are executed on the computer, other programmable data processing device, or other device, resulting in a computer-implemented process. Thus, the instructions executed on the computer or other programmable data processing device can provide a process for implementing the functions / operations specified in the blocks of the flowchart and / or block diagram.
[0060] A single pair cable (SPC) is a transmission medium consisting of only a pair of wires, usually used to simultaneously carry data communication and low-power power supply. AsFigure 1 As shown in the figure, its basic structure consists of two insulated conductors twisted together, one for data transmission and the other for powering the device. The outer layer can be covered with a shielding layer to suppress electromagnetic interference, and some designs also include a protective sleeve to enhance mechanical strength. The conductor material of a single-pair cable is mostly copper or copper alloy to ensure good conductivity, while the insulation layer is often made of polymer materials such as polyethylene (PE) or polypropylene (PP) to balance dielectric loss and flexibility. In industrial scenarios, single-pair cables usually meet strict anti-interference standards. For example, a double-layer shielding structure of metal foil shielding (such as aluminum foil) and braided mesh is used to meet the stability requirements in harsh environments.
[0061] In existing technologies, the application of single-pair cables is primarily concentrated in industrial automation, automotive electronics, and the Internet of Things (IoT). For example, industrial communication protocols such as HART (Highway Addressable Remote Transducer) use a single pair of cables to transmit both 4-20mA analog and digital signals, enabling bidirectional communication in process control instruments. Profibus PA and Foundation Fieldbus H1 utilize a single pair of cables to transmit data and power in intrinsically safe (Ex i) environments, simplifying wiring in hazardous areas. In recent years, the 10BASE-T1L Ethernet technology defined by the IEEE 802.3cg standard has further expanded the capabilities of single-pair cables, supporting transmission distances of up to 1 km at 10Mbps and providing up to 52W of power (PoDL) over the same cable, making it a key technology for connecting sensors and actuators in the Industrial Internet of Things (IIoT).
[0062] The core reasons for the widespread adoption of single-pair cabling lie in its economical efficiency and technical adaptability. First, compared to traditional multi-pair cables (such as four-pair twisted-pair cables), single-pair cabling reduces the number of conductors, reducing cabling costs and wiring space by over 60%, significantly saving installation and maintenance costs in large industrial facilities or automotive wiring harnesses. Second, its support for long-distance transmission and mixed signal (data + power) distribution addresses the challenge of distributed power supply for industrial field sensors. For example, in oil refineries, a single-pair cabling can power remote instruments and transmit data in explosion-proof areas, eliminating the need for additional power lines. Furthermore, advances in anti-interference design (such as differential signaling and shielding optimization) ensure stable communication in factories with complex electromagnetic environments. The promotion of standards organizations (such as the IEC 61158 series and the OPEN Alliance's Automotive Ethernet specifications) has accelerated the maturity of the technology ecosystem. With the development of industry and edge computing, single-pair cabling, with its "one-wire, multiple-use" flexibility, is gradually replacing traditional multi-wire systems and becoming the preferred infrastructure for connecting smart devices.
[0063] With the large-scale deployment of single-pair Ethernet in the industrial control field, the number of low-power devices supporting protocols such as 10BASE-T1L and Profibus PA has increased sharply. However, the protocol compatibility, signal stability, and power supply performance of products from different manufacturers vary widely. For example, in an industrial site, there may be IIoT sensors based on 10BASE-T1L, transmitters using the HART protocol, and actuators compliant with the Foundation Fieldbus H1 standard. If these devices are directly networked without strict testing, it is likely to cause problems such as excessive communication latency, data packet loss, or power coupling noise. Therefore, when building a stable and reliable industrial control system, it is necessary to conduct full-link performance verification on single-pair devices.
[0064] In an industrial scenario, a single pair needs to adapt to multiple industrial communication protocols, and the test metrics of the physical layer and data link layer of different protocols vary significantly. Due to the lack of a unified test platform, engineers need to rely on a combination of multiple dedicated instruments to complete cross-protocol verification. For a single-pair gateway that supports multiple protocols simultaneously, testers need to manually select the device type and switch the test script, which undoubtedly greatly increases the workload of testers.
[0065] To solve the above problems, the embodiments of the present application provide a method for conformance testing of single-pair communication, as Figure 2 shown. The steps of the method specifically include:
[0066] Receive the communication signal sent by the device under test, extract the time-domain characteristics, frequency-domain characteristics, and modulation characteristics of the communication signal, generate protocol characteristic values, and perform dimensionality reduction processing on the time-domain characteristics, frequency-domain characteristics, and modulation characteristics to generate protocol characteristic vectors;
[0067] Perform a matching degree analysis on the protocol characteristic vectors and a predefined mapping dictionary to determine the target communication protocol type with the highest matching degree, where the mapping dictionary is generated based on a protocol standard feature library and a machine learning model;
[0068] Based on the determined communication protocol, dynamically generate a conformance test stream through a pre-trained neural network model. The test stream includes signal injection parameters, test timing configuration, and adaptive decision thresholds;
[0069] Configure a signal generator to inject an excitation signal according to the test stream, and synchronously collect the physical layer response, link layer frame structure, and power layer parameters of the device under test;
[0070] Based on the real-time feedback data, dynamically adjust the signal amplitude, frequency, and decision thresholds through a pre-trained neural network model;
[0071] Summarize the feedback data from multiple rounds of testing to generate a test report containing the conformance metrics of the physical layer, link layer, and power layer.
[0072] After the system receives the single-pair communication signal of the device under test, it extracts the time-domain characteristics, frequency-domain characteristics, and modulation characteristics of the communication signal to generate protocol characteristic values. The time-domain characteristics refer to the physical manifestations of the signal in the time dimension, reflecting the regularity, stability, and abnormal distortion of the signal waveform over time. Typical parameters include voltage amplitude (such as peak-to-peak value, DC offset), timing characteristics (rise / fall time, duty cycle, symbol period jitter), waveform integrity (eye diagram opening, overshoot / undershoot amplitude), etc. For example, the time-domain characteristics of the industrial fieldbus Profibus PA are manifested as the unique symmetric rise / fall edges (25ns ± 5%) of Manchester coding, while the PAM3 modulation of 10BASE-T1L Ethernet presents a three-level eye diagram with its symbol period strictly aligned to 100ns. The frequency-domain characteristics convert the signal to the frequency domain through Fourier transform to reveal its energy distribution and harmonic components. Key indicators include the ratio of fundamental frequency to harmonic power (such as total harmonic distortion THD), out-of-band noise suppression (spectrum mask compliance), carrier frequency accuracy (such as the 1200Hz / 2200Hz frequency deviation error of the HART protocol), etc. For example, the FSK modulation superimposed on the 4-20mA analog signal by the HART protocol has frequency-domain characteristics manifested as discrete spectral peaks at 1200Hz (logical "1") and 2200Hz (logical "0"), while the broadband spectrum of 10BASE-T1L needs to meet the flatness requirements of 1.6MHz to 20MHz specified by IEEE 802.3cg. The modulation characteristics describe how the signal encodes information through changes in carrier parameters (amplitude, frequency, phase), covering modulation methods (such as FSK, PSK, PAM3), symbol mapping rules (constellation diagram shape), modulation error rate (MER), etc. For example, Foundation Fieldbus H1 uses phase-continuous FSK based on a 31.25kHz carrier, and its modulation characteristics are reflected in a symbol rate of 1.0kbps and a ±7.5% frequency deviation tolerance; while the industrial Ethernet EtherCAT uses baseband NRZ coding, and its modulation characteristics are manifested as pulse-width modulation characteristics without a carrier.
[0073] Single-dimensional features cannot comprehensively represent the essential differences of communication protocols. Multi-dimensional features need to be considered comprehensively. For example, both HART and Modbus RTU use FSK modulation (similar in frequency domain), but the time-domain features of HART include the superposition of 4-20mA analog signals, while Modbus RTU is a pure digital signal, and the time-domain amplitude distributions of the two are significantly different. Another example is that both 10BASE-T1L and Profibus PA support single-pair lines, but the former needs to verify the anti-EMI ability through out-of-band noise suppression in the frequency domain (<-40dBc), while the latter relies on the time-domain jitter tolerance (<1UI) to ensure timing stability. Another example: for the same PSK protocol, the phase jump step of Profibus is 180° (BPSK), while some variants of RS-485 use differential PSK (DPSK), and their modulation features are completely different in the constellation diagram distribution. Therefore, this multi-dimensional cross-verification mechanism can effectively avoid misjudgment of single features (such as false peaks in the frequency domain caused by noise interference), and significantly improve the robustness and accuracy of protocol recognition.
[0074] Original feature data usually contains high-dimensional redundant information. For example, time-domain waveform sampling may contain thousands of data points, frequency-domain spectrum analysis may involve the energy distribution of hundreds of frequency bands, and modulation features (such as constellation diagram coordinates) may also generate high-dimensional vectors. These original features not only occupy a large amount of storage and computing resources, but may also cause model overfitting due to noise interference or high correlation between features, reducing the efficiency and accuracy of protocol recognition. Therefore, dimensionality reduction processing for the extracted time-domain features, frequency-domain features, and modulation features is a favorable choice to improve the efficiency of the method. The essence of dimensionality reduction processing is to extract key discriminative features in the low-dimensional space through mathematical methods, eliminate redundancy and retain classification information, so as to construct a more compact and representative protocol feature vector.
[0075] There are multiple choices for the specific method of dimensionality reduction, such as principal component analysis (PCA): PCA maps the original features to the orthogonal basis with the largest variance through orthogonal transformation, retaining the main variation directions of the data. For example, for the PAM3 modulation features of the 10BASE-T1L protocol (such as three-level amplitude, symbol interval, etc.), the original time-domain waveform may contain 1000 sampling points, which can be compressed to 10 principal components through PCA. These components can explain more than 95% of the signal energy distribution and eliminate the secondary fluctuations caused by high-frequency noise at the same time. Linear discriminant analysis (LDA): LDA maximizes the between-class difference and minimizes the within-class difference during dimensionality reduction, and is suitable for scenarios with known protocol class labels. For example, when distinguishing HART (FSK) from Profibus PA (Manchester coding), LDA can find the best projection direction to maximize the separation of the frequency-domain features of HART (1200 / 2200Hz double peaks) and the time-domain features of Profibus (edge symmetry) in the low-dimensional space, thereby improving the clarity of the classification boundary. t-SNE (t-distributed stochastic neighbor embedding): This non-linear method is good at visualizing the clustering structure of high-dimensional data. For example, when analyzing the mixed modulation features of multiple industrial protocols (such as Modbus RTU, Foundation Fieldbus), t-SNE can compress hundreds of dimensions of features to 2-3 dimensions, intuitively showing the distribution clusters of different protocols in the low-dimensional space, and assisting in the construction of the protocol fingerprint library and the detection of abnormal protocols. Autoencoder: The autoencoder realizes non-linear feature compression and reconstruction through a neural network. For example, for 500-dimensional original features including time-domain eye diagrams, frequency-domain power spectra, and modulation error rates, an encoder-decoder structure is designed to compress the data into a 20-dimensional latent space, and the reconstruction error of the decoder is less than 2%. This method can adaptively learn the deep abstract patterns of protocol features, especially suitable for processing the non-linear feature associations of complex protocols (such as the 10BASE-T1L and TSN fusion protocols). Dimensionality reduction reduces the feature dimension from hundreds to dozens, reducing the computational complexity of protocol matching from O(n²) to a linear level. Dimensionality reduction filters out noise and redundant information, reducing the risk of overfitting. The low-dimensional feature vectors are more easily associated with physical layer metrics, and the dimensionality-reduced feature space can unify the heterogeneous features of different protocols.
[0076] After completing the dimensionality reduction of time-domain, frequency-domain, and modulation features, it is necessary to convert the low-dimensional data into a standardized protocol feature vector through structured coding and feature fusion. The core goal of this process is to integrate multi-dimensional features into a vector form with clear physical meaning and suitable for matching algorithms, so as to support efficient protocol type recognition.
[0077] The features after dimensionality reduction (such as PCA principal components, autoencoder latent variables) usually exist in the form of floating-point number arrays. Exemplarily, the protocol feature vector can be generated through the following steps: standardize (Z-score) or normalize (Min-Max) each feature dimension to eliminate the dimensional difference; assign weights according to the feature importance; concatenate the dimensionality reduction results of time-domain, frequency-domain, and modulation features in a fixed order into a single vector.
[0078] After the protocol feature vector is generated, perform a matching degree analysis between the protocol feature vector and a predefined mapping dictionary to determine the target communication protocol type with the highest matching degree, where the mapping dictionary is generated based on a protocol standard feature library and machine learning model training. The mapping dictionary is a structured protocol feature database, and its core consists of two parts: a protocol standard feature library and machine learning optimized features. The protocol standard feature library is theoretical parameters extracted based on international communication standards, and these parameters are stored in the form of multi-dimensional vectors. For example, the original feature vector of 10BASE-T1L may contain 30 dimensions such as time-domain amplitude, frequency-domain bandwidth, and modulation error rate; the machine learning optimized features are generated by training measured data through a supervised learning model to generate a more compact and discriminative feature representation.
[0079] The matching degree analysis between the protocol feature vector and the mapping dictionary realizes efficient and accurate protocol type determination through a systematic process. Such as Figure 3As shown, first, preprocess the input feature vector to ensure that its dimension is aligned with the mapping dictionary entries, and use the same normalization method as when constructing the dictionary (such as Z-score or Min-Max) to eliminate the dimension difference. For example, when the input vector contains 10 dimensions of time domain, frequency domain, and modulation features, it is necessary to verify whether its structure is consistent with the protocol feature vector stored in the dictionary. If necessary, complete the alignment by filling in default values or truncating redundant dimensions. Subsequently, scale each eigenvalue to the range of [0, 1] according to the preset rules to avoid deviation in distance calculation caused by amplitude differences. Next, perform hierarchical matching to improve efficiency. First, conduct a coarse-grained classification based on key features to narrow down the candidate protocol range. For example, judge whether the protocol belongs to the high-frequency Ethernet class (such as 10BASE-T1L) or the low-frequency fieldbus class (such as Profibus PA) through the frequency domain principal component, and then further screen the subclasses according to the modulation features (such as FSK or PAM3 encoding). This step can reduce more than 70% of the invalid calculation amount. After determining the candidate protocol subset, enter the fine-grained similarity calculation stage, and use measurement methods such as weighted Euclidean distance or cosine similarity to quantify the matching degree between the input vector and the center of each protocol cluster in the dictionary. Specifically, if the weighted Euclidean distance between the input vector and the center of the HART protocol cluster is 0.06, while the distance from the center of the 10BASE-T1L cluster is 1.12, then the HART protocol with a smaller distance is preferentially selected as the candidate target. During this process, the feature weights are dynamically assigned based on the random forest or gradient boosting tree model. For example, the frequency domain feature may obtain a weight of 0.8 when distinguishing HART and Modbus, while the time domain feature is set to a weight of 0.7 when verifying the edge symmetry of Profibus, so as to strengthen the discriminative role of key features. Subsequently, confirm the final protocol type through dynamic threshold determination and confidence evaluation. The system sets an adaptive threshold according to the protocol complexity and historical misjudgment rate. For example, an Euclidean distance threshold of 0.1 is set for the HART protocol vulnerable to interference, while a strict threshold of 0.05 is adopted for the 10BASE-T1L with stable signals. If the distance between the input vector and the optimal candidate protocol is lower than the threshold and significantly better than the sub-optimal result (such as the minimum distance of 0.06 and the second minimum distance of 0.15), it is determined that the match is successful; if the distances of multiple protocols are close (such as 0.08 and 0.09), a secondary verification mechanism is triggered, such as injecting a specific handshake message into the device under test or performing a physical layer stress test, and further verify the protocol compatibility through the response data.
[0080] After determining the communication protocol of the device under test, a conformance test stream is dynamically generated through a pre-trained neural network model according to the communication protocol and the type of the device under test. This process deeply integrates protocol specification constraints and real-time environmental parameters to achieve intelligent optimization and adaptive execution of the test process. The pre-trained neural network model adopts a hierarchical multi-task learning architecture. Its input layer receives protocol type encoding, device model features, environmental noise samples, and historical test data. Through the bidirectional LSTM module and attention mechanism in the hidden layer, spatio-temporal correlation features are extracted. Finally, three groups of core test parameters are generated in the output layer: signal injection parameters, test timing configuration, and adaptive decision threshold.
[0081] In the stage of generating signal injection parameters, the model comprehensively determines the waveform, amplitude, and modulation mode of the excitation signal based on the protocol physical layer specification and device load characteristics. For example, when it is identified that the device under test is an IIoT gateway supporting Power over Data Line (PoDL) on a single pair of wires, the model will inject a composite waveform of superimposed DC power supply (such as 24V / 500mA) and PAM3 modulation signal, and dynamically compensate for signal attenuation according to the cable length (measured by Time Domain Reflectometry TDR) (such as increasing the amplitude by 5% for every 100 meters of cable). For the HART protocol, the model generates an FSK excitation signal (1200Hz / 2200Hz) superimposed on the 4 - 20mA analog signal, and automatically matches the enhanced burst mode timing according to the HART version number (such as HART-7) marked in the device manual.
[0082] The test timing configuration optimizes the scheduling strategy of multiple test items through a time series prediction model, solving the efficiency bottleneck caused by fixed timing in the traditional test process. For example, when verifying the physical layer jitter and link layer token polling of the Profibus PA protocol, the model will perform the following operations in parallel: synchronously trigger physical layer eye diagram sampling (once every 10ms) and link layer management frame injection (such as sending a token request every 200ms) in the first test cycle, and dynamically adjust the handshake timeout time according to the response speed of the device under test (the initial value is 1ms, and it will be gradually extended to 5ms if a delay is detected).
[0083] The adaptive decision threshold mechanism breaks through the limitations of traditional fixed thresholds and optimizes the decision conditions in real time through online reinforcement learning (such as Q-learning). For example, in the power layer consistency test, the model initially sets the surge current threshold to 120% of the device's nominal value (such as 2A), but when it detects that the ambient temperature rises to 85°C, it automatically relaxes the threshold to 150% (2.5A) to compensate for the temperature drift effect of semiconductor components; conversely, if the device under test is in an ideal laboratory environment (noise < 20dBm), the bit error rate threshold is tightened to 1e-12 to verify the extreme performance. This process drives the iterative update of the Q-learning policy network by defining an objective function (such as test accuracy weight 0.7, time consumption weight 0.2, energy consumption weight 0.1), and finally converges to the Pareto optimal solution.
[0084] The execution process of generating the test flow follows a logical framework that combines hierarchical progression and dynamic feedback, and realizes the adaptive optimization of test parameters through multi-stage collaborative control. In the initial stage, the system loads the basic test template based on the standard specifications of the target communication protocol, including physical layer signal parameters, link layer frame structure verification rules, and power layer constraint conditions. At the same time, it initializes the test hardware and calibrates the time synchronization module to ensure the timing alignment of subsequent multi-level data acquisition. This step provides a benchmark reference for the test process, avoids systematic errors caused by misunderstandings of protocol standards, and reserves a compatibility interface for dynamic adjustment.
[0085] In the environmental perception stage, the system uses a distributed sensor network to collect channel characteristics (such as cable attenuation, noise spectrum), device status (power supply stability, temperature drift), and service scenario requirements (test target priority, user-defined constraints) in real time, and constructs a multi-dimensional environmental feature vector. After being normalized, this data is input into a pre-trained neural network model as the context condition for dynamically generating the test flow. The core significance of environmental perception is to enable the test flow parameters to adapt to external interference and device individual differences in real time. For example, it dynamically compensates the signal amplitude according to the cable length, or switches the modulation method according to the environmental noise spectrum to avoid interference bands.
[0086] The neural network model generates the core parameters of the test flow through a hierarchical inference mechanism. In the signal injection parameter generation phase, the model combines protocol standard parameters with real-time environmental data to calculate the amplitude compensation value, modulation strategy optimization scheme, and frequency fine-tuning amount. For example, it dynamically increases the signal amplitude according to the channel attenuation model to maintain the effective signal-to-noise ratio. The test timing configuration uses a reinforcement learning algorithm to optimize the execution order and time allocation of test items, giving priority to high-failure-probability or short-duration test items to improve the overall efficiency. At the same time, it dynamically adjusts the handshake timeout period according to the device response speed to avoid ineffective waiting. The setting of the adaptive decision threshold is achieved through multi-objective optimization, taking the weighted combination of indicators such as test accuracy, time consumption, and energy consumption as the objective function, and dynamically calculating the pass thresholds for each level of testing. For example, in a high-temperature environment, the power supply ripple limit is relaxed to compensate for component performance drift, while the physical layer bit error rate threshold is tightened to maintain communication reliability.
[0087] In the test flow execution stage, a multi-channel synchronous trigger mechanism is adopted to ensure the coordinated operation of the signal generator, protocol analyzer, and power supply monitoring module. The signal injection parameters are accurately converted into the excitation signal waveform, and the physical layer response, link layer frame structure, and power layer parameters are collected with microsecond-level alignment through the hardware time synchronization engine, forming a data cube with spatio-temporal correlation. This mechanism enables the system to accurately locate cross-layer coupling faults. For example, it correlates the physical layer eye diagram distortion at a specific moment with the link layer CRC error for analysis, so as to identify signal integrity problems caused by impedance mismatch, rather than simply attributing them to protocol stack implementation defects.
[0088] The closed-loop optimization mechanism based on real-time feedback drives the dynamic adjustment of the test flow. After each round of testing, the system extracts key indicators (such as bit error rate, frame loss rate, peak surge current) and identifies performance bottleneck factors, updates the weights of the neural network model through an online learning algorithm, and generates adjustment strategies for signal amplitude, frequency, and decision threshold. The adjustment instructions follow the principle of progressive optimization. For example, it uses small-step iteration to increase the signal amplitude to avoid overshoot damage to the device, while monitoring the changes in power layer parameters to prevent secondary problems caused by the adjustment. This process continues to iterate until the test indicators converge or the termination condition is triggered, forming an "execution - feedback - optimization" closed-loop control loop.
[0089] The termination logic of the test flow is based on preset convergence conditions and safety protection mechanisms. When all level indicators continuously meet the standards, the marginal benefit of parameter adjustment is lower than the threshold, or the hardware protection mechanism is activated, the system stops the test and generates a structured report. The report not only includes the pass / fail determination for each level, but also records the parameter adjustment history and environmental impact factors, providing data support for subsequent design improvement or operation and maintenance decisions. Through the coordination of dynamic generation and real-time optimization, the entire process significantly improves the efficiency while ensuring the test coverage rate, and has strong robustness to cope with the disturbances in complex industrial environments.
[0090] Finally, summarize the feedback data from multiple rounds of testing to generate a test report that includes the consistency metrics for the physical layer, link layer, and power supply layer.
[0091] In some embodiments, optionally, as Figure 4 shown, the dimensionality reduction processing includes:
[0092] Normalize the time-domain features to eliminate the differences in signal amplitude and time reference;
[0093] Perform band-pass filtering and power spectral density calibration on the frequency-domain features;
[0094] Perform carrier frequency offset compensation and noise suppression on the modulation features.
[0095] Due to hardware differences in the device under test (such as ADC sampling rate, amplifier gain) and time-base drift in the test environment (such as clock source accuracy deviation), the time-domain signal will cause uncontrollable differences in signal amplitude and time reference. Therefore, this application uses dynamic range compression and sliding time window alignment techniques to normalize the time-domain features. First, the original signal amplitude is mapped to a preset standard range (such as [-1,1]) through linear transformation. For example, for the 4-20mA analog quantity of the HART protocol, after stripping the DC component, it is normalized according to the maximum swing amplitude (16mA) to eliminate the influence of ADC gain differences of different devices on feature extraction. Then, based on the synchronization signal (such as PTP protocol time synchronization) or signal autocorrelation peak detection, the time-domain waveform is interpolated and resampled to eliminate the symbol period measurement deviation caused by device clock jitter. For example, for the Manchester coding signal of Profibus PA, the time axis is aligned by detecting the rising edge of the preamble, reducing the standard deviation of symbol period jitter collected by different devices from ±5% to ±0.8%. The normalization process eliminates the time-domain feature deviations introduced by device hardware and the test environment, making the test data of devices from different suppliers comparable and improving the protocol matching accuracy by 15%-20%.
[0096] There is wide - band environmental noise in the industrial field (such as high - frequency interference from frequency converters and low - frequency disturbances caused by motor startup and shutdown), resulting in serious distortion of frequency - domain characteristics (such as harmonic components and noise floor). This application uses dynamic band - pass filtering and reference - signal inversion calibration technology to improve the effectiveness of frequency - domain characteristics. First, an adjustable digital filter is designed according to the spectrum range defined by the protocol standard (such as 1.6 - 20 MHz for 10BASE - T1L) to dynamically filter out out - of - band noise. For example, when 50Hz power - frequency interference is detected, a notch filter is enabled to suppress the energy at this frequency point, reducing the measurement error of the base - frequency power spectral density from ±3dB to ±0.5dB. Then, by injecting a reference sine signal with a known amplitude (such as 1MHz / -10dBm), the channel attenuation characteristics are inversely calculated to compensate the measured power spectrum. For example, when the cable loss causes a 6dB attenuation of the 10MHz component, the calibration module compensates the power value at this frequency point to the standard level, avoiding misjudgment of frequency - domain characteristics due to physical - medium differences. Band - pass filtering suppresses more than 85% of out - of - band interference, and power - spectrum calibration improves the compliance of frequency - domain characteristics with the protocol standard from 70% to 98%, significantly reducing the risk of protocol mis - identification caused by channel attenuation or environmental noise.
[0097] Carrier - frequency offset (such as a ±500ppm deviation caused by crystal - oscillator temperature drift) and channel noise (such as phase jumps caused by impulse interference) will damage the stability of modulation characteristics. This application uses frequency - offset estimation and pre - correction and noise - perception suppression technology to solve this problem. First, the carrier - frequency offset amount is estimated in real - time through fast Fourier transform (FFT) or Costas Loop, and digital mixing compensation is performed on the received signal. For example, when a +2kHz carrier - center - frequency offset is detected in an FSK - modulated signal, the signal spectrum is shifted back to the standard frequency point through complex multiplication, reducing the symbol - decision error rate by 40%. Then, based on wavelet transform and adaptive - threshold filtering technology, the impulse noise and Gaussian white - noise components in the signal are separated. For example, when an impulse interference with a duration <1μs is identified in a HART - protocol signal, time - domain zero - setting or median filtering is enabled, improving the modulation error rate (MER) from 18dB to 24dB. Carrier compensation expands the modulation - frequency - offset tolerance from ±1000ppm to ±2500ppm, and noise - suppression technology improves the protocol - identification success rate in a low - signal - to - noise - ratio (SNR = 10dB) scenario from 65% to 92%, significantly enhancing the robustness of the system in a harsh industrial environment.
[0098] In some embodiments, optionally, as Figure 5 shown, the matching - degree analysis includes:
[0099] Calculating the similarity between the standardized protocol feature vector and each protocol feature vector in the mapping dictionary based on the Euclidean distance;
[0100] Prioritize candidate protocols with similarity higher than a preset threshold;
[0101] Combine the context information of the protocol application scenario to select the final target communication protocol type.
[0102] Calculate the Euclidean distance between the standardized protocol feature vector and the feature vectors of each protocol cluster in the mapping dictionary as the benchmark for similarity measurement. This process is accelerated by a batch parallel computing engine. For example, for a mapping dictionary containing 100 protocol types, GPU-accelerated matrix operations are used to calculate the distances between the input vector and all protocol cluster centers at once, generating a similarity score matrix. To ensure the effectiveness of the distance calculation, the protocol feature vector needs to be pre-processed by standardization (such as Z-score normalization) to eliminate the differences in feature dimensions between different protocols (such as the time-domain amplitude unit is V and the frequency-domain power unit is dBm). The Euclidean distance provides an objective numerical similarity index, avoiding misjudgments caused by subjective experience, and the protocol matching accuracy is increased to ≥95%. Parallel computing controls the matching time of a large-scale protocol library (such as 1000+ protocols) within 10 ms, meeting the industrial real-time requirements.
[0103] Prioritize candidate protocols with similarity higher than a preset threshold (such as Euclidean distance ≤ 0.2), and the sorting rule combines static weights and dynamic context. For static weights, the priority is assigned based on the historical usage frequency of the protocol. For example, in the industrial control scenario, the weight coefficient of Profibus PA is set to 0.9, while that of CANopen is 0.7. For dynamic context, the sorting can be adjusted according to the real-time environmental noise level and the device model library (such as the white list of protocols supported by the device). For example, when it is detected that the device under test is a HART temperature transmitter, even if the similarity score of the HART protocol is slightly lower than that of Profibus PA, its priority is still promoted to the first place. Using the dynamic threshold and weight mechanism can effectively reduce the misjudgment rate of similar protocols and improve the recognition accuracy. By screening out low-similarity protocols through the threshold, the amount of data processing in the later stage can be effectively reduced, and the data processing efficiency can be improved.
[0104] On the basis of the priority sorting, introduce the context information of the protocol application scenario for the final decision. The context includes: device type and industry specifications, physical layer compatibility constraints, and environmental interference pattern library. The decision-making engine adopts a fusion model of rule reasoning and Bayesian network: First, exclude the protocols that are obviously not in line with the scenario through the rule library (such as in-vehicle devices do not support industrial Ethernet), and then calculate the conditional probabilities of each candidate protocol based on the Bayesian network (such as when the known environmental noise > 30 dBm, the applicable probability of the HART protocol is 85%), and select the protocol type with the highest comprehensive confidence.
[0105] The above three-step matching mechanism forms a progressive analysis process of "coarse screening - fine ranking - decision-making": the Euclidean distance quickly narrows the candidate range, dynamic ranking optimizes the computational load, and context fusion ensures that the final decision meets the actual application constraints. This process is particularly applicable to industrial devices with similar protocol features but different application scenarios (such as Profibus and IEC 61158-2 protocols both using Manchester encoding), and the two can be clearly distinguished through context rules (such as industry specifications). This matching degree analysis method provides a highly reliable and adaptive decision-making basis for the multi-protocol compatibility test of single-pair wire communication devices through the deep integration of quantitative calculation and semantic reasoning.
[0106] In some embodiments, optionally, dynamically adjusting the signal amplitude, frequency, and decision threshold through a pre-trained neural network model specifically includes: defining a test objective function, which includes a weighted combination of test accuracy, time consumption, and energy consumption; iteratively updating the signal injection parameters through the Q-learning algorithm to maximize the objective function.
[0107] Specifically, the test objective function is F = α * Accuracy + β * (1 / T) + γ * (1 / E), where Accuracy is the test accuracy evaluation value, comprehensively calculated based on the bit error rate, harmonic distortion degree, and protocol compliance; T is the time consumption of a single test, and E is the energy consumption during the test process; the weight coefficients (α, β, γ) are dynamically configured by the device type recognition module. For example, in the industrial device scenario, α:β:γ = 5:3:2. Then, based on the above test objective function, a reinforcement learning framework based on the deep Q network (DQN) is established. Its state space S includes: real-time channel parameters, including signal-to-noise ratio (SNR), multipath delay spread, and carrier frequency offset; device state characteristics, including power supply voltage volatility, chip junction temperature, and previous test response time; environmental interference characteristics, the center frequency and bandwidth of narrowband interference extracted through spectrum analysis; the action space A is defined as: signal amplitude adjustment, with a step size of 0.1 dB and a range of ±5 dB; frequency offset compensation, with a resolution of 1 ppm and a range of ±50 ppm; dynamic threshold update, adjusted according to the statistical characteristics of historical test data according to the ±3σ principle. Through the above scheme, a double-loop optimization mechanism is realized. In the inner loop, online parameter exploration is carried out through the ε-greedy strategy, and the exploration rate ε decays from 0.5 to 0.01 with the number of training rounds; in the outer loop, the target network parameters are synchronously updated every 24 hours, and the optimal strategy is stored in the device feature library.
[0108] In some embodiments, optionally, the physical layer protocol tests include transmitter output voltage, transmitter output droop rate, transmitter timing jitter, transmitter power spectral density, transmit clock frequency, transmit signal distortion, and receive bit error rate stress testing. Among them, the transmitter output voltage is used to detect the compliance of the signal amplitude, verify whether it meets the standard level requirements, and identify risks of insufficient driving ability or overload; the transmitter output droop rate is used to evaluate the amplitude attenuation characteristics of the signal during continuous transmission and detect power supply voltage regulation circuit defects or line impedance matching problems; the transmitter timing jitter is used to measure the time deviation of the clock edge and diagnose the stability of the clock source and signal integrity degradation; the transmitter power spectral density is used to analyze the distribution characteristics of signal energy in the frequency domain and detect out-of-limit EMI frequency points and harmonic interference; the transmit clock frequency is used to verify the deviation between the actual frequency and the nominal value and evaluate the tracking ability of the clock recovery circuit; the transmit signal distortion is used to quantify the waveform distortion degree and identify impedance mismatch, inter-symbol interference (ISI), or nonlinear distortion; the receive bit error rate stress testing is used to measure the BER under extreme conditions (such as the lowest level, the highest frequency) and verify the receiver sensitivity and noise tolerance.
[0109] In some embodiments, optionally, the link layer protocol tests include packet format verification, automatic polarity detection and correction, ESD_ERR4 error handling, FCS error handling, auto-negotiation verification, management restart auto-negotiation, link state failure detection, and link establishment time. Among them, the packet format verification is used to detect the compliance of the frame structure, preamble, delimiter, address field, length / type field; the automatic polarity detection and correction is used to detect the automatic recognition and inversion ability of the line pair polarity (A / B line); the ESD_ERR4 error handling is used to detect the error recovery ability after electrostatic discharge (ESD) events; the FCS error handling is used to detect the frame check sequence (FCS) error detection and frame loss strategy; the auto-negotiation verification is used to detect the rate / duplex mode negotiation process; the management restart auto-negotiation is used to detect the ability to trigger re-negotiation through software commands; the link state failure detection is used to detect the recognition speed of physical link interruption (such as carrier loss); the link establishment time is used to detect the recognition speed of physical link interruption (such as carrier loss).
[0110] In some embodiments, optionally, the power layer protocol test includes minimum current consumption, inrush current, in-band ripple noise, out-of-band ripple noise, current change rate, maximum / minimum load voltage events, under-voltage protection, shielding options, and polarity sensitivity. Among them, the minimum current consumption is used to detect the lowest operating current of the device in standby / sleep mode; the inrush current is used to detect the peak current (Inrush Current) at the moment of power-on; the in-band ripple noise is used to detect the low-frequency noise component on the power supply rail; the out-of-band ripple noise is used to detect the power supply noise spectrum in the high-frequency band; the current change rate is used to detect the current slope when the load changes suddenly; the maximum / minimum load voltage events are used to detect the voltage fluctuation range under extreme loads; the under-voltage protection is used to detect the turn-off response after the voltage drops to the threshold; the shielding options are used to detect the power line EMI suppression ability; and the polarity sensitivity is used to detect the tolerance ability of reverse power connection.
[0111] In the second aspect of the embodiments of the present application, a device for conformance testing of single-pair communication is provided, as Figure 6 shown, including the following modules:
[0112] A feature extraction module, configured to connect through a single pair of lines and receive the communication signals of the device under test, extract the time-domain features, frequency-domain features, and modulation features of the communication signals, and perform dimensionality reduction processing on the features to generate a protocol feature vector;
[0113] A protocol recognition module, configured to perform a matching degree analysis on the protocol feature vector and a predefined mapping dictionary to determine the target communication protocol type with the highest matching degree, where the mapping dictionary is generated based on a protocol standard feature library and machine learning model training;
[0114] A test flow generation module, configured to dynamically generate a conformance test flow based on the determined communication protocol through a pre-trained neural network model, where the test flow includes signal injection parameters, test timing configuration, and adaptive decision thresholds;
[0115] A test execution module, configured to configure a signal generator to inject an excitation signal according to the test flow, synchronously collect the physical layer response, link layer frame structure, and power layer parameters of the device under test, and dynamically adjust the signal amplitude, frequency, and decision threshold through a pre-trained neural network model based on real-time feedback data;
[0116] A report generation module, configured to summarize the feedback data of multiple rounds of tests and generate a test report including the conformance indicators of the physical layer, link layer, and power layer.
[0117] As Figure 7As shown, the feature extraction module receives the communication signals from the device under test, and respectively extracts time-domain features, frequency-domain features, and modulation features based on the above communication signals. Preferably, the above extraction processes are carried out synchronously to improve the extraction efficiency; then the extracted features are subjected to dimensionality reduction processing and a protocol feature vector is generated. Then the protocol feature vector generated in the above steps is sent to the protocol recognition module. The protocol recognition module determines the target communication protocol type with the highest matching degree by performing a matching degree analysis on the protocol feature vector and a predefined mapping dictionary, so as to determine the communication protocol type of the device under test. The determined communication protocol is sent to the test flow generation module. The test flow generation module dynamically generates a conformance test flow in a targeted manner through a pre-trained neural network model based on the above device type and protocol type. The test flow includes signal injection parameters, test timing configuration, and adaptive decision thresholds. The parameter information related to the generated test flow is sent to the test execution module, and the test execution module executes the test. Real-time feedback data will be generated during the test. If the real-time feedback data meets the predetermined conditions, the real-time feedback data is sent back to the test flow generation module. The test flow generation module re-adjusts the parameters related to the test flow based on the above real-time feedback data and re-sends them to the test execution module for re-testing. After multiple rounds of testing, the feedback data of multiple rounds of testing is summarized to generate a test report including conformance indicators for the physical layer, link layer, and power supply layer.
[0118] Embodiment 1. This embodiment mainly realizes the automatic recognition of the protocol type of the device under test.
[0119] First, signal acquisition and preprocessing are carried out. The system captures the communication signals of the device under test through a high-precision signal conditioning circuit, configures a sampling rate of 100MS / s and an ADC resolution of 14 bits to ensure that effective signals can still be obtained in an industrial electromagnetic interference (EMI) environment. In the signal preprocessing stage, an adaptive baseline calibration technique is adopted, and power frequency interference (50 / 60Hz) and high-frequency noise (>1MHz) are eliminated through sliding window median filtering. For the 4-20mA current loop superimposed digital signal unique to the HART protocol, the system separates the analog quantity and the FSK modulation wave through a digital phase-locked loop (DPLL) to achieve dual-channel parallel processing: the analog channel uses a 16-bit high-precision ADC for slow and high-precision sampling (1kS / s), and the digital channel enables a FIR band-pass filter (center frequency 1.7kHz, bandwidth ±500Hz) to extract the FSK signal.
[0120] Multi-dimensional feature extraction is then performed to synchronously extract time-domain features, frequency-domain features, and modulation features. Among them, the specific process of time-domain feature extraction is as follows: Align the signal waveform through an improved dynamic time warping (DTW) algorithm to eliminate the timing deviation caused by the device crystal oscillator drift (±100 ppm). Calculate the symmetry index (0.98 / 1.02) of the rising / falling edge within the symbol period to identify the Manchester coding feature of Profibus PA (theoretical value 1.0); The specific process of frequency-domain feature extraction is as follows: Use windowed FFT (Blackman-Harris window) and Welch power spectrum estimation to construct a 0-10 MHz spectrum template. For the broadband characteristics of the 10BASE-T1L protocol, focus on analyzing the power flatness (fluctuation <±1.5 dB) and out-of-band rejection ratio (>40 dB) in the 1.6-20 MHz frequency band. The specific process of modulation feature extraction is as follows: Deploy a constellation map reconstruction network based on deep learning (CNN-LSTM hybrid architecture) to achieve a classification accuracy of over 95% for modulation methods such as PAM3, FSK, and PSK. For the problem of eye diagram closure, introduce an adaptive equalization filter (LMS algorithm) to compensate for channel distortion, reducing the measurement error of the eye diagram opening degree from ±5% to ±1%.
[0121] Then, dimensionality reduction and fusion processing are performed on the extracted multi-dimensional features. Specifically: In the feature space construction stage, adopt a hierarchical dimensionality reduction strategy. Convert the original waveform of the time-domain features into an 8-dimensional symbol sequence through symbolic aggregate approximation (SAX) to retain the key timing patterns; Apply non-negative matrix factorization (NMF) to the frequency-domain features to extract the energy proportion of 3 main frequency bands (fundamental frequency, second harmonic, noise floor); Compress the 256-dimensional constellation map data of the modulation features to a 4-dimensional latent space using an autoencoder; Finally, generate a 12-dimensional comprehensive feature vector through feature concatenation and standardization (Z-score). Compared with the traditional PCA method, the protocol recognition accuracy of this scheme is effectively improved in the industrial noise environment.
[0122] Then protocol matching is performed. Among them, the protocol database is stored in a graph structure to construct a topological relationship network of protocol feature vectors; The matching process introduces hierarchical retrieval. First, narrow the search range according to the fundamental frequency range (e.g., <2 MHz is classified as a fieldbus protocol), and then use dynamic time warping distance (DTW) for time-domain features, KL divergence for frequency-domain features, and a hybrid similarity measure of cosine similarity for modulation features. Then, perform reasoning through the context. When the similarity difference between the HART and WirelessHART protocols is <5%, combine the device antenna impedance feature (>50Ω is determined as wired HART) for the final decision to obtain the protocol type with the highest matching degree.
[0123] Example 2. The main purpose of this example is to dynamically generate test streams and optimize test parameters.
[0124] First, load a three - layer test template based on the protocol type (such as 10BASE - T1L). Based on the physical layer, configure a BERT (Bit Error Rate Tester) to generate a PRBS31 pseudo - random sequence and inject it into an attenuation network (simulating the loss of a 1km 24AWG cable); based on the link layer, construct test frames containing VLAN tags and QoS priority markings, and make the stress test traffic reach 110% of the protocol limit; based on the power supply layer, simulate PoDL (Power over Data Line) power supply through a programmable DC power supply, set a load transient slope of 0 - 100mA / μs, and dynamically generate test flows based on different application scenarios, such as different cable layout methods for different house types or sites, and different environments, such as the presence or absence of high - speed rotating motors, etc.
[0125] Then, deploy a dual - neural - network architecture to achieve closed - loop control, including a policy network and an evaluation network. Among them, the policy network is based on the DDPG algorithm. The input layer receives real - time channel parameters (S - parameter matrix, return loss), device temperature (infrared thermal imager data), and historical test results, and the output layer generates an amplitude compensation value (±2dB), a frequency fine - tuning amount (±50ppm), and a decision - threshold relaxation coefficient (0.8 - 1.2 times); the evaluation network is based on the TD3 algorithm and constructs a multi - dimensional reward function, where the weight of bit - error - rate improvement is 0.6, the weight of test time consumption is 0.3, and the weight of device power consumption is 0.1. When the chip junction temperature > 85°C is detected, automatically insert a 5ms cooling interval and reduce the injected signal amplitude by 20%.
[0126] Then, conduct multi - level collaborative testing to achieve cross - protocol - stack correlation analysis. For example, achieve physical - link layer linkage. When a sudden increase in the CRC error rate is detected, synchronously retrieve the eye diagram data at the corresponding moment to identify the inter - symbol interference caused by impedance mismatch; achieve power - physical layer coupling testing. During the surge current test stage (500mA / μs), monitor the output voltage droop rate of the transmitter and establish a quantitative relationship model between power supply stability and signal amplitude; achieve environmental adaptability verification. Simulate multipath fading (RMS delay spread of 0 - 200ns) and strong electromagnetic interference (10V / m field strength) in an industrial environment through a reverberation chamber to evaluate the protocol robustness of the device under extreme conditions.
[0127] Finally, perform closed - loop feedback and knowledge - base update. Automatically enter each round of test data into the graph database to construct a knowledge graph of device characteristics. For example, it is found that when the cable length > 800m, the signal pre - emphasis coefficient needs to be increased from 2dB to 4dB to maintain the bit - error rate; accumulate typical abnormal cases, such as the characteristic waveform of the "ringing effect" caused by terminal resistance mismatch in the CAN FD protocol; when a new protocol (such as 802.1Qbv in TSN) is detected, start small - sample incremental learning, and only 50 groups of samples are required to expand the protocol library.
[0128] The above is only the specific implementation manner of the embodiments of the present invention, but the protection scope of the embodiments of the present invention is not limited thereto. Any person skilled in the art within the technical scope disclosed by the embodiments of the present invention can easily think of changes or substitutions, which should all be covered within the protection scope of the embodiments of the present invention. Therefore, the protection scope of the embodiments of the present invention shall be subject to the protection scope of the claims.
Claims
1. A method for conformance testing of single-pair wire communication, characterized in that, The method includes the following steps: Receive a communication signal sent by a device under test, extract the time-domain features, frequency-domain features, and modulation features of the communication signal, generate a protocol feature value, and perform dimensionality reduction processing on the time-domain features, frequency-domain features, and modulation features to generate a protocol feature vector; Perform a matching degree analysis on the protocol feature vector and a predefined mapping dictionary to determine the target communication protocol type with the highest matching degree, where the mapping dictionary is generated based on a protocol standard feature library and machine learning model training; Based on the determined communication protocol, dynamically generate a conformance test stream through a pre-trained neural network model, where the test stream includes signal injection parameters, test timing configuration, and an adaptive decision threshold; Configure a signal generator to inject an excitation signal according to the test stream, and synchronously collect the physical layer response, link layer frame structure, and power supply layer parameters of the device under test; Dynamically adjust the signal amplitude, frequency, and decision threshold through a pre-trained neural network model based on real-time feedback data; Summarize the feedback data of multiple rounds of tests to generate a test report including conformance indicators for the physical layer, link layer, and power supply layer.
2. The method according to claim 1, characterized in that, The target communication protocol type includes an industrial fieldbus protocol, an industrial Ethernet protocol, or a combination thereof, where the industrial fieldbus protocol includes at least one of single-pair communication 4-20mA+HART, Profibus, CAN, and Foundation Fieldbus, and the industrial Ethernet protocol includes at least one of the protocols in the IEEE 802.3 series that support single-pair.
3. The method according to claim 1, characterized in that, The dimensionality reduction processing includes: Perform normalization processing on the time-domain features to eliminate the differences in signal amplitude and time reference; Perform band-pass filtering and power spectral density calibration on the frequency-domain features; Perform carrier frequency offset compensation and noise suppression on the modulation features.
4. The method according to claim 1, wherein The matching degree analysis includes: Calculate the similarity between the standardized protocol feature vector and each protocol feature vector in the mapping dictionary based on the Euclidean distance; Perform a priority ranking on the candidate protocols with a similarity higher than a preset threshold; Select the final target communication protocol type in combination with the protocol application scenario context information.
5. The method according to claim 1, characterized in that, The neural network model is trained through supervised learning, and the training data includes a historical protocol test data set, a device model library, and environmental noise samples. The output of the model is a test stream parameter optimization strategy and a decision threshold adaptation rule.
6. The method according to claim 1, wherein The dynamically adjusting the signal amplitude, frequency, and decision threshold through a pre-trained neural network model specifically includes: Define a test objective function, which includes a weighted combination of test accuracy, time consumption, and energy consumption; Iteratively update the signal injection parameters through the Q-learning algorithm to maximize the objective function.
7. The method according to claim 1, characterized in that The conformance test includes a physical layer protocol test, a link layer protocol test, and a power supply layer protocol test.
8. The method according to claim 7, characterized in that The physical layer protocol test includes transmitter output voltage, transmitter output droop rate, transmitter timing jitter, transmitter power spectral density, transmit clock frequency, transmit signal distortion, and receive bit error rate stress tests.
9. The method according to claim 7, wherein The link layer protocol test includes data packet format verification, automatic polarity detection and correction, ESD_ERR4 error handling, FCS error handling, auto-negotiation verification, management restart auto-negotiation, link status failure detection, and link establishment time.
10. The method according to claim 7, characterized in that, The power layer protocol test includes minimum current consumption, inrush current, in-band ripple noise, out-of-band ripple noise, current change rate, maximum / minimum load voltage events, under-voltage protection, shielding options, and polarity sensitivity.
11. The method according to claim 1, wherein The time-domain features include: Peak-to-peak output voltage and voltage drift rate; Linearity of the rising / falling edges of the signal waveform; Standard deviation of time jitter within the transmission symbol period; The frequency-domain features include: Fundamental frequency power spectral density and harmonic attenuation slope; Spectrum mask compliance of out-of-band noise; The modulation features include: Carrier clock frequency offset; Distribution characteristics of the signal pre-emphasis coefficient.
12. An apparatus for conformance testing of single-pair wire communication, characterized in that It includes the following modules: A feature extraction module, configured to connect through a single pair of lines and receive the communication signal of the device under test, extract the time-domain features, frequency-domain features, and modulation features of the communication signal, and perform dimensionality reduction processing on the features to generate a protocol feature vector; A protocol identification module, configured to perform a matching degree analysis on the protocol feature vector and a predefined mapping dictionary to determine the target communication protocol type with the highest matching degree, wherein the mapping dictionary is generated based on a protocol standard feature library and machine learning model training; A test flow generation module, configured to dynamically generate a conformance test flow through a pre-trained neural network model based on the determined communication protocol, and the test flow includes signal injection parameters, test timing configuration, and adaptive decision thresholds; A test execution module, configured to configure a signal generator to inject an excitation signal according to the test flow, synchronously collect the physical layer response, link layer frame structure, and power layer parameters of the device under test, and dynamically adjust the signal amplitude, frequency, and decision threshold through a pre-trained neural network model based on real-time feedback data; A report generation module, configured to summarize the feedback data of multiple rounds of tests and generate a test report including the conformance metrics of the physical layer, link layer, and power layer.
Citation Information
Patent Citations
Resource allocation management for co-channel co-existence in intelligent transport systems
CN113841461A
Smart transport system co-channel coexistence frame structure with asymmetric gap duration
CN114143744A